Hi Björn (including dev list), Nashorn is used to evaluate expressions in most pipe configurations so yes, it is mandatory. Can you track a bug in sling (ideally with a pax-exam failing IT patch)?
> On 6 Nov 2017, at 09:51, Bjoern Csott <[email protected]> wrote: > > Hi Nicolas, > > I’ve debugged the sling pipes code. The issue is > ScriptEngine engine = new ScriptEngineManager().getEngineByName("nashorn"); > in PipeBindings.java. > > The point I do not get is: Why does it work with sling pipes > PlumberServlet.java but not with mine. I got exactly the same lines to get > the pipe. > > Did you face these nashorn issues in the past? In dl-dev I found this: > https://github.com/apache/sling/tree/trunk/contrib/scripting/framework-extension-nashorn > > Is this a mandatory requirement? > > Thanks > Björn > > ... > > Von: Nicolas Peltier <[email protected]> > Datum: Donnerstag, 2. November 2017 um 17:58 > An: Bjoern Csott <[email protected]> > Betreff: Re: Sling Pipes > > Hi! Can you try to use directly the plumber in the see let to see if it helps? > What version are you using? > Can you share the code? > > Envoyé de mon iPhone > > Le 2 nov. 2017 à 15:32, Bjoern Csott <[email protected]> a écrit : > > Hi Nicolas, > > I have implemented some migration pipes in my current project. Since we want > to allow business to do the mandatory changes, we got a service which > executes the pipes. > > Now I have a really strange behavior: > If I trigger the migration via JMX everything works fine: > plumber.getPipe(pipeResource) returns my container pipe > If I inject the service into a Servlet and run the same method, I get a > Exeption from Plumber (Unable to properly instantiate the pipe configure > in....) and the follwing in system.out: > ScriptEngineManager providers.next(): javax.script.ScriptEngineFactory: > Provider > > In both cases I am getting the Resource resolver from the Resolverfactory for > a service account. > > Executing the pipe via curl works fine. > > Thanks for any hints! > Björn >
