One thing to be careful of: I'm not 100% sure the tooling is completely threadsafe. I think it does some thing to various static caches and other statics which may not be re-entrant. Thus, I would SUGGEST making sure it's protected somehow from being called on multiple threads at the same time.
That said, it may work. But it may also not work. It's not an area that we've stressed tested at all from a re-entrancy standpoint. :-) Dan On Wednesday 10 November 2010 4:38:33 am Wang Jinglong wrote: > hi, > > in my environmen,i need to use wsdl4java to generate java code in runtime. > so i need call wsdl4java api that i can generate code in runtime(may be > not in web apps). > > then i run my test case,that throw an exception: > org.apache.cxf.tools.common.ToolException: Could not find jaxws frontend > within classpath > at > org.apache.cxf.tools.wsdlto.core.PluginLoader.getFrontEnd(PluginLoader.java > :241) at > org.apache.cxf.tools.wsdlto.core.PluginLoader.getFrontEndProfile(PluginLoad > er.java:377) at > org.apache.cxf.tools.wsdlto.WSDLToJava.loadFrontEnd(WSDLToJava.java:64) at > org.apache.cxf.tools.wsdlto.WSDLToJava.run(WSDLToJava.java:96) > at org.apache.cxf.tools.wsdlto.WSDLToJava.run(WSDLToJava.java:86) > > that's means no jar of jaxws frontend in my classpath. > > how to add jaxws frontend into my classpath? > > i'm use maven. > > pom dependencies: > > <dependencies> > <dependency> > <groupId>wsdl4j</groupId> > <artifactId>wsdl4j</artifactId> > <version>1.6.2</version> > </dependency> > <dependency> > <groupId>org.apache.ws.schema</groupId> > <artifactId>XmlSchema</artifactId> > <version>1.4.5</version> > </dependency> > <dependency> > <groupId>dom4j</groupId> > <artifactId>dom4j</artifactId> > <version>1.6.1</version> > <type>jar</type> > <scope>compile</scope> > </dependency> > <dependency> > <groupId>junit</groupId> > <artifactId>junit</artifactId> > <version>4.8.2</version> > <type>jar</type> > <scope>compile</scope> > </dependency> > <dependency> > <groupId>log4j</groupId> > <artifactId>log4j</artifactId> > <version>1.2.15</version> > <type>jar</type> > <scope>compile</scope> > </dependency> > <dependency> > <groupId>ws-commons</groupId> > <artifactId>axiom</artifactId> > <version>1.1.1</version> > <type>jar</type> > <scope>compile</scope> > </dependency> > <dependency> > <groupId>org.apache.cxf</groupId> > <artifactId>cxf-tools-wsdlto-core</artifactId> > <version>2.3.0</version> > <type>jar</type> > <scope>compile</scope> > </dependency> > <dependency> > <groupId>org.apache.cxf</groupId> > <artifactId>cxf-rt-frontend-jaxws</artifactId> > <version>2.3.0</version> > <type>jar</type> > <scope>compile</scope> > </dependency> > </dependencies> > > thx a lot! -- Daniel Kulp [email protected] http://dankulp.com/blog
