Skip navigation links

Package com.caoccao.javet.interop.engine

Engine pool for managing reusable V8/Node.js runtime instances in production.

See: Description

Package com.caoccao.javet.interop.engine Description

Engine pool for managing reusable V8/Node.js runtime instances in production.

Creating V8 runtimes is expensive. Use the engine pool to amortize that cost:

Usage:


 try (JavetEnginePool<V8Runtime> pool = new JavetEnginePool<>()) {
     try (IJavetEngine<V8Runtime> engine = pool.getEngine()) {
         V8Runtime runtime = engine.getV8Runtime();
         runtime.getExecutor("1 + 1").executeInteger();
     }
 }
 
Since:
0.7.0
Skip navigation links