Skip to content

Third-party SDK: consume JS-declared extensions from other OSGi bundles #696

Description

@romain-pm

Part of EPIC #554. Implemented — under review in #687.

New exported package org.jahia.modules.javascript.modules.engine.sdk with JSServerExtensionInvoker: forEach(type, handler) iterates JS registry entries within one GraalVM context, Invoker.call(...) executes a JS callable and converts results to plain Java — consumer bundles need no polyglot or engine-internal imports (those packages stay unexported). The engine bundle's Export-Package lists only this package.

First consumer: formidable (JS form-field validators executed server-side).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions