WSO2 ESB Clustering Architectural configuration - wso2

i have a question about an architectural solution feasibility using WSO2.
This is my scenario:
I have a Web Service REST exposing some functionalities
I have the WSO2 ESB
I have a client layer (Liferay)
the architecture i want to develop is the one showed in the first image:
http://s11.postimg.org/gu6b6k3zn/Immagine.png
1) Liferay clients send request to avail one functionality
2) WSO2 ESB (clustered) get the client request... and (as a proxy) redirects it to che tomcat server by using load balancing mechanism
3) Web service on tomcat receives the request and answers to it
Studying the WSO2 documentation i saw the configuration showed in the img 2 dealing with esb clustering and load balancing
http://s17.postimg.org/tuy885gzz/Immagine2.png
As i can see, in this case the Tomcat Application Server(inside WSO2 AS) is embedded inside the WSO2 ESB, so i have to deploy my REST WS into the WSO2 esb, and then clustering it.
I want to ask if the second solution is the only permitted or if i can obtain my first architectural solution in which the tomcat instances are decoupled from the ESB instances on a third (physically separated) layer.

In image 2, (http://s17.postimg.org/tuy885gzz/Immagine2.png), it is shown a Fail over scenario, where when the Primary ESB node goes down, the requests will be routed to backup node 2.
Even if you want to deploy something like in image 2, you can have the WSO2 AS layer sitting behind the ESB server layer. There you can deploy your REST WS. The REST WS can be fronted by a proxy in your ESB. And the proxy can be accessed by your life ray client.

Related

Testing Applications for use of Web Services

1) Is it possible using burp suite/ ZAP or any other web testing tools to find out
if an application is making calls to web services?
2) As SOAP web services reply in XML is it also possible to view the responses of
the HTML request to distinguish between use of REST web services?
Thanks
Yes, this is normally possible.
You need to configure the application to use the interactive proxy (Burp, Zap, etc.) as its proxy. Most applications will use your system proxy settings.
Once the proxy is configured, you can see a full history of HTTP interactions (in Burp: Proxy > HTTP History). This includes requests and responses, which will clearly indicate a SOAP or REST service.

How to create data service with local transport using proxy?

I have created data service using WSO2 DSS which is called by proxy service.
Everything works smoothly, but this DSS service is also visible to internet.
Now I would like to hide this DSS so proxy service is so only way to use this service.
Proxy has security, logging etc.
As far as I understand local transport is good and efficient way to keep
traffic between services internal on WSO2.
Everything goes as expected but when I try to set WSDL URL or internal for proxy (which is DSS service WDSL) I get error "Unable to modify proxy service :: Unable to modify proxy service: mylogtest-ProxyServiceAdminProxyAdminException".
In log file there is error "Caused by: org.apache.synapse.SynapseException: Error building service from WSDL" and "Caused by: org.apache.axis2.AxisFault: there is no service with ports to pick".
I get this error when I have local transport only in DSS.
If I add http transport, everything works. Proxy has http and https transports.
Local transport works only inside a single JVM. I guess here you are running DSS and ESB separately i.e. with two jvm instances - if so it won't work. The solution is to install DSS features inside the ESB and then run it (without running the DSS separately). You can find the feature installation guide here: http://docs.wso2.org/display/Carbon420/Installing+Features+via+the+UI
I had incorrectly formed WSDL for proxy. Very novice error.

mule versioning on web service

I have the same mule webservice application with 2 different versions deployed on the same mule server. Let's call it MuleApp.1.0 and MuleApp.1.1. The flow is as simple as the example of webservice flow on mulesoft website. Their wsdl urls are different as:
http://www.myhost.com:25101/MuleApp.1.0/Service?wsdl
http://www.myhost.com:25101/MuleApp.1.1/Service?wsdl
Both of them are working as expected when the other is not deploying on the mule server. The issue happens when I having both of them deployed on the same mule server like what I used to do in WebLogic. Now I am able to access MuleApp.1.1, but when I tried to access MuleApp.1.0, I got the error as below
07-Mar-2013:14:52:57.142 VWILVM3667 [MuleApp.1.1].connector.http.mule.default.receiver.03
WARN org.mule.transport.http.HttpMessageReceiver NA
No receiver found with secondary lookup on connector: connector.http.mule.default with URI key: http://www.myhost.com:25101/MuleApp.1.0/Service
This is supposed to be a very common versionning case. What did I miss in my config?
You can't have two different applications sharing the same HTTP port in the same Mule instance.
So what probably happens is that MuleApp.1.0 doesn't deploy properly (check the logs), which is why there is no endpoint listening on /MuleApp.1.0.
Either:
Use a different port in the two apps,
Put both flows in a single app.
Create a frontal app that listens on port 25101 and both /MuleApp.1.0 and /MuleApp.1.1 paths and that dispatches requests to MuleApp.1.0 and MuleApp.1.1 on private ports (say 25102 and 25103).
I finally deployed my application on tomcat, and replaced http inbound endpoint with servlet inbound endpoint. I configure the web.xml with servlet class org.mule.transport.servlet.MuleReceiverServlet. Now I am able to deploy multiple applications on the same port.

More than 1500 proxyes with JMS transport, WSO2 ESB 4.0.3 and Activemq

Is there developers who have been succeeded deployed to wso2 esb more than 1500 proxy services
with jms transport without any problems?
Criteria:
deploying process must be very fast
wso2esb use activemq client libraries and activemq brocker
someone please help me!
This should be possible. There is no limitation on the number of proxies that an ESB can have.
You may try this with using the hot deployment capabilities of WSO2 ESB.
You may create a bunch of proxy services and place them inside:
/repository/deployment/server/synapse-config/default/proxy-services
Then the proxies with get automatically deployed..
eg:
proxy_1.xml, proxy_2.xml, proxy_3.xml,..., proxy_1500.xml etc.
However, having this number of proxy services, gives some indication of some anti-pattern in your SOA. Please review whether you need this much of proxy services in your solution architecture.

Forwarding web services through JMS

I'm trying to figure out how to forward web service requests from the web server to a remote application server through jms.
In my architecture there are web services client which communicate with some web server (Tomcat) which needs to forward the request to be executed on a remote application server and at the end get the result and push it back to the web service client.
Something like:
Web Service Client <-> HTTP <-> Tomcat <-> JMS <-> Application Server.
I want to use jax-ws so my methods will be called automatically in the application server.
Although I've expected this will be common approach, I didn't find any examples.
I would appreciate if someone can provide some links or tips on how such a configuration can be built.
Currently I'm using Metro but any other solution is valid as well.
Another aspect which I'm interested in, is whether I can use the fast-infoset over JMS to increase performance.
Thanks in advance,
Avner
you can try wso2MB as a JMS provider ...Check following links, would be useful
[1]http://wso2.org/library/message-broker
[2]http://pzf.fremantle.org/2011/04/introduction-to-wso2-message-broker_05.html
One option to solve it is using Apache Camel.
Then you can configure such a thing with an XML configuration file.