As I understand, you won't be able to synchronize (at front-end) two
requests since you want the system to display partial result.
One solution could be rather than retrieving data in SFSB at once, you could
do it in a loop. For example, if there are 100 records to retrieve, your
front-end could instruct SFSB to retrieve 20 records at a time. And before
going to SFSB, you could acquire lock and release it once the call is
complete. Your display method could use the same lock before going to SFSB.
That way you won't be using same SFSB instance concurrently and still be
able to display partial result.


-J.




-----Original Message-----
From: A mailing list for Enterprise JavaBeans development
[mailto:[EMAIL PROTECTED]]On Behalf Of anup_bd
Sent: Tuesday, July 23, 2002 11:43 PM
To: [EMAIL PROTECTED]
Subject: re-enterant error in stateful session bean


Hi,
        I am facing a problem working with stateful session beans (SFSB).
Problem:
There are 2 links on the front end, one queries the database and caches =
the data in stateful session and bean and the other retrieves the data =
from the SFSB and displays it to the user.
Now the probelm is, if the user clicks the first link and immediately =
clicks on the second, we are getting re-entrant error.
This is because, the quering and cachcing data in SFSB takes a long time =
and before this is complete the request for display is coming in.
The basic objective is, the user need not wait till all the records are =
cached in the SFSB. He should be shown whatever data is available.

Can any one please give some solution or a workaround for this ?

TIA,
Anup B Darvatkat

=========================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to