0

I have installed:

  • Ubuntu 12.10
  • jruby 1.7.3
  • ruby 2
  • rails 3.2.13
  • RubyMine 5
  • DB2 C-Express

I have create a sample application and connected it correctly to the database - I know this because I have successfully executed the scaffold and migrate commands and check that the tables are created.

Then I have run the following commands in order to deploy my application with torquebox 2.0:

torquebox deploy
torquebox run

I have run these commands in my project folder and as a result on localhost:8080 I am seeing rails start page. I have the following issues:

  1. Clicking on "About your application’s environment" tab I am getting the following error:

javax.servlet.ServletException: org.jruby.exceptions.RaiseException: (NameError) cannot link Java class com.ibm.db2.jcc.DB2Driver, probable missing dependency: Could not initialize class com.ibm.db2.jcc.DB2Driver org.torquebox.web.servlet.RackFilter.doRack(RackFilter.java:117) org.torquebox.web.servlet.RackFilter.doFilter(RackFilter.java:101) org.torquebox.web.servlet.RackFilter.doFilter(RackFilter.java:72) org.torquebox.web.servlet.SendfileFilter.doFilter(SendfileFilter.java:49) org.torquebox.web.servlet.SendfileFilter.doFilter(SendfileFilter.java:33)

I believe this is because the torque box is not able to find the driver. But why as it is vissible in my rails application and I successfully created/migrate tables from it using the terminal? Should I put the driver somewhere else,too?

  1. Then I the torque box documentation is said:

Changes to your Rails application show up immediately in the browser, as expected. When you're done, press CTRL+C in the terminal to stop TorqueBox before continuing with the next steps.

But that's exactly what I have had to do in order to refresh the content of the page. I have changed my gem file and database.yml file but refreshing the page did not reflect this. After I have stop the server and start it again it shows something different.

Could you advise or tell me what I am doing wrong?

gotqn
  • 42,737
  • 46
  • 157
  • 243
  • not all changes show up immediately, some changes require restarting the process - did you run `bundle install` after updating your Gemfile? you will definitely need to restart (also changes to database.yml require a restart) – house9 Mar 29 '13 at 04:20
  • Yes, I have run bundle install several times during the changes. Unfortunately, I am not able to confirm this is happing again because I can't fix the torque box error described above. – gotqn Mar 29 '13 at 07:12

1 Answers1

1

Without restarting the Torquebox server your can redeploy the knob with touch just run

touch $TORQUEBOX_HOME/jboss/standalone/deployments/your_apps-knob.yml.deployed

this way you don't have to restart whole JBOSS server.Deployment via descriptor

For production setups you can use Capistrano Torquebox Capistrano support

tlarevo
  • 635
  • 1
  • 5
  • 12