| View previous topic :: View next topic |
| Author |
Message |
soasoa
Joined: 26 Feb 2010 Posts: 12
|
Posted: Fri Feb 26, 2010 11:42 am Post subject: Service which provide Endpoint to others |
|
|
Hello everyone.
I am very new SOA. It's very possible I write something wrong.
I'm doing a SOA project of several services using BPEL for orchestration.
Logically, I dont know the endpoints of these services, but presumably should not
be a problem for dynamically modified as indicated here:
http://docs.sun.com/app/docs/doc/821-0017/cnfg_bpel-se-dynamic-ptnrlink_c?a=view
To avoid having the service URL hard-coded into literal or accessing
by DB query, I thought implement another support service which receives an id and
return an EndpointReference object who may be assigned to the Partner Link.
Why? Because I would like have a logistic service in which delegate the resolution of EPR.
I dont know if this is a good idea but I get the following error:
"A valid SOAPAction should be set in the RequestContext when Addressing is enabled,
Use BindingProvider.SOAPACTION_URI_PROPERTY to set it. "
My service provider of Endpoint only has this:
| Code: |
W3CEndpointReferenceBuilder builder =
new W3CEndpointReferenceBuilder ();
builder.address (http://10.10.10.10:1010/hello/hello ");
builder.build return ();
|
Let's see if someone can help me.
Thank you very much, greetings.[/code] |
|
| Back to top |
|
 |
Daoud AbdelMonem Faleh Posted via mailing list.
|
|
| Back to top |
|
 |
soasoa
Joined: 26 Feb 2010 Posts: 12
|
Posted: Sun Feb 28, 2010 12:48 pm Post subject: |
|
|
Thank you very much for your reply.
I still have trouble finding what I want.
For example, this error:
"Caused by: BPJBI-6019:unable to resolve the service endpoint dynamically for the document fragment"
No matter that returns in my service java.net.Uri, java.net.URL or W3EndpointReference.
No matter that in bpel I assign values to wsa:EndpointReference and later mapping EPR to PartnerLink.
I tried all possible combinations of types and assign...
In fact, if I forget the URLProviderWebService and try this:
literal --> EPR variable and later EPR variable --> PartnerLink
| Code: |
<assign name="initEPR">
<copy>
<from><literal><service-ref>
<wsa:EndpointReference>
<wsa:Address>
http://localhost:8080/MyBpel_WSDLServiceMyBpel_WSDLPort</wsa:Address>
<wsa:ServiceName
xmlns:ns4="http://j2ee.netbeans.org/wsdl/MyBpel_WSDL"
PortName="MyBpel_WSDLPort">
ns4:MyBpel_WSDLService
</wsa:ServiceName>
</wsa:EndpointReference>
</service-ref></literal></from>
<to>$EPR/wsa:EndpointReference</to>
</copy>
</assign>
|
I get same error, so I think the problem is not in type (Uri, URL, W3CEndpointReference) that I return in my Web Service.
any idea, please?
Thanks again [/code] |
|
| Back to top |
|
 |
soasoa
Joined: 26 Feb 2010 Posts: 12
|
Posted: Sun Feb 28, 2010 3:10 pm Post subject: |
|
|
And this is the fragment that "unable to resolve"
| Code: | <?xml version="1.0" encoding="UTF-8"?>
<EPR xmlns="http://j2ee.netbeans.org/wsdl/PeticionExterna" xmlns:sref="http://docs.oasis-open.org/wsbpel/2.0/serviceref">
<wsa:EndpointReference xmlns:bpws="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
xmlns:ns1="http://j2ee.netbeans.org/wsdl/PeticionExterna"
xmlns:ns2="http://www.w3.org/2005/08/addressing"
xmlns:ns3="http://docs.oasis-open.org/wsbpel/2.0/process/executable"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:sxed="http://www.sun.com/wsbpel/2.0/process/executable/SUNExtension/Editor"
xmlns:sxt="http://www.sun.com/wsbpel/2.0/process/executable/SUNExtension/Trace"
xmlns:tns="http://enterprise.netbeans.org/bpel/Orquestacion/principal"
xmlns:wsa="http://schemas.xmlsoap.org/ws/2004/08/addressing"
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<Address xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing">
http://localhost:8080/MyBpel_WSDLServiceMyBpel_WSDLPort
</Address>
<ServiceName xmlns="http://schemas.xmlsoap.org/ws/2004/08/addressing"
xmlns:ns4="http://j2ee.netbeans.org/wsdl/MyBpel_WSDL"
PortName="MyBpel_WSDLPort">ns4:MyBpel_WSDLService
</ServiceName>
</wsa:EndpointReference>
</EPR>[quote][/quote] |
|
|
| Back to top |
|
 |
Daoud AbdelMonem Faleh Posted via mailing list.
|
Posted: Sun Feb 28, 2010 6:56 pm Post subject: Re: Service which provide Endpoint to others |
|
|
I was looking for the same thing when stumbled upon the link I gave,
sorry hasn't coded anything yet.
If you find a way to achieve the dynamic routing please let me know.
Thanks.
soasoa a |
|
| Back to top |
|
 |
soasoa
Joined: 26 Feb 2010 Posts: 12
|
Posted: Mon Mar 01, 2010 5:19 pm Post subject: |
|
|
Dont worry about this.
When I find how to solve it, I'll tell you. Hope you get it and tell me too
Thanks again.
PS: The worst is not this ... it's read hundreds of forums and none fix me anything. |
|
| Back to top |
|
 |
soasoa
Joined: 26 Feb 2010 Posts: 12
|
Posted: Thu Mar 04, 2010 8:13 pm Post subject: |
|
|
Hello! I have news...
Everything I did last week was in ESB 2.1 and Netbeans 6.5
Today, I tried with ESB 2.2 and Netbeans 6.7
Well....I got it using NM Properties.
First, I init an EndpointReference variable.
Later, I invoke my URLProviderService and it get me the correct URL.
Later, I assign that URL to my EPR variable.
Tha last step is the conflictiv: ESB 2.1 fail and ESB 2.2 is working.
The difference is that 2.2 has NM Property, and I put this code:
| Code: |
<copy>
<from>$EPR/wsa:EndpointReference/wsa:Address</from>
<to variable="MyBpel_WSDLOperationIn"
sxnmp:nmProperty="org.glassfish.openesb.outbound.address.url"/>
</copy>
|
I' try to fix my problem in ESB 2.1 (I suppose....)
Any help for me ?
Thanks again |
|
| Back to top |
|
 |
soasoa
Joined: 26 Feb 2010 Posts: 12
|
Posted: Sat Apr 10, 2010 4:39 pm Post subject: |
|
|
I Edit this message...
I've got it works fine in ESBv2.1...
I've made again the orchestation process....and now it seems go!
I put my code for somebody who need it.
| Code: |
<assign name="setEPR">
<copy>
<from>$GetUriOut.parameters/return</from>
<to>$EPR/wsa:EndpointReference/wsa:Address</to>
</copy>
</assign>
<assign name="assignParams">
<copy>
<from>$EPR/wsa:EndpointReference/wsa:Address</from>
<to variable="MiBpel_WSDLOperationIn"
sxnmp:nmProperty="org.glassfish.openesb.outbound.address.url"/>
</copy>
</assign>
|
|
|
| Back to top |
|
 |
markwright789
Joined: 30 May 2011 Posts: 15
|
Posted: Mon May 30, 2011 9:20 am Post subject: |
|
|
| To avoid having the serve URL hard-coded into literal or accessing by DB query, I thought implement another support service which receives an id as well as return an EndpointReference object who may be allotted to the Partner Link. |
|
| Back to top |
|
 |
|