I want to introduce this new “section” or this new category starting for introducing itself. This category is named: “Ask the Community” and the idea is to put in common our experience and our ideas to solve a problem or to show all the posibilities when you are facing a problem or a reality. So, I encourage all of you to participate in the comments and to create a fluid conversation that could be powerful to increase our knowledge and to be a better profesional.
And after this introduction I want to introduce the topic: Creating an unified API (http based) that relies on several TIBCO BW processes in BW (5.x or 6.x series no matter which one).
When can create a API HTTP-based that relies on BW processes without any problem, so we develop our processes using the HTTP palette or the Service palette or if we are using the TIBCO BW 6.x series using the SCA-based services and that’s it. We could implement one or several WSDL that implement any logic that we want.
Ok, that’s true but how we can unified this API to be the idea that is a unified one? I want to introduce some different aspect that I think are important when we are going to create this unified API (but you could add the ones you think I miss, please!! I beg you for it!):
– How can I hide all the processes behind the same HTTP port?
This is the first problem when we are facing this unification process. Probably most of you have been used a HTTP API with different methods and WSDL but how many of them exposes different functionalities using different HTTP port? No one? Ok, me neither. I’ve never seen an API using different port (except if it exposes a secure and a normal way). So why is our approach here?
TIBCO BW processes are able to use a HTTP port per process or more precisely a port per “deployment package”. So, you may think that’s not problem we could create a big deployment package with all of our API and that’s it! Problem solved! But that’s not a realiastic approach. You have to build an independence between different functionalities so you could improve one of them seperately and don’t tie one together even in the deployment life-cycle.
But what other choice do we have? We already said that the product doesn’t allow us to use the same port in different packages. Ok, that’s really not true, the product documentation allowed to us (at least in current version 6.2.1) as you can read here: https://docs.tibco.com/pub/activematrix_businessworks/6.2.1/doc/html/GUID-E7A7A6BD-20C7-496D-9F75-868B6F82FD1E.html
Note: You can start more than one HTTP server on a single port by using Context and Path fields on HTTP Receiver and Wait for HTTP activities. Ensure that you use a different port, if different Context or Path are not specified.
But the current reality is different: Unfortunately, That’s not work. 😦
. Ok, no problem we have another options to achieve this goal:
– We can create a proxy BW process that receives all the request incoming to our input port and then forward the request to the current port.
– We can also use some proxy software or commercial load balancer to do this in a more efficient and declarative way: Software like apache mod_proxy or F5 networks could do the task for us.
We have so many other points to face to get our goal, but I think it’s better go step by step so the conversation can be more helpful and focus in a one topic at the time.
Please, once again, I encourage you to leave a comment about your thoughts and experience