[JBossWS] - JbossWS fails when using wsdlLocation and generated WSDL
by Artur Signell
Hi,
I have a simple webmethod such as the one below, taking an array as an argument. This works fine as long as I remove the "wsdlLocation" specification.
| @WebService(name = "WSDLTest", targetNamespace = "namespace", wsdlLocation = "META-INF/wsdl/WSDLTest.wsdl")
| @SOAPBinding(style = SOAPBinding.Style.RPC, use = SOAPBinding.Use.LITERAL)
| @Stateless
| public class WSDLTest {
|
| @WebMethod(operationName = "testMethod", action = "testMethod")
| public void testMethod(
| @WebParam(name = "binaryData") BinaryData[] binaryData)
| throws Exception {
|
| System.out.println("OK");
|
| }
|
| }
|
However, when I save the JBossWS-generated wsdl to a file and tell JBossWS to use it using the "wsdlLocation" parameter, I get the following error:
| Caused by: org.jboss.xb.binding.JBossXBRuntimeException: Failed to resolve class name for {namespace}value: No ClassLoaders found for: java.lang.BinaryData
| at org.jboss.xb.binding.sunday.unmarshalling.impl.runtime.RtElementHandler.loadClassForTerm(RtElementHandler.java:1050)
| at org.jboss.xb.binding.sunday.unmarshalling.impl.runtime.RtElementHandler.classForNonArrayItem(RtElementHandler.java:1379)
| at org.jboss.xb.binding.sunday.unmarshalling.impl.runtime.RtElementHandler.classForElement(RtElementHandler.java:857)
| at org.jboss.xb.binding.sunday.unmarshalling.impl.runtime.RtElementHandler.startElement(RtElementHandler.java:460)
| ...
|
BinaryData is a simple dataclass containing only an integer and methods for setting and getting it. It resides in the webservice.data-package but is for some reason searched for in the java.lang package where the Exception is defined (defining an own exception in another package changes "java.lang" to the package name where the exception is defined).
JBossWS version is 1.0.3.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3975664#3975664
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3975664
19 years, 7 months
[JBossCache] - Re: Caching for Web services?
by zzzz8
Hi Manik,
Thanks for the reply.
I have an application (JEE app - running on Tomcat/EJB3 embedded/Seam) that acts as a Web services client. I use JAX-RPC's wscompile (will upgrade to JAX-WS/wsimport in the near future) to generate the client side source code. The app does tend to invoke the Web services operations fairly frequently, so it would be nice to have some sort of client side cache. I currently don't need to cluster/share state, so a local-type cache is OK for me (for now - although I may want to have some sort of replicated cache in the future).
I have recently read some of the JBoss Cache documentation and I believe I may have some ideas as to how to implement this (please tell me if I'm way off or on target).
Because wscompile/wsimport generate source code files that are used by the Web services client, I could possibly aspectize certain source code files generated by wscompile/wsimport. It might be a little annoying to write the jboss-aop.xml file... I have figure out which files to aspectize and how to use the pointcut language to only aspectize those source code files involved in the response messages (and any related classes used in these response classes). I would only aspectize the response message classes since there should be no need to aspectize the request message classes. I'm also assuming these source code files could be aspectized (I'm not sure if there are any limitations in aspectizing the wsimport/wscompile generated source code files)...
I think once I aspectize these files (hopefully correctly), it would seem to be fairly straightforward to use the PojoCache... I probably need to learn a little bit more about PojoCache though. The toughest thing seems to be the configuration file, which really confused me. I couldn't find any definitive documentation on the XML config file (perhaps I missed it).
It would be nice if there was a less intrusive way of caching Web services - perhaps via JAX-WS handlers (that might be uglier) or if JBoss Cache were better integrated with JAX-WS/JAX-RPC.
Again, thanks for the assistance.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3975659#3975659
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3975659
19 years, 7 months
[Clustering/JBoss] - Re: Need help trying to expose singleton mbean interface to
by bstansberry@jboss.com
Sorry for a very late reply; probably won't help you but may help others.
HA-JNDI provides two functions:
1) A global replicated tree. Objects bound into this tree (by a client that creates an InitialContext that connects to HA-JNDI) are replicated across the cluster and can be seen in the jmx-console's global jndi namespace on any node.
2) An ability to query the regular, non-replicated jndi tree on any node in the cluster. Thus things bound on any one node can be looked up by connecting to the HA-JNDI server running on any node in the cluster. This is actually the more important function, but it's less intuitively understood. The jmx-console doesn't show objects accessible this way in the global jndi namespace. They only appear in jmx-console in the regular jndi namespace on the server(s) where they are bound. But this doesn't mean a client doing a lookup via HA-JNDI can't find them.
Your RMIAdaptor is bound in local JNDI on the singleton master node, and thus isn't visible in the global jndi namespace. But it can be looked up via HA-JNDI.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3975655#3975655
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3975655
19 years, 7 months