Uploaded image for project: 'TinkerPop'
  1. TinkerPop
  2. TINKERPOP-1095

Create a custom ScriptContext

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Implemented
    • 3.1.0-incubating
    • 3.2.5
    • groovy
    • None

    Description

      The current ScriptContext in use with the ScriptEngine is the SimpleScriptContext. It doesnt' allow for additional scopes which might be useful when dealing with the ScriptEnginePluginAcceptor which allows plugins to inject "global" bindings into the a ScriptEngine instance (e.g. the "hdfs" object with the hadoop plugin).

      We currently inject this into the GLOBAL_SCOPE of the ScriptEngine which at the moment doesn't seem to conflict with anything, but I wonder if more separation is required.

      Another alternative would be to manage these types of "globals" with new methods on the DependencyManager interface.

      Attachments

        1. allocations-before.png
          213 kB
          Stephen Mallette
        2. allocations-after.png
          224 kB
          Stephen Mallette
        3. gc-before.png
          159 kB
          Stephen Mallette
        4. gc-after.png
          128 kB
          Stephen Mallette

        Issue Links

          Activity

            People

              spmallette Stephen Mallette
              spmallette Stephen Mallette
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: