reidmorrison/rocketjob

NameError: uninitialized constant RocketJob::Plugins::Job::Model::Boolean

Closed this issue · 2 comments

Environment

Provide at least:

  • Ruby Version.
    • ruby "2.5.8", :engine => "jruby", :engine_version => "9.2.19.0"
  • Rocket Job Version.
    • 'rocketjob', '5.4.1
    • 'rocketjob_mission_control', '5.0.1'
  • Application/framework names and versions (e.g. Rails, Sinatra, Puma, etc.).
    • puma (5.2.2-java)
    • 'rails', '5.2.4.2'
  • Full Stack Trace, if an exception is being raised.
~ bundle exec rocketjob

NameError: uninitialized constant RocketJob::Plugins::Job::Model::Boolean
load_missing_constant at /home/user/.rvm/gems/jruby-9.2.19.0/gems/activesupport-5.2.4.2/lib/active_support/dependencies.rb:550
const_missing at /home/user/.rvm/gems/jruby-9.2.19.0/gems/activesupport-5.2.4.2/lib/active_support/dependencies.rb:195
Model at /home/user/.rvm/gems/jruby-9.2.19.0/gems/rocketjob-5.4.1/lib/rocket_job/plugins/job/model.rb:42
module_eval at org/jruby/RubyModule.java:3255
append_features at /home/user/.rvm/gems/jruby-9.2.19.0/gems/activesupport-5.2.4.2/lib/active_support/concern.rb:122
include at org/jruby/RubyModule.java:3022
class:Job at /home/user/.rvm/gems/jruby-9.2.19.0/gems/rocketjob-5.4.1/lib/rocket_job/job.rb:6
module:RocketJob at /home/user/.rvm/gems/jruby-9.2.19.0/gems/rocketjob-5.4.1/lib/rocket_job/job.rb:3
at /home/user/.rvm/gems/jruby-9.2.19.0/gems/rocketjob-5.4.1/lib/rocket_job/job.rb:1
create_indexes at /home/user/.rvm/gems/jruby-9.2.19.0/gems/rocketjob-5.4.1/lib/rocket_job/rocket_job.rb:4
run at /home/user/.rvm/gems/jruby-9.2.19.0/gems/rocketjob-5.4.1/lib/rocket_job/supervisor.rb:15
run at /home/user/.rvm/gems/jruby-9.2.19.0/gems/rocketjob-5.4.1/lib/rocket_job/cli.rb:57
at /home/user/.rvm/gems/jruby-9.2.19.0/gems/rocketjob-5.4.1/bin/rocketjob:8
load at org/jruby/RubyKernel.java:1009
at /home/user/.rvm/gems/jruby-9.2.19.0/bin/rocketjob:23
eval at org/jruby/RubyKernel.java:1048
at /home/user/.rvm/gems/jruby-9.2.19.0/bin/jruby_executable_hooks:22

Expected Behavior

rocketjob should start

Actual Behavior

we receive an error: uninitialized constant RocketJob::Plugins::Job::Model::Boolean

Pull Request

  • Consider submitting a Pull Request with a fix for the issue.
  • Or, even a Pull request that only includes a test that reproduces the problem.

This appears to have been fixed in the 6.0 series

field :destroy_on_complete, type: Mongoid::Boolean, default: true, class_attribute: true, copy_on_restart: true

Yes, this change was required by the Mongoid gem. Using an older version of Mongoid will work with Rocket Job v5.
Rocket Job v6, although marked as a release candidate is fully production ready. The challenge is that work on the Web interface (RJMC) is ongoing. There is a an early version of RJMC available that we are running in production, and is fully functional. RJMC is undergoing a significant appearance overhaul.