Hi Scott, thanks for the gentle reminder ...
+) I have an updated version based on the final JSR-223 release (but not committed) that works for Groovy and Rhino +) this implementation is already using the libraries from https://scripting.dev.java.net/ +) the main problem I had is supporting JDK 1.5 which I solved at ApacheCon - the non-released bsf-api-3.0 is an ASF implementation for JSR-223 +) so fulcrum-script is a JDK1.5+ component So the only thing which stopped me from committing is that the various ScriptEngine (Groovy, Rhino) implementation are not on any M2 repo - I currently keep them in a lib directory and tell M2 to pick them up from there. BTW, I'm pretty sure that https://scripting.dev.java.net/ was not BSD licenced a while ago. Anyway - how to handle the ScriptEngine libraries +) M2 repo upload request but there are no official releases for the them ... :-( +) put them in our SVN repo in a "lib" directory with PMC blessing And the unreleased BSF libraries ... Cheers, Siegfried Goeschl PS: I have already two kids sitting on my lap - need a break PS: Many thanks to Felix Meschberger regarding BSF Scott Eade wrote: > It appears that JSR-223 is bit of a mixed bag. > > As Siegfried has said below there were changes to the spec between its > 1.0 release and its inclusion in JDK 6: > > * Namespace was renamed to Bindings > * SimpleNamespace became SimpleBindings > * Invocable.invoke() methods became Invocable.invokeFunction(String > Object...) and Invocable.invokeMethod(Object, String Object...) > [note the use of varargs] > * there may be one or two other small changes. > > You can download a bunch of ScriptEngine implementations from > https://scripting.dev.java.net/ - I presume these all work with JDK 6, > certainly the JavaScript one does. Note that JDK 6 on Windows > includes Rhino and the com.sun.script implementation of ScriptEngine, > but since scripting engines are optional you cannot actually rely on > this being present (e.g. JDK 6 on OS X does not come with Rhino). To > use Rhino on OS X with JDK 6 you need the java.net ScriptEngine > implementation (which comes in a package named com.sun.phobos.script > and appears to work nicely with a standard Rhino download). The > java.net implementation is not available in a maven repository (though > it is BSD licensed and is not a huge amount of code). > > AFAICT there is no stand alone version of javax.script that has been > updated to reflect the above changes so as to support JDK versions > prior to 6. I did come across an Apache ScriptEngine implementation > for Rhino at > http://svn.apache.org/viewvc/incubator/sling/trunk/bundles/scripting/javascript/ > - sling seems to indicate that JDK 5 is okay, so I am not sure what > they are doing. > > What do people think of saying that fulcrum-script is a JDK 6+ > component? fulcrum-bsf/fulcrum-groovy could be retained in some form > to support JDK < 6 (note that there is chatter about a new release of > BSF). > > Of course if Siegfried can convince the JSR-223 spec lead to release a > stand alone update to the javax.script API then fulcrum-script should > be able to use it to support JDK < 6, but until then... (can JDK 1.4 > code pass vararg arguments such as Object... as Object[]?) > > I have patches here to update fulcrum-script to work with JDK 6, but I > won't commit them without comment from Siegfried. > > Scott > > Siegfried Goeschl wrote: >> Hi Thomas, >> >> some historical background >> >> +) I needed a scripting integration for one of my products >> +) I had a look at BSF and found it largely deserted >> +) I wrote fulcrum-groovy but groovy was never stable enough for >> production usage >> +) I discovered the brand new JSR-223 and it gives me a script >> compile functionality to improve performance ... yippie >> +) Sun still worked on the JSR-223 spec (being part of JDK 1.6) and >> provided samples and libraries to be downloaded >> +) I got fulcrum-script it running in this ver early state >> (pre-final) using JavaScript and Groovy >> +) unfortunately Sun made a last minute change to the final Spec >> +) I got in touch with the JSR-223 spec lead and he told me that Sun >> might publish a final javax.script library to be used with JDK 1.4 >> >> Soo far so good >> >> +) I downloaded the final spec and they have an updated javax.script >> +) I have a look to see if it is working somehow under with fulcrum >> and JDK 1.4 >> >> Cheers, >> >> Siegfried Goeschl >> >> >> >> Thomas Vandahl wrote: >>> Hi folks, >>> >>> My understanding of the intention of fucrum-script is that it >>> supports all JSR-223 implementations of scripting engines. Would >>> that be a true replacement for the other scripting components? I >>> would like to get rid of them then. Your comments are welcomed. >>> Especially Siegfrieds as we already talked about the subject but I >>> cannot remember the outcome... >>> >>> Bye, Thomas. >>> >>> --------------------------------------------------------------------- >>> To unsubscribe, e-mail: [email protected] >>> For additional commands, e-mail: [email protected] >>> >>> >>> >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: [email protected] >> For additional commands, e-mail: [email protected] >> > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [email protected] > For additional commands, e-mail: [email protected] > > > --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
