ThreadService.getRubyThreadFromThread supports only one non-rubynative thread
at a time.
----------------------------------------------------------------------------------------
Key: JRUBY-2868
URL: http://jira.codehaus.org/browse/JRUBY-2868
Project: JRuby
Issue Type: Bug
Components: Embedding
Affects Versions: JRuby 1.1.3
Environment: JRuby when embedded inside a java application.
Reporter: Peter Williams
Priority: Critical
Consider JRuby running in embedded mode in a multithreaded scenario. Java
thread 1 creates the runtime. Later, java thread 2 invokes a ruby method. If
this method calls getActiveRubyThreads to obtain RubyThread instances for all
the active threads, the entry representing java thread 2 will actually be the
RubyThread instance for java thread 1.
This is because in ThreadService.getRubyThreadFromThread(), all non-rubynative
threads are mapped to singleton RubyThread masterContext.getThread(), which,
for the example above, will be the RubyThread representing the java thread that
originally created the runtime.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email