struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joachim Schaaf>
Subject Re: [JBoss-user] How can I use a background process with JBoss
Date Wed, 13 Feb 2002 14:10:51 GMT

Am Mittwoch, 13. Februar 2002 14:16 schrieb Dirk Storck:
> Hi,
> I want to do the following:
> I have a ShoppingCart.
> The users clicks on order and the items from the ShoppingCart are moved to
> my OrderBean. ShoppingCart and OrderBean are EJB's.

It's funny to see how everyone is working on similar problems (even the names 
of my classes are the same :) ).

> Now it comes to the problem. The order must be proccessed in background
> cause it will have a long durration.
> After the order has be proccessed the user should be notived somehow.

The EJB spec. doesn't allow threads, so I think you will have to use message 
driven beans (MDB, belongs to EJB 2.0). The notification could be done via 

> How can I achieve this with JBoss and Struts ? What would be the best way
> to implement this

I haven't used MDB's yet, but the trick is to start a time consuming 
operation with a MDB and let it notify you when it's ready; your Struts 
action class would simply start the thing and return.

Dipl.-Ing. Joachim Schaaf | Projektleiter |
cataloom AG | Eupener Str. 148 | 50933 Köln |
Tel: +49 221 4851807 | Fax: +49 221 4851907 | Mobil-Tel: +49 170 7667807

To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message