Since the lack of Java serialization of JRuby objects stops us dead in our tracks when trying to hook up our persistence engine, I am interested in either getting someone on this end to work on it or jumping in myself. In either case, I need some background on the JRuby runtime architecture and some guidance on particular issues. The issues are about how to detach an object from its runtime elements and how to restore them when the object gets reloaded into memory:

1) When we first tried saving a JRuby object to our database, we saw it drag along a gaggle of runtime objects. Given that it might be loaded into a different VM when it is brought in from the database, is reconnecting the object to a particular runtime important? If so, is there a way of determining which of the available runtimes would be best to connect it to?

2) Detaching an object from its 'runtime' variable and making the 'metaclass' variable transient lets us store the object in our database without dragging much else along. But we need to reconnect things when the object is reloaded into memory. Is there a canonical name for the metaclass that we could store in the database along with the instance? If not, what information is available for reconnecting. iWe persist type information in our Java product by storing the fully- qualified name of the class with the object, then lazily loading and initializing the connection (using the name) when we reload the object to memory. Will this work in JRuby?

If someone has thought through a strategy for deserializing a JRuby object and restoring its connections to its runtime, I would love to hear about it.

Thanks,
Alan McKean


---------------------------------------------------------------------
To unsubscribe from this list please visit:

   http://xircles.codehaus.org/manage_email

Reply via email to