I've got a workaround for the thread context classloader problem in JRuby in the jnlp gem (updated to: jnlp-0.0.2.1346)
Getting the updated into your jruby: $ jruby -S gem install jnlp --source=http://rails.dev.concord.org/gems/ JRuby limited openssl loaded. gem install jruby-openssl for full support. http://wiki.jruby.org/wiki/JRuby_Builtin_OpenSSL Updating metadata for 6 gems from http://rails.dev.concord.org/gems/ ...... complete Successfully installed jnlp-0.0.2.13465 1 gem installed Installing ri documentation for jnlp-0.0.2.13465... Installing RDoc documentation for jnlp-0.0.2.13465... Testing the code in jirb: $ jirb require 'rubygems' require 'jnlp' url = "http://rails.dev.concord.org/sds/2/offering/144/jnlp/540/view?sailotrunk.otmlurl=http://continuum.concord.org/otrunk/examples/BasicExamples/document-edit.otml&sailotrunk.hidetree=false" j = Jnlp::Otrunk.new(url, "cache") j.run_local Some questions: 1) After startup of the SAIL instance control returns back to the jruby program (jirb in this case) however if I quit the Swing instance the jruby program also quits. What's the best way to prevent this? 2) I like to be able to stop it from ruby, SessionManager doesn't have that capability. 3) Also is there a way to dynamically read and write into a sessions OTDatabase from the session object? If not what's he best way to add this capability? 4) If I try and start another SAIL session: j2 = Jnlp::Otrunk.new(url, "cache") j2.run_local I get this error: 2.run_local Jun 26, 2008 5:46:54 PM net.sf.sail.emf.launch.ConsoleLogServiceImpl setUpEMFFoundation INFO: local console data: /Users/stephen/SailUserData/v375/console16427.xml Setting up logging console. Done setting up file logging. Jun 26, 2008 5:46:54 PM net.sf.sail.core.service.impl.SessionManagerImpl start INFO: session property: sds_time=1214516813922 Jun 26, 2008 5:46:54 PM net.sf.sail.core.service.impl.SessionManagerImpl start INFO: session property: sailotrunk.otmlurl=http://continuum.concord.org/otrunk/examples/BasicExamples/document-edit.otml Jun 26, 2008 5:46:54 PM net.sf.sail.core.service.impl.SessionManagerImpl start INFO: session property: sailotrunk.hidetree=false Jun 26, 2008 5:46:54 PM net.sf.sail.emf.launch.PortfolioManagerService getOffering INFO: No bundle poster exists. Skipping old bundle uploading. Jun 26, 2008 5:46:55 PM net.sf.sail.emf.launch.PortfolioManagerService getOffering INFO: local learner data: /Users/stephen/SailUserData/v375/session16429.xml Jun 26, 2008 5:46:55 PM net.sf.sail.emf.launch.PortfolioManagerService getOffering INFO: no bundle poster -- marking bundle file for deletion on exit. Jun 26, 2008 5:46:55 PM net.sf.sail.emf.launch.ConsoleLogServiceImpl okToDelete INFO: not marking console log for deletion. successfulPost: false localFile: /Users/stephen/SailUserData/v375/console16427.xml Jun 26, 2008 5:46:55 PM net.sf.sail.emf.launch.SessionBundleHelper setupSessionBundle INFO: sessionId: 443ebd7a-0ab2-4309-ab97-ad92646033e2 NativeException: java.lang.UnsupportedOperationException: existing service reference obtained from different BeanContextServiceProvider not supported from java/beans/beancontext/BeanContextServicesSupport.java:211:in `verifyAndMaybeSetProvider' from java/beans/beancontext/BeanContextServicesSupport.java:323:in `usingService' from java/beans/beancontext/BeanContextServicesSupport.java:844:in `getService' from org/telscenter/sailotrunk/SailOTrunkRootBean.java:334:in `consumeService' from net/sf/sail/common/beansupport/SailBeanContextChildSupport.java:62:in `serviceAvailable' from java/beans/beancontext/BeanContextServicesSupport.java:1070:in `fireServiceAdded' from java/beans/beancontext/BeanContextServicesSupport.java:916:in `serviceAvailable' from java/beans/beancontext/BeanContextServicesSupport.java:681:in `addService' from java/beans/beancontext/BeanContextServicesSupport.java:647:in `addService' from net/sf/sail/core/beans/SessionContext.java:80:in `register' from net/sf/sail/core/beans/SessionContext.java:179:in `initiate' from net/sf/sail/core/service/impl/SessionManagerImpl.java:191:in `start' from sun/reflect/NativeMethodAccessorImpl.java:-2:in `invoke0' from sun/reflect/NativeMethodAccessorImpl.java:39:in `invoke' from sun/reflect/DelegatingMethodAccessorImpl.java:25:in `invoke' from java/lang/reflect/Method.java:585:in `invoke' Is there another way to accomplish this? --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "SAIL-Dev" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/SAIL-Dev?hl=en -~----------~----~----~----~------~----~------~--~---
