sign in
Home | Updates | Pages | Users | Admin | Help

ActiveRDF and RoR and Sesame

test

test

h3. get jruby get jruby, as described in this guide Dont forget to export JRUBY_HOME and include JRUBY_HOME/bin in your path. I currently (as of 6-Feb-2006) recommend revision 2886, so that would be:
svn co -r 2886 svn://svn.codehaus.org/jruby/trunk/jruby jruby-trunk
If something does not work, you can try to update your jruby-trunk.

Go into your JRUBY_HOME, and do “ant clean test” to build jruby and run the tests. hopefully all tests pass.

2.) from now on make sure that only jruby versions of all relevant ruby tools are used.

3.) install ruby on rails:
gem install rails --include-dependencies --no-rdoc --no-ri
4.) install rake:
gem install rake --include-dependencies --no-rdoc --no-ri
5.) install activerdf and activerdf-sesame
gem install activerdf-sesame  --include-dependencies --no-rdoc --no-ri
You can get them from http://rubyforge.org/projects/activerdf/ , if the rubygems mirrors are not quick enough for this howto. 6.) set your java classpath to include the sesame jars, which are a part of the sesame adapter. these jars should be in JRUBY_HOME/lib/ruby/gems/1.8/gems/activerdf_sesame-0.1/ext/ or similiar. we will define JRUBY_HOME/lib/ruby/gems/1.8/gems/activerdf_sesame-0.1/ to be SESAME_ADAPTER then do:
 
export CLASSPATH=$SESAME_ADAPTER/ext/wrapper-sesame2.jar;$SESAME_ADAPTER/ext/openrdf-sesame-2.0-alpha4-onejar.jar
7.) run the sesame adapter tests:
cd $SESAME_ADAPTER/test
jruby test_sesame_adapter.rb
dont worry about java warnings, just make sure that the unit test summary mentions no errors or warnings from (j)ruby.

8.) perform the steps in the Getting Started Guide in the the section “The Semantic Web on Rails” at the bottom. see http://wiki.activerdf.org/GettingStartedGuide

9.) you can now start your ruby on rails application using jruby like this:
jruby ./script/server

10.) if you have come this far, then you are one of the lucky few persons in the world, who could potentialy build a ruby on rails application which uses rdfs inferencing. Please report your success to the activerdf users mailing list at activerdf@lists.deri.org :)


Powered by JunebugWiki v0.0.31 Page last edited by benjaminheitmann on February 08, 2007 12:05 PM (diff)
Version 5 «oldernewer»currentversions