Bug 779199 (SOA-1593)

Summary: WebService Proxy - Not all components supports classpath URI
Product: [JBoss] JBoss Enterprise SOA Platform 5 Reporter: Jiri Pechanec <jpechane>
Component: JBossESBAssignee: Kevin Conner <kevin.conner>
Status: CLOSED NEXTRELEASE QA Contact:
Severity: high Docs Contact:
Priority: high    
Version: 5.0.0 ER2   
Target Milestone: ---   
Target Release: 5.0.0 GA, 5.0.0 ER8   
Hardware: Unspecified   
OS: Unspecified   
URL: http://jira.jboss.org/jira/browse/SOA-1593
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
ER4 Fedora release 10 (Cambridge): 2.6.27.38-170.2.113.fc10.i686 #1 SMP Wed Nov 4 17:55:39 EST 2009 i686 i686 i386 GNU/Linux PostgreSQL 8.3.8 java version "1.6.0_14" Java(TM) SE Runtime Environment (build 1.6.0_14-b08) Java HotSpot(TM) Server VM (build 14.0-b16, mixed mode)
Last Closed: 2010-02-12 09:14:41 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
cp.zip none

Description Jiri Pechanec 2009-11-12 10:05:04 UTC
Complexity: Medium
Date of First Response: 2009-12-02 05:50:13
project_key: SOA

WebService Proxy actions provides a special URL named for loading a WSDL from classpath (ESB archive). Unfortunately not all other components can handle it
SOAPProxyWsdlContractPublisher 
10:59:02,134 ERROR [AbstractWsdlContractPublisher] Failed to load WSDL contract information from WS Endpoint 'classpath:///HelloWorldWS.wsdl'.
java.lang.NullPointerException
        at org.jboss.soa.esb.actions.soap.proxy.SOAPProxyWsdlContractPublisher.getWsdl(SOAPProxyWsdlContractPublisher.java:60)
        at org.jboss.soa.esb.actions.soap.AbstractWsdlContractPublisher.getContractInfo(AbstractWsdlContractPublisher.java:141)
WsdlEndpointTransformer - there can be issues with import transformation

I suggest either fix this problems or document that using classpath URL is not supported for all features offered by ESB

Comment 1 trev 2009-12-02 10:50:13 UTC
Jirka can you please provide an example for kconner

Comment 2 Jiri Pechanec 2009-12-04 11:59:10 UTC
Deploy the example, go to ESB Service list page and click on contract for InVM endpoint

Comment 3 Jiri Pechanec 2009-12-04 11:59:10 UTC
Attachment: Added: cp.zip


Comment 4 Kevin Conner 2009-12-07 11:03:25 UTC
Link: Added: This issue depends JBESB-3034


Comment 5 David Ward 2009-12-08 20:28:32 UTC
Jiri, can you please describe in detail your environment (OS, JDK vendor + version)?  The reason is that using your example as is, I can't reproduce this on the JBESB_4_7_CP branch, using either Sun JDK 1.5.0_22 or 1.6.0_17 on Fedora 11 (Linux 2.6.30.9-99.fc11.i686.PAE).

How old is SOA-P 5.0.0 ER2?  According to https://svn.devel.redhat.com/repos/jboss-soa/trunk/build-tools/dependencies.properties , it appears there is an ER5 built from ESB 4.7?  Can you try again with that?

Also, if someone can give me instructions for creating a SOA-P 5 distro from source, I'd appreciate it.  Thanks.

Comment 6 David Ward 2009-12-08 20:30:32 UTC
Nevermind that last question.  I found it here: https://svn.devel.redhat.com/repos/jboss-soa/build-team-tags/SOA-5.0.0.ER5/build-tools/README.TXT

Comment 7 David Ward 2009-12-08 22:00:49 UTC
So, after 41 minutes, the ER5 build barfed on me in the jbpm section.  Is ER5 supposed to build?  Maybe I should try ER4?  I'm gonna hold off until I hear back on my other questions.

Comment 8 Jiri Pechanec 2009-12-09 06:39:52 UTC
I have reproduced it on ER5 too

Comment 10 David Ward 2009-12-09 17:07:50 UTC
Okay, I don't know why I didn't think of this before. When I was said above I couldn't reproduce this on the JBESB_4_7_CP branch, it was because I was deploying ESB into JBoss AS 4.2.3, where both the HTTP and INVM wsdl is available through the contract JSP app. However, once I downloaded and tried on ER5, I was quickly reminded that SOA-P 5 uses JBoss AS 5.1, and I was able to reproduce it. I then went back to the JBESB_4_7_CP branch and was able to reprodue it so long as I deploy to AS 5.1 (not 4.2.3). The HTTP wsdl is still available through the contract JSP app, but the INVM wsdl is not.

I believe the problem is classloading visibility. In the contract JSP app, when clicking on the INVM wsdl link, the classloader of the web tier is used to lookup the classpath URL resource of "helloworld.wsdl". This is no problem on AS 4.2.3, most likely because of the behavior of the UnifiedClassLoader. However, on AS 5.1, classloading is obviously different, so the URL resource cannot be found. One would have to use the classloader of the deployed esb archive, I would assume (as that's where helloworld.wsdl lives).

But why does the HTTP wsdl link work through the contract JSP app, no matter if AS 4.2.3 or 5.1 is used? Because during the esb archive deployment, when the HttpGatewayServlet is initialized, the wsdl is obtained using the ContractProviderLifecycleResource, which handles it.

Now what to do about the INVM wsdl link. Hmmm...

Comment 11 Kevin Conner 2009-12-09 17:36:06 UTC
Can we move this to the forums and discuss?

Comment 13 David Ward 2009-12-09 18:23:17 UTC
JBoss Forum Reference: Added: http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4269844
Complexity: Added: Medium


Comment 14 David Ward 2010-01-19 19:56:56 UTC
Please test now that JBESB-3034 is closed.  Thank you.

Note: Because of the decision made to go along with the workaround describedin JBESB-2913 / SOA-1552, we only have to worry about this with regard to HTTP-based contracts.

Comment 15 Jiri Pechanec 2010-02-12 09:14:41 UTC
Verified in CR1