From: Anthony E. <ae...@si...> - 2003-06-20 23:43:32
|
Is your WAR packed or unpacked? If they are unpacked then take a look at the PyServlet class in the Jython distribution. This demonstrates how to add your libraries in the WEB-INF/lib directory to sys. Unfortunately this won't work with packed WARs because the class loader only seems to support reading from the filesystem. I am still looking for a way around this. My last attempt was to replace the class loader with a custom class loader but I am not quite sure how Jython's class loading is supposed to work: my class loader implementation is actually trying to create a class from the package names. Example: if I try to use the following class: org.foo.MyClass the classloader will first ask for the class org. I am not sure what the classloader should return in this case. Sincerely, Anthony Eden Frank Cohen wrote: > I'm working on TestNetwork, the distributed version of TestMaker > (http://www.pushtotest.com/ptt.) The code installs on Tomcat, receives > SOAP-based Web Service calls that contain a Jython script, and > executes the Jython code and returns the results. It is SO cool to see > Jython running remotely like that. > > My problem is that Jython does not appear to find the jar files in the > WAR file of my webapp. My Tomcat 4.1 installation looks like this: > > tomcat/webapps/TestNetwork.war > > That expands to include: > > tomcat/webapps/TestNetwork/WEB-INF/lib/tool.jar > > How do I tell Jython to look in the WEB-INF/lib directory to import > the tool.jar? > > -Frank > > -- > Frank Cohen, Founder, PushToTest, http://www.PushToTest.com, phone: > 408 374 7426 > Come to PushToTest for free open-source test automation solutions that > test and monitor > Web-enabled applications, especially Web Services for scalability and > reliability. > > > > ------------------------------------------------------- > This SF.Net email is sponsored by: INetU > Attention Web Developers & Consultants: Become An INetU Hosting Partner. > Refer Dedicated Servers. We Manage Them. You Get 10% Monthly Commission! > INetU Dedicated Managed Hosting http://www.inetu.net/partner/index.php > _______________________________________________ > Jython-users mailing list > Jyt...@li... > https://lists.sourceforge.net/lists/listinfo/jython-users |