Question

Situation:

I have multiple encapsulated web applications (e.g. a forum, a blog, a user profile, etc.) that are each deployed in their own .ear file.

These can each work as a standalone but do offer enhanced functionality (e.g. the user profile displaying a list of blog entries made by this user).

Now to get this list of entries the user profile app would have to request it from the blog app by employing a service call and parsing the answer.

Question: Are there any technologies that allow me to implement such a service so it is only accessible from application instances running on the same machine? (Besides using sockets)

Bonus: What about limiting to application instances running in the same server container (e.g. Tomcat instance)?

Was it helpful?

Solution

You can use an embedded message broker, e.g. ActiveMQ. With ActiveMQ, if you only configure vm-connectors, it is only accessible from within the same VM. Here is the documentation that applies to embedding ActiveMQ into Tomcat, but I would think that you can use it as the basis to integrate it with the EE container of your choice. Most likely you can find documentation for your container, too.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top