Skip to content


Subversion checkout URL

You can clone with
Download ZIP
A JRuby/Hibernate integration with Datamapper
Ruby JavaScript Java
Pull request Compare This branch is 180 commits ahead of headius:master.
Fetching latest commit...
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.
demo require dm-{transactions,migrations}
lib refactoring of all java hooks conversion and adding first part of com…
spec refactoring of all java hooks conversion and adding first part of com…
src/main/java/dm_hibernate_adapter * add jruby-classloader wrapper to allow reload of ruby classes which…
LICENSE-2.0.txt added apache license + header in lib files
Mavenfile refactoring of all java hooks conversion and adding first part of com… docu: main db vendors
Rakefile #12 - we dont need eventlog
dm-hibernate-adapter.gemspec little fixes

dm-hibernate-adapter aka jibernate


  • Install ruby-maven wrapper

    jruby -S gem install ruby-maven

  • setup the gems and compile the java extension

    rmvn clean gem:initialize compile -- -Djruby.version=1.6.4


  • The ruby-maven setup will generate a pom.xml which can be used by proper maven3.
  • Don't use -o if you want to access remote repositories


  • use SHOW_SQL=true ENV variable in order to log SQL (except DDL, turned off by default)
  • use FORMAT_SQL=true ENV variable in order to format SQL logs



  • how to list rake tasks (please note the jruby.rake.args part(var name))

    rmvn rake -T -- -o


Test suites:

  • AbstractAdapter specs:

    rmvn rake spec -- -o or rmvn rspec spec/

    Database Vendor Abstract Adapter
    MySQL x
    PostgreSQL x
    Derby -
    H2 x
    HSQLDB -


  • when using rmvn test there will be a nice html rspec report in target/rspec-report.html. to get debug output use (use '--' only once which denotes the beginning of maven options) -- -Djruby.verbose -e
  • you can switch the jruby version by adding to the above commands -- -Djruby.version=1.6.3
  • if you are getting OutOfMemory errors, you should try to tune jruby-maven-plugin's settings and set them as properties in 'Mavenfile' - see in that file (ie. properties['jruby.jvmargs'] = '-Xmx1024m')
  • if you are getting problems with specs you can skip that phase: -- -Dmaven.test.skip=true


Authors listed in dm-hibernate-adapter.gemspec file (in random order). Project was built on top of Charles Nutter's sample code.


See LICENSE-2.0.txt

Something went wrong with that request. Please try again.