From: Dean T. <dth...@me...> - 2001-06-19 15:25:01
|
Does anyone have experience running Jython in a WebLogic environment? I think the most likely scenario for us would be to invoke Jython scripts from within servlets, and then invoke further Java APIs from within those Jython scripts. Dean |
From: Andrew B. <ab...@fa...> - 2001-06-19 16:14:47
|
> Does anyone have experience running Jython in a WebLogic > environment? I think the most likely scenario for us would > be to invoke Jython scripts from within servlets, and then > invoke further Java APIs from within those Jython scripts. A little bit of experimentation with org.python.util.PyServlet has me pretty excited - it seems very easy to configure so you can load your own python scripts (implementing HttpServlet) directly from your webapp's HTML root directory. The scripts can then load java classes from your webapp. I haven't tried it in WebLogic, but the configuration is very simple and should work in any Servlet 2.2-compliant container. In this model, the Jython script *is* the servlet, but it's pretty close to what you described... It seems like python servlets can even import other non-servlet python classes from the HTML root, but it's a little awkward, since they need to be imported by full package name, and the directory with the scripts in it must have an __init__.py in it for the import to work. Not worth complaining about, but it was a little tough to figure out... is there an easier way? Ideally, you'd be able to stick a few python files, including the servlet script, in some random directory under the web app; you'd invoke the jython servlet by its full name, but have the servlet be able to directly import other scripts in the same directory without needing to reference the name of the directory they're in. Seems like jython scripts could easily coexist with JSPs, placing objects in the request context and then forwarding to a JSP to do the presentation. I imagine it could integrate very nicely with Jakarta Struts, too - Python seems like a good language to implement Action classes in. Andy Boyko ab...@fa... |
From: Carlos G. A. <ga...@to...> - 2001-06-19 17:51:56
|
Ok guys, where can I find documentation about that? I mean servlets in Jython. Chau, Gaston ----- Original Message ----- From: Andrew Boyko <ab...@fa...> To: <jyt...@li...> Sent: Tuesday, June 19, 2001 1:16 PM Subject: RE: [Jython-users] PyServlet (Was: Running Jython within WebLogic) > > Does anyone have experience running Jython in a WebLogic > > environment? I think the most likely scenario for us would > > be to invoke Jython scripts from within servlets, and then > > invoke further Java APIs from within those Jython scripts. > > A little bit of experimentation with org.python.util.PyServlet > has me pretty excited - it seems very easy to configure so > you can load your own python scripts (implementing HttpServlet) > directly from your webapp's HTML root directory. The scripts > can then load java classes from your webapp. I haven't tried > it in WebLogic, but the configuration is very simple and should > work in any Servlet 2.2-compliant container. In this model, > the Jython script *is* the servlet, but it's pretty close to > what you described... > > It seems like python servlets can even import other non-servlet > python classes from the HTML root, but it's a little awkward, > since they need to be imported by full package name, and > the directory with the scripts in it must have an __init__.py > in it for the import to work. Not worth complaining about, > but it was a little tough to figure out... is there an easier > way? Ideally, you'd be able to stick a few python files, > including the servlet script, in some random directory > under the web app; you'd invoke the jython servlet by its full > name, but have the servlet be able to directly import other > scripts in the same directory without needing to reference > the name of the directory they're in. > > Seems like jython scripts could easily coexist with JSPs, > placing objects in the request context and then forwarding > to a JSP to do the presentation. I imagine it could > integrate very nicely with Jakarta Struts, too - Python > seems like a good language to implement Action classes in. > > Andy Boyko ab...@fa... > > _______________________________________________ > Jython-users mailing list > Jyt...@li... > http://lists.sourceforge.net/lists/listinfo/jython-users |
From: James H. <jh...@pa...> - 2001-06-19 16:23:40
|
We're using Jython in WL6.0 within Session beans.... seems to work fine with no hitches. (unlike JAXP1.1 compliant XML parsers, which WL6.0 can't get along with worth a darn.) James At 6/19/2001 11:22 AM -0400, Dean Thompson wrote: >Does anyone have experience running Jython in a WebLogic environment? I >think the most likely scenario for us would be to invoke Jython scripts >from within servlets, and then invoke further Java APIs from within those >Jython scripts. > >Dean |
From: <la...@lu...> - 2001-06-19 16:46:46
|
Hi Dean. I haven't used Jython specifically with WebLogic, but I have used Jython to communicate w/ EJBs on a Jboss server, which is similiar. It works very well. Let me know if you have any specific questions and if I have an answer for you I'll cough it up :) ----------------------------------------------------------------------------- Brian Knox Just Another Perl Hacker perl -le '$_="6110>374086;2064208213:90<307;55";tr[0->][ LEOR!AUBGNSTY];print' On Tue, 19 Jun 2001, Dean Thompson wrote: > Does anyone have experience running Jython in a WebLogic environment? I > think the most likely scenario for us would be to invoke Jython scripts from > within servlets, and then invoke further Java APIs from within those Jython > scripts. > > Dean > |