Hi Mike

Indeed, the SlingScriptAdapterFactory appears to load the scripting 
providers using autodetection of the corresponding bundle metadata. 
However, the velocityengine has never been called so far, and I've managed 
to track down the problem, which itself was invisible due to a severely 
flawed exception handling in the ScriptEngineManager.
Apparently, the default logging configuration of apache velocity 1.6.2 has 
classloading issues in OSGi. It appears the velocity LogManager performs 
in-bundle classloading and ends up having the same interface loaded from 
two different classloaders (the velocity scripting support bundle and the 
velocity bundle), thus failing to assert that the configured logger 
implements the org.apache.velocity.runtime.log.LogChute interface. I will 
look into this.

Thanks,
Olaf
___________________________________________________________________

Olaf Otto IKGE*
externe Mitarbeiter, Unic AG, Bern
CSS Versicherung
Tribschenstrasse 21
CH-6002 Luzern
Telefon +41 (0)58 277 11 11
Telefax +41 (0)58 277 12 12
olaf.o...@css.ch
www.css.ch / www.intras.ch
___________________________________________________________________

CSS Kranken-Versicherung AG, CSS Versicherung AG,
INTRAS Kranken-Versicherung AG, INTRAS Versicherung AG,
Arcosana AG, Auxilia Kranken-Versicherung AG



Von:    Mike Müller <mike...@mysign.ch>
An:     "'users@sling.apache.org'" <users@sling.apache.org>
Datum:  26.08.2010 13:47
Betreff:        RE: Antwort: RE: Velocity scripting support



Hi Olaf

You should be able to use velocity scripting just by install
the bundle. There's no additional configuration needed.
The scripts which should be resolved by velocity scripting
must have .vlt as extension.
That should also work with your version of sling.

best regards
mike

> @Mike Müller:
>
> Hi,
> How exactly did you get the velocity scripting to work? The
> 2.0.0 snapshot
> version does not have any scr metadata and the factory is not
> detected by
> Sling (I'm running felix 1.4x and Sling engine version 2.0.7
> R897784 btw,
> and cannot change.). Did you simply install the scripting api
> and velocity
> bundles or was there additional configuration involved?
>
> Regards,
> Olaf
>
> ___________________________________________________________________
>
> Olaf Otto IKGE*
> externe Mitarbeiter, Unic AG, Bern
> CSS Versicherung
> Tribschenstrasse 21
> CH-6002 Luzern
> Telefon +41 (0)58 277 11 11
> Telefax +41 (0)58 277 12 12
> olaf.o...@css.ch
> www.css.ch / www.intras.ch
> ___________________________________________________________________
>
> CSS Kranken-Versicherung AG, CSS Versicherung AG,
> INTRAS Kranken-Versicherung AG, INTRAS Versicherung AG,
> Arcosana AG, Auxilia Kranken-Versicherung AG
>
>
>
> Von:    Mike Müller <mike...@mysign.ch>
> An:     "'users@sling.apache.org'" <users@sling.apache.org>
> Datum:  25.08.2010 16:22
> Betreff:        RE: Velocity scripting support
>
>
>
> > On Wed, Aug 25, 2010 at 4:07 PM, Mike Müller
> > <mike...@mysign.ch> wrote:
> > > I just upgraded and tested the Velocity scripting
> > > support to the latest stable version 1.6.4.
> >
> > Thanks!
> >
> > >
> > > What about making Velocity scripting to a first citizen
> > > scripting bundle and move it to bundles/scripting/velocity?...
> >
> > My preference is to leave it under contrib/scripting/velocity, so as
> > to keep our core small. That doesn't prevent us from releasing it.
>
> Okay, that's fine for me. In this case I would like to make a
> release 2.0.0.
>
> best regards
> mike
>
>
> ------
> Der Inhalt dieses E-Mails ist streng vertraulich und
> möglicherweise gesetzlich besonders geschützt. Dieses E-Mail
> ist nur für den Adressaten bestimmt. Wenn Sie nicht der
> beabsichtigte Empfänger sind, ist es Ihnen nicht gestattet
> und stellt möglicherweise einen Gesetzesverstoss dar, dieses
> E-Mail zu kopieren, zu verbreiten oder anderweitig zu
> verwenden. In diesem Fall sollten Sie uns so schnell wie
> möglich benachrichtigen und dieses E-Mail löschen.
>
> Le contenu de ce courriel est strictement confidentiel et
> probablement légalement protégé. Il n'est adressé qu'aux
> destinataires mentionnés. Si vous n'en faites pas partie,
> vous n'avez pas l'autorisation de le copier, ni de le
> diffuser, ni même de le destiner à un autre usage - ce qui
> dans chaque cas peut en effet constituer une infraction à la
> loi. Dans ce cas, vous devriez nous en informer immédiatement
> et effacer ce courriel.
>
> Il contenuto del presente messaggio elettronico è da
> considerare di massima riservatezza e possibilmente è
> protetto in modo particolare dalla legge. La presente e-mail
> è riservata alla sola attenzione della persona destinataria.
> Se lei non è la persona che avrebbe dovuto ricevere la
> e-mail, non le è permesso e possibilmente rappresenta una
> violazione della legge, copiare la presente e-mail,
> diffonderla o utilizzarla in qualsiasi altro modo. In questo
> caso lei dovrebbe informarci al più presto possibile e
> cancellare la presente e-mail.
>


------ 
Der Inhalt dieses E-Mails ist streng vertraulich und möglicherweise gesetzlich 
besonders geschützt. Dieses E-Mail ist nur für den Adressaten bestimmt. Wenn 
Sie nicht der beabsichtigte Empfänger sind, ist es Ihnen nicht gestattet und 
stellt möglicherweise einen Gesetzesverstoss dar, dieses E-Mail zu kopieren, zu 
verbreiten oder anderweitig zu verwenden. In diesem Fall sollten Sie uns so 
schnell wie möglich benachrichtigen und dieses E-Mail löschen. 

Le contenu de ce courriel est strictement confidentiel et probablement 
légalement protégé. Il n'est adressé qu'aux destinataires mentionnés. Si vous 
n'en faites pas partie, vous n'avez pas l'autorisation de le copier, ni de le 
diffuser, ni même de le destiner à un autre usage - ce qui dans chaque cas peut 
en effet constituer une infraction à la loi. Dans ce cas, vous devriez nous en 
informer immédiatement et effacer ce courriel. 

Il contenuto del presente messaggio elettronico è da considerare di massima 
riservatezza e possibilmente è protetto in modo particolare dalla legge. La 
presente e-mail è riservata alla sola attenzione della persona destinataria. Se 
lei non è la persona che avrebbe dovuto ricevere la e-mail, non le è permesso e 
possibilmente rappresenta una violazione della legge, copiare la presente 
e-mail, diffonderla o utilizzarla in qualsiasi altro modo. In questo caso lei 
dovrebbe informarci al più presto possibile e cancellare la presente e-mail.  

Reply via email to