You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@avalon.apache.org by Leo Simons <le...@apache.org> on 2003/11/05 09:30:08 UTC

Scripting containers (was: Merging plan)

Stephen McConnell wrote:
 > [scripting]

I don't quite recall why, but I ended up not very much liking the jelly 
service. Probably biased. Anyway, its easy to embed, as is BSF, as is a 
specific engine like BeanShell (which I'm currently doing as its the 
simplest IMO).

For an example of exactly how much control you could give to scripts:

http://cvs.sourceforge.net/viewcvs.py/*checkout*/jicarilla/jicarilla-sandbox/platform/components/http/impl/src/java/com/leosimons/Main.java?content-type=text%2Fplain&rev=1.1
http://cvs.sourceforge.net/viewcvs.py/*checkout*/jicarilla/jicarilla-sandbox/platform/components/http/impl/src/bsh/startup.bsh?content-type=text%2Fplain&rev=1.9

basically, load your service, expose the environment (ie instances of 
the important stuff) under some name, and your scripts can wreak havoc 
every way you like. Add security by exposing only specific parts of the 
environment. The next step is moving pieces of logic from java to your 
chosen scripting language. The tricky part is deciding how much to move.

Another BeanShell-based example here (component adapter factory 
supporting scripted configuration, for picocontainer):

http://cvs.codehaus.org/viewcvs.cgi/nano/bsh/?root=nanocontainer

I am not sure what parts of merlin you'd want to expose or how you would 
like to do it.

- LSD



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@avalon.apache.org
For additional commands, e-mail: dev-help@avalon.apache.org


Re: Scripting containers (was: Merging plan)

Posted by Stephen McConnell <mc...@apache.org>.

Leo Simons wrote:

> Stephen McConnell wrote:
> > [scripting]
>
> I don't quite recall why, but I ended up not very much liking the 
> jelly service. Probably biased. Anyway, its easy to embed, as is BSF, 
> as is a specific engine like BeanShell (which I'm currently doing as 
> its the simplest IMO).
>
> For an example of exactly how much control you could give to scripts:
>
> http://cvs.sourceforge.net/viewcvs.py/*checkout*/jicarilla/jicarilla-sandbox/platform/components/http/impl/src/java/com/leosimons/Main.java?content-type=text%2Fplain&rev=1.1 
>
> http://cvs.sourceforge.net/viewcvs.py/*checkout*/jicarilla/jicarilla-sandbox/platform/components/http/impl/src/bsh/startup.bsh?content-type=text%2Fplain&rev=1.9 
>
>
> basically, load your service, expose the environment (ie instances of 
> the important stuff) under some name, and your scripts can wreak havoc 
> every way you like. Add security by exposing only specific parts of 
> the environment. The next step is moving pieces of logic from java to 
> your chosen scripting language. The tricky part is deciding how much 
> to move.
>
> Another BeanShell-based example here (component adapter factory 
> supporting scripted configuration, for picocontainer):
>
> http://cvs.codehaus.org/viewcvs.cgi/nano/bsh/?root=nanocontainer
>
> I am not sure what parts of merlin you'd want to expose or how you 
> would like to do it. 


I'm thinking about a scriptable kernel with the ability to add and 
remove components - trigger assembly and deployment - etc. 

Stephen.

>
>
> - LSD
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@avalon.apache.org
> For additional commands, e-mail: dev-help@avalon.apache.org
>
>

-- 

Stephen J. McConnell
mailto:mcconnell@apache.org




---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@avalon.apache.org
For additional commands, e-mail: dev-help@avalon.apache.org