[prev in list] [next in list] [prev in thread] [next in thread]
List: openjdk-nashorn-dev
Subject: Passing objects between Nashorn engines
From: Serguei Mourachov <smourachov () gmail ! com>
Date: 2014-10-31 15:18:38
Message-ID: 5453A84E.4070904 () gmail ! com
[Download RAW message or body]
I'm working on implementing automatic javascript code reloading.
The process is implemented using following sequence: when I'm seeing
any modification our our JS files, I'm preserving state of our system
calling a function returning ScriptObjectMirror, creating new
ScriptEngine, and initializing its state passing the ScriptObjectMirror
to it.
Apparently, it It works as expected in my simple tests, but it seems
that the initial ScriptObjectMirror keeps reference to its original
global and potentially to other old engine internals.
So my question is: is that safe in to share ScriptObjectMirror objects
between multiple engines and can I assume it's not going to create a
memory leak, keeping all the previous engines in memory after I stopped
using them?
SM
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic