Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NameError: uninitialized constant ActiveSupport::ArrayInquirer Did you mean? ActiveSupport::ArrayInquirer #4788

Closed
cmthakur opened this issue Sep 14, 2017 · 5 comments

Comments

@cmthakur
Copy link

cmthakur commented Sep 14, 2017

Scenario
Recently we had switched to jRuby(jruby-9.1.7.0), but due to SSL handshake issues bug we upgrade java from 1.7x to 1.8.0_131. This leads to issue like "NameError: uninitialized constant ActiveSupport::ArrayInquirer Did you mean? ActiveSupport::ArrayInquirer".

Is this due to upgrade of java version or there any bug in jRuby itself?

Environment
Production

jRuby version:
jruby-9.1.7.0

OS:
Ubuntu 16.04.3 LTS

JAVA version:

openjdk version "1.8.0_131"
OpenJDK Runtime Environment (build 1.8.0_131-8u131-b11-2ubuntu1.16.04.3-b11)
OpenJDK 64-Bit Server VM (build 25.131-b11, mixed mode)

Framework:
Rails 5.0.0.1 (api)

Application Server
Passenger Entreprise

@cmthakur cmthakur changed the title uninitialized constant ActiveSupport::JSON Did you mean? ActiveSupport::JSON JSON NameError: uninitialized constant ActiveSupport::ArrayInquirer Did you mean? ActiveSupport::ArrayInquirer Sep 14, 2017
@kares
Copy link
Member

kares commented Sep 17, 2017

please try latest on 9.1 (9.1.13 ATM) ... this is an auto-loading issue that might go away.
if it persist than try to eager load your application -> as (lazy) loading in multiple threads, without a GIL, will always have some (more or less visible) race conditions ...

@cmthakur
Copy link
Author

@kares The application is already configured to use eager load and it should be able to work with the threaded web server in my case passenger server.

config/environments/production.rb

  # Eager load code on boot. This eager loads most of Rails and
  # your application in memory, allowing both threaded web servers
  # and those relying on copy on write to perform better.
  # Rake tasks automatically ignore this option for performance.
  config.eager_load = true

Am I missing anything here, except upgrading jRuby to the latest version?

@kares
Copy link
Member

kares commented Sep 18, 2017

nope, except maybe activerecord-jdbc-adapter not supporting Rails 5.x ... depends on particular adapter on how well it works. anyways just give upgrade a try and if the issue persist try to come up with a minimal reproducer piece.

@kares
Copy link
Member

kares commented Jun 20, 2018

since there's finally some AR-JDBC 50.x releases, this should be re-evaluated using those (and latest 9.1)

@kares
Copy link
Member

kares commented Sep 25, 2018

... no further feedback here and since desc is very vague - closing. we ideally need a reproducer.
anyway before doing that you should re-run with latest 9.1/9.2 as well as updated activerecord-jdbc-adapter.

@kares kares closed this as completed Sep 25, 2018
@kares kares added this to the Invalid or Duplicate milestone Sep 25, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants