Hi,

as far as I understand, MDB's are designed for 2 main issues.

1. to enable an asynchrone communication mechanism (i.e. to trigger
some actions where the client has no need to wait for the result.)
2. to enable a listener mechanism where sending and recieving processes
could be connected in a very flexible way (i.e. a new listener is
connected to en existing Topic to do additional things, so you must not
change anything in the former part of  your app.)

In your case, the sending process has to know the result of the
operation, so I think this is no good design to use MDBs in this part.
A good place for an MDB may be the part where you trigger the next
steps in handling the purchase ( i.e. tell the workers to pack the
books and write a bill).

HTH
tom

On Mon, 14 May 2001, you wrote:
> Hi:
> I'm testing JBoss with MDB but i'm still lost about its
> utility...
> I'd like to write an application to manage a little 
> "web-shop" using EJBs and MDBs as follows:
> 
> * A java servlet who takes data from web application, i.e.
>    the identifier of a client who wants to buy a book.
> 
> * Before allowing this purchase i want to check if this client
>    is not in my 'defaulter list'.
> 
> * After this i'll be able to avoid/allow the purchase.
> 
> Well, i though to do this:
> 
> "The servlet takes data from web client and sends it to a Topic,
> then Topic sends data to a Checker Bean that runs a method 
> called 'checkClient' wich look for this client in a 'defaulter' database.
> If everything is ok, a 'true' value is returned to servlet"
> 
> Is this a good way to pose my problem?
> I know its possible to develope *the same* without MDBs, but,
> is there any advantage on using MDBs?
> in other words, how can i take advantage of MDBs?
> 
> Excuse me if these questions sounds so 'simple' but i need 
> a little help to understand MDB cause i'm really interested
> in learning everything about JBOSS.
> Thanks in advance!
> 
> __________________________________________
> Jaume Soriano Sivera <[EMAIL PROTECTED]>
> __________________________________________
> 
> _______________________________________________
> JBoss-user mailing list
> [EMAIL PROTECTED]
> http://lists.sourceforge.net/lists/listinfo/jboss-user
-- 
THETA - Consulting   
Kommuniktionsanalyse - Anwendungsentwicklung - LINUX-Systeme

Thomas Hagedorn                          Tel. 07231-472108
Rainstr. 12                              Tel. 0172-7642398
75217 Birkenfeld                         [EMAIL PROTECTED]

Jesus inside - where do you want to go forever ?

_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to