Exodus icon indicating copy to clipboard operation
Exodus copied to clipboard

JRuby support

Open jesjos opened this issue 9 years ago • 0 comments

I've been looking into providing JRuby support to this gem.

There are a couple of hurdles:

  1. Dependency upon bson_ext, which uses C extensions
    • This could be solved quite easily by adding an unless RUBY_PLATFORM ~= /java/ in the gemspec, so that bson_ext isn't used on JRuby
  2. Time precision is more coarse in JRuby
    • This messes up the completed? method in lib/exodus/migrations/migration.rb
    • time_it will very often return 0.0, especially if the down action is empty
    • Since execution_time == 0 is used to check whether execution has happened, we get errors.

I'd happily provide a PR, but I need help figuring out a better implementation for completed? - one that doesn't rely on the precision of Time.now.

jesjos avatar Apr 14 '15 08:04 jesjos