This service will be undergoing maintenance at 00:00 UTC, 2016-08-01. It is expected to last about 1 hours
Bug 780432 - (SOA-2865) CXF: OneWay methods called through webservice producer throws exception when accessing to SOAPProcessor.getMessage()
CXF: OneWay methods called through webservice producer throws exception when ...
Status: CLOSED NEXTRELEASE
Product: JBoss Enterprise SOA Platform 5
Classification: JBoss
Component: Documentation, JBossESB (Show other bugs)
5.1.0.ER8
Unspecified Unspecified
urgent Severity urgent
: ---
: 5.2.0 GA
Assigned To: Magesh Bojan
http://jira.jboss.org/jira/browse/SOA...
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2011-02-02 04:43 EST by Jiri Pechanec
Modified: 2011-11-15 03:54 EST (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2011-11-15 03:54:14 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
JBoss Issue Tracker JBESB-3567 Major Closed Remove thread local use within SOAPProcessor 2015-12-14 07:36 EST
JBoss Issue Tracker SOA-2865 Blocker Closed CXF: OneWay methods called through webservice producer throws exception when accessing to SOAPProcessor.getMessage() 2015-12-14 07:36 EST

  None (edit)
Description Jiri Pechanec 2011-02-02 04:43:51 EST
project_key: SOA

Try webservice_producer, message_02, and add a line to @OneWay method - System.out.println("ESB Message: " + SOAPProcessor.getMessage());

in server you will see the exception

10:37:05,422 WARNING [PhaseInterceptorChain] Application {http://webservice_producer/goodbyeworld}GoodbyeWorldWSService#{http://webservice_producer/goodbyeworld}sayGoodbyeWithoutResponse has thrown exception, unwinding now
org.apache.cxf.interceptor.Fault: ESB message not found!
	at org.jboss.wsf.stack.cxf.AbstractInvoker.createFault(AbstractInvoker.java:209)
	at org.jboss.wsf.stack.cxf.AbstractInvoker._invokeInternal(AbstractInvoker.java:174)
	at org.jboss.wsf.stack.cxf.AbstractInvoker.invoke(AbstractInvoker.java:104)
	at org.apache.cxf.interceptor.ServiceInvokerInterceptor$1.run(ServiceInvokerInterceptor.java:58)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
	at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
	at java.util.concurrent.FutureTask.run(FutureTask.java:166)
	at org.apache.cxf.workqueue.SynchronousExecutor.execute(SynchronousExecutor.java:37)
	at org.apache.cxf.interceptor.ServiceInvokerInterceptor.handleMessage(ServiceInvokerInterceptor.java:106)
	at org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:243)
	at org.apache.cxf.phase.PhaseInterceptorChain.resume(PhaseInterceptorChain.java:218)
	at org.apache.cxf.interceptor.OneWayProcessorInterceptor$1.run(OneWayProcessorInterceptor.java:100)
	at org.apache.cxf.workqueue.AutomaticWorkQueueImpl$2.run(AutomaticWorkQueueImpl.java:253)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
	at java.lang.Thread.run(Thread.java:636)
Caused by: java.lang.RuntimeException: ESB message not found!
	at org.jboss.soa.esb.actions.soap.SOAPProcessor.getMessage(SOAPProcessor.java:349)
	at org.jboss.soa.esb.samples.quickstart.webserviceproducer.webservice.GoodbyeWorldWS.sayGoodbyeWithoutResponse(GoodbyeWorldWS.java:41)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:616)
	at org.jboss.wsf.container.jboss50.invocation.InvocationHandlerJSE.invoke(InvocationHandlerJSE.java:120)
	at org.jboss.wsf.stack.cxf.AbstractInvoker._invokeInternal(AbstractInvoker.java:154)
	... 14 more

the issue is not present with two way messages.
Comment 1 Kevin Conner 2011-02-02 09:09:34 EST
The use of thread locals to pass ESB messages to invoked webservices is inherently broken and should be removed from the ESB codebase.

Any webservice stack is free to move one way invocations onto a separate thread, responding immediately on the original thread to the invoker.

This is what CXF has chosen to do in this instance.
Comment 2 Kevin Conner 2011-02-02 09:17:28 EST
I have created JBESB-3567 to have this functionality removed but, for this release, I believe we should add something to the documentation to state that this is not supported as part of a one way invocation and that it will be removed in a future release.
Comment 3 Anne-Louise Tangring 2011-04-01 12:53:51 EDT
This needs to be marked Deprecated. Make sure it is properly documented. 
Comment 4 tcunning 2011-04-12 17:21:04 EDT
Link: Added: This issue relates to JBESB-3567
Comment 5 tcunning 2011-08-15 09:49:15 EDT
Magesh, if you've already made the changes here to documentation (I saw there were edits on the Programmer's Guide on the linked ESB issue) can you set this one to resolved?    Thanks.
Comment 6 Magesh Bojan 2011-08-23 08:48:12 EDT
Release Notes Text: Added: Documentation regarding the SOAPProcessor.getMessage has been removed as part of JBESB-3567.
Comment 7 David Le Sage 2011-09-02 01:46:05 EDT
Release Notes Docs Status: Added: Not Required
Writer: Added: dlesage
Comment 8 Martin Vecera 2011-11-15 03:54:14 EST
Verified.

Note You need to log in before you can comment on or make changes to this bug.