K Hein
K Hein

Reputation: 914

JMS for JCA Inbound Messaging?

I am implementing JCA Inbound model so I am studying available reference implementations that I found from Google.

So far I managed to find 2 sample implementations and in both implementation, for inbound messages, they just define a simple MessageListener interface and directly call onMessage method on it.

So I'd like to know if there is any pros/cons to use JMS instead of user defined MessageListener.

Thanks in advance.

Regards,

Kyi Hein

Upvotes: 0

Views: 677

Answers (2)

Nitin Verma
Nitin Verma

Reputation: 508

As you would be writing your own JCA implementation, I won't recommend you "reuse" the JMS's MessageListener interface. Even if the interface which you would design by yourself is quite similar to the MessageListener, it would be better to keep your own interface.

Thanks, Nitin

Upvotes: 2

igor.beslic
igor.beslic

Reputation: 974

If you plan to open your solution to wider community is good idea to design JCA adapters that requires standard MessageListener interface. Almost every JCA example that people use to learn JCA, relates to MessageListener and what is more important (for me) it is packaged in j2ee libraries. Personaly, I'm sick and horrified when I'm forced to add libraries just because somebody ment that special Listener interface is cool despite the fact it provides developer with same methods as standard MessageListener.

Upvotes: 1

Related Questions