I'm trying to execute an oracle function and get back a result.
I have a question about configuring the send port.
I only have one action in the SOAP action header:
<BtsActionMapping xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<Operation Name="FUNCTION_AP_INVOICES_INTERFACE" Action="http://Microsoft.LobServices.OracleDB/2007/03/AMCCUST/Function/FUNCTION_AP_INVOICES_INTERFACE" />
</BtsActionMapping>
Do I need a separate action to get the result?
Should I set the pipelines to xml or pass through?
If I don't need a separate action is the name of the operation important? It has to match between the send port and the orchestration.
Is there a good reference for how this works?
Do I need a separate action to get the result?
No
Should I set the pipelines to xml or pass through?
XML
If I don't need a separate action is the name of the operation important? It has to match between the send port and the orchestration.
You need to set the name of the Operation object in the logical send port to the same name as the BTSActionParameter in the WCF-Custom configuration of the physical send port. Be careful to set the "Operation" object name NOT the "Operation Message" object names!
Related
I have a JSP-type servlet that registers a WebSocket Endpoint with the Servlet container.
I want to pass a reference of that servlet, and/or some of its objects, to the WebSocket Endpoint, so that I can use the code from that servlet, e.g. for Authentication or Session management (the servlet has its own non-Java EE Session management).
I was hoping that I could set some attribute somewhere when I call addEndpoint() on ServerContainer, because at that point I have access to the objects that I want to use later, but none of the classes that I've seen at that point have an attribute collection, e.g.
objectThatWillBeAvailableAtWebSocket.addAttribute("some.custom.object", someObject);
By the time my code reaches an ServletRequestListener, ServerEndpointConfig.Configurator, or the registered Endpoint, I do not have any reference to the original servlet that added the Endpoint.
How can I pass an Object to the WebSocket servlet? I'm running my test code in Embedded Jetty, but I'm aiming for Container-agnostic code.
Is there a way to test a choice router for the following scenario which is based on the http.status? I am seeking a way to test the first condition of the router
<flow>
<choice>
<when expression="#[message.inboundProperties['http.status'] !=201">
......
<otherwise>
.....
</otherwise>
</choice>
</flow>
I want to verify that a javax.ws.rs.core.Response with can be correctly handled by the HTTP endpoint.
The flow doesn't have an inbound endpoint (thus it's a private flow) so to test it
create a test flow in a test XML config file that you will load side by side with your other Mule configuration XML files,
add an inbound VM endpoint to this test flow and make it call the private flow you want to test,
in your functional test case, use the Mule Client to dispatch a test message over the VM endpoint, setting properties on this test message that will end-up as inbound properties in the private flow.
I have some problems in the next situation:
I have wso2esb and a there is proxy-service in the esb.
I call this proxy with parameters with parameter, e.g.
http://host:9643/service/myproxy?domain=first.
After that my proxy need to get to the next endpoint: http://first.mysite.com
if we have http://host:9643/service/myproxy?domain=second we will have to get to the http://second.mysite.com
You get your parameter inside the proxy service using.
<property name="domain" value="application/x-www-form-urlencoded" scope="axis2"/>
And then you need to use switch mediator inside proxy service's insequence and then based on the case you need use send mediator to send the message to required endpoing.
This will be helpful to understand the scenario.
http://docs.wso2.org/wiki/display/IntegrationPatterns/Dynamic+Router
Getting following error after hosting WCF Service in IIS.
HTTP Error 500.0 - Internal Server Error. The page cannot be displayed
because an internal server error has occurred.
Module IsapiModule
Notification ExecuteRequestHandler
Handler svc-ISAPI-4.0_32bit
Error Code 0x00000000
It is HTTPS having a secure certificate WCF Service.
Please help me to solve this problem.
It can be caused by many different things. You should try the following solutions:
1 First way
Right click the folder where your site is located: "C:\Users\NAME\SiteName" and select Properties.
Select the Security tab and click on Edit.
Add.. and type in "IIS_IUSRS".
2 Second way
By default, WCF Service OperationContracts can only be invoked using an HTTP POST. When you call open() on the Titanium HTTPClient, are you specifying a GET or POST for HTTP method parameter?
Secondly, since your service binding is using SOAP 1.1, you need to pass a SOAPAction header in your request so that WCF can route the message to the GetData method. If an Action parameter is not specified in the service's OperationContract attribute, the Action should be the method name preceded by the namespace and service contract name (probably http://tempuri.org/IService1/GetData if you're using what the default WCF application created). You'll also need to specify a content-type. So, you'd need to setup your xhr like this prior to calling send:
xhr.setRequestHeader('Content-Type', 'text/xml; charset=utf-16');
xhr.setRequestHeader('SOAPAction',
'"http://tempuri.org/IService1/GetData"'); xhr.send(s); Also, you can
explicitly specify an action for a WCF service operation:
[OperationContract(Action = "MyAction")] string GetData() {
// ...snip... }
xhr.setRequestHeader('SOAPAction', '"MyAction"');
And lastly, you can allow service operations to be invoked via an HTTP GET by decorating the method with the [WebGet] attribute. This allows the operation to be called in REST fashion: http://msdn.microsoft.com/en-us/library/system.servicemodel.web.webgetattribute.aspx
Is it possible to invoke sftp outbound endpoint, and send a file, through the code?
I have a reference to a File object in java code (in a custom transformer), and I want to invoke sftp outbound endpoint and pass that File reference. Is this doable?
Thanks.
Pass it a FileInputStream, that should work.
muleContext.getClient().dispatch("sftp://...", new FileInputStream(file), null);
If not, you'll have to pass it a byte[].
Note that dispatch is asynchronous: the call will return immediately while the SFTP communication occurs. if you want to wait until it's done, use send with a time-out as last parameter.
Since you have several SFTP connectors configured, you'll have to specify the connector name in the URL. Supposing you want to dispatch using SFTP_Upload_Connector, you'll have to use:
muleContext.getClient().dispatch("sftp://...?connector=SFTP_Upload_Connector", new FileInputStream(file), null);
If you want to set a particular destination file name, pass it as a property named filename in the properties map, for example using:
muleContext.getClient().dispatch("sftp://...?connector=SFTP_Upload_Connector", new FileInputStream(file), Collections.singletonMap("filename", "somen_ame"));