kajk
kajk

Reputation: 126

One war calling another in Tomcat

I am currently implementing a small application A. This application A gets some objects from users and will do some preprocessing, before it passes these objects into a different web application B, which finally will store information of these objects.

Now to the question: What are possible approaches to call application B from application A? And which one is the most efficient (in terms of run-time speed)?

This call is one-way, possibly can be done asynchronous and always will happen in the same tomcat server.

Upvotes: 1

Views: 773

Answers (2)

Kayaman
Kayaman

Reputation: 73528

Use an in-memory message queue such as ZeroMQ which provides fast asyncronous communication, constantly open connections (avoiding connect delays that REST would have) and plenty of other things.

Upvotes: 1

Tiago Medici
Tiago Medici

Reputation: 2194

The best approach is to change it in terms of architecture: Monolith vs Microservice.

You can expose REST, WSDL (soap) services in both applications to the others also externally.

In generall REST is less standardized than SOAP, also WSDL requires such contract installment

REST is protocol independent, can use any protocol for which there is an standardized URI scheme

Upvotes: 2

Related Questions