Closed Bug 1200403 Opened 9 years ago Closed 11 months ago

SpiderMonkey does not allow runtimes to be switched between threads

Categories

(Core :: JavaScript Engine, defect)

31 Branch
defect

Tracking

()

RESOLVED INCOMPLETE

People

(Reporter: rehrlich, Unassigned)

Details

User Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; Trident/7.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C; .NET4.0E; InfoPath.2; rv:11.0) like Gecko

Steps to reproduce:

When converting our application to SpiderMonkey v31, we noticed that the API functions JS_SetRuntimeThread() and JS_ClearRuntimeThread have been removed. Our application depends on being able to switch a runtime from one thread to another.

We use JavaScript as our script engine in our HTTP server. We use a 
runtime/context to maintain state of a user from one HTTP request to another 
(our concept of a session). This works very well for us to maintain random 
state information and reuse compiled scripts. Obviously sessions can last a 
long time and processing threads will come and go, but we must maintain 
state.

See the discussion entitled "Re: Threading and runtime / context sharing" in the Mozilla.dev.tech.js-engine for more details.

Also the development team submitted https://bugzilla.mozilla.org/show_bug.cgi?id=1188693.
Severity: normal → S3
Status: UNCONFIRMED → RESOLVED
Closed: 11 months ago
Resolution: --- → INCOMPLETE
You need to log in before you can comment on or make changes to this bug.