users@glassfish.java.net

RE: calling Groovy class from existing servlet...

From: Martin Gainty <mgainty_at_hotmail.com>
Date: Wed, 28 Apr 2010 20:03:58 -0400

if you want a Servlet which processes groovy scripts take a look at 'grails'
http://www.grails.org/Download

Martin Gainty
______________________________________________
Verzicht und Vertraulichkeitanmerkung/Note de déni et de confidentialité
 
Diese Nachricht ist vertraulich. Sollten Sie nicht der vorgesehene Empfaenger sein, so bitten wir hoeflich um eine Mitteilung. Jede unbefugte Weiterleitung oder Fertigung einer Kopie ist unzulaessig. Diese Nachricht dient lediglich dem Austausch von Informationen und entfaltet keine rechtliche Bindungswirkung. Aufgrund der leichten Manipulierbarkeit von E-Mails koennen wir keine Haftung fuer den Inhalt uebernehmen.
Ce message est confidentiel et peut être privilégié. Si vous n'êtes pas le destinataire prévu, nous te demandons avec bonté que pour satisfaire informez l'expéditeur. N'importe quelle diffusion non autorisée ou la copie de ceci est interdite. Ce message sert à l'information seulement et n'aura pas n'importe quel effet légalement obligatoire. Étant donné que les email peuvent facilement être sujets à la manipulation, nous ne pouvons accepter aucune responsabilité pour le contenu fourni.




> Date: Wed, 28 Apr 2010 13:29:46 -0700
> From: glassfish_at_javadesktop.org
> To: users_at_glassfish.dev.java.net
> Subject: calling Groovy class from existing servlet...
>
> Using NB6.8, the groovy-all-1.7.2.jar is in my classpath.
> In an existing servlet, I'm trying to call a method from a simple Groovy class in the same package.
>
> package bobo
> class MyProvider {
> def greeting = "Hello from Groovy"
> }
>
> in a servlet using:
> MyProvider provider = new MyProvider();
> provider.getGreeting();
>
> I get:
>
> WARNING: StandardWrapperValve[NewServlet]: PWC1406: Servlet.service() for servlet MyServlet threw exception
> java.lang.ExceptionInInitializerError
>
> In the glassfish log when I try to access it from a browser.
> [Message sent by forum member 'namestka']
>
> http://forums.java.net/jive/thread.jspa?messageID=399474
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_glassfish.dev.java.net
> For additional commands, e-mail: users-help_at_glassfish.dev.java.net
>
                                               
_________________________________________________________________
Hotmail is redefining busy with tools for the New Busy. Get more from your inbox.
http://www.windowslive.com/campaign/thenewbusy?ocid=PID28326::T:WLMTAGL:ON:WL:en-US:WM_HMP:042010_2