[JBossWS] - WSException: Cannot obtain endpoint
by froden
Hi,
I'm having some problems integrating JBossWS 1.2.1 into our webapp using Seam 1.2.1 on Tomcat 5.5.23.
I downloaded jbossws-1.2.1.GA.zip and copied the jars as specified here http://jbws.dyndns.org/mediawiki/index.php?title=Install_Tomcat into tomcat's common/libs and common/endorsed. I also copied the jbossws.war into tomcat's webapp directory. So far so good, the jbossws webapp is working and I can deploy the samples from jbossws-samples-1.2.1.GA by dragging their wars into jbossws-deploy.
I then proceeded to try and add a webservice to our already existing web application.
This is the class I wish to expose as a web service:
package services;
|
| import javax.jws.WebMethod;
| import javax.jws.WebService;
| import javax.jws.soap.SOAPBinding;
|
| @WebService (name="TestService")
| @SOAPBinding(style = SOAPBinding.Style.RPC)
| public class TestService {
|
| @WebMethod
| public String feedback() {
| return "Hello from ws;
| }
| }
I've added the following to my web.xml
<?xml version="1.0" encoding="UTF-8"?>
|
| <web-app version="2.5"
| xmlns="http://java.sun.com/xml/ns/javaee"
| xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
| xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
|
| <servlet>
| <servlet-name>TestService</servlet-name>
| <servlet-class>org.jboss.ws.integration.tomcat.TomcatServiceEndpointServlet</servlet-class>
| </servlet>
| <servlet-mapping>
| <servlet-name>TestService</servlet-name>
| <url-pattern>/TestService.ws</url-pattern>
| </servlet-mapping>
|
| </web-app>
As you can see, I've removed pretty much anything else from web.xml, trying to isolate the problem.
Now, from what I've seen in the samples, dropping the war into the jbossws-deploy directory causes the jbossws system to modify web.xml and add an ServiceEndpointImpl init-param to each web service servlet. In my case, it should be something like this:
| <init-param>
| <param-name>ServiceEndpointImpl</param-name>
| <param-value>services.TestService</param-value>
| </init-param>
This doesn't happen.
When I try to view the service (localhost:8080/MyApp/TestService.ws) it gives me the following exception:
anonymous wrote : ERROR org.apache.commons.logging.impl.Log4JLogger (Log4JLogger.java:119) - Servlet.service() for servlet TestService threw exception
| org.jboss.ws.WSException: Cannot obtain endpoint for: jboss.ws:context=MyApp,endpoint=TestService
| at org.jboss.ws.core.server.AbstractServiceEndpointServlet.initServiceEndpoint(AbstractServiceEndpointServlet.java:161)
| at org.jboss.ws.core.server.AbstractServiceEndpointServlet.service(AbstractServiceEndpointServlet.java:73)
| at org.jboss.ws.integration.tomcat.TomcatServiceEndpointServlet.service(TomcatServiceEndpointServlet.java:99)
| at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:269)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
| at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:210)
| at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:174)
| at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
| at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
| at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:108)
| at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:151)
| at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:870)
| at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:665)
| at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:528)
| at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81)
| at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:685)
| at java.lang.Thread.run(Thread.java:595)
|
This happens also if I add the init-param manually.
Any ideas what I might be missing here?
- Frode
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4117942#4117942
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4117942
18 years, 3 months
[JBoss Messaging] - Re: LocalTx, ClientTransaction leak?
by ydzsidemiik
I've studied the GC root paths for some of these objects, they all look like this:
| org.jboss.jms.tx.ClientTransaction
| <- value of EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap$Entry
| <- [287] of EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap$Entry[1025]
| <- table of EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap
| <- transactions of org.jboss.jms.tx.ResourceManager
| <- resourceManager of org.jboss.jms.client.state.ConnectionState
| <- parent of org.jboss.jms.client.state.SessionState
| <- parent of org.jboss.jms.client.state.ConsumerState
| <- state of org.jboss.jms.client.delegate.ClientConsumerDelegate [Stack Local]
|
Where the stack local is reported to be on the stack of 'Connection Consumer for dest JBossQueue[...]', which is a thread feeding an MDB.
I've collected allocation traces for some of these objects as well, and they all look like this:
| org.jboss.resource.connectionmanager.xa.JcaXAResourceWrapper.end(Xid, int)
| com.arjuna.ats.internal.jta.transaction.arjunacore.TransactionImple.delistResource(XAResource, int)
| org.jboss.resource.adapter.jms.JmsSession.close()
| ... earlier frames vary ...
|
It's strange that the traces cut off there since (looking at the source), no allocations occur in that function. However, I tried to figure out where the trace went from there and my guess is something like MessagingXAResource.end -> MessagingXAResource.unsetCurrentTransactionId -> ResourceManager.createLocalTx, which seems to be a plausible source of these allocations.
I don't know where to go from here. Please help :(
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4117935#4117935
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4117935
18 years, 3 months
[JBoss Seam] - Creating a simple selectOneMenu
by felixk2
Hi,
I'm trying to use a selectOneMenu for a String property in an Entity. For example I have an entity with:
@NotNull
| @Column(name="Status")
| @Length(max=16)
| private String status;
Instead of using a textbox for users to fill in this field i'd like to use a drop down with values that I populate. So I created the following h:selectOneMenu:
<s:decorate template="layout/edit.xhtml">
| <ui:define name="label">Status</ui:define>
| <h:selectOneMenu value="#{customerHome.instance.status}">
| <f:selectItem itemLabel="Active" itemValue="Active"/>
| <f:selectItem itemLabel="Inactive" itemValue="Inactive"/>
| </h:selectOneMenu>
| </s:decorate>
This works fine for submitting of the form. The selected itemValue will end up in the database. But when I want to view the data the proper selectItem is never selected. I know for example that #{customerHome.instance.status} contains the string "Inactive" but the form shows "Active".
Any ideas how to fix that?
Thanks,
Felix
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4117934#4117934
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4117934
18 years, 3 months