Hello,
I have a SFSB that I use to hold states in a pageflow. It resides in the
conversation scope. Now I have a SLSB that I use to upload files.
What I try to achieve is that I want to decouple the uploading process from the
the conversational flow (as file uploading should not be tigth to that
particular flow).
So in the SFSB I implemented a methods like this:
@Observer("newUpload")
| public void onUploadEvent() {
| ...
| }
|
Then the upload method of the upload SLSB calls:
events.raiseEvent("newUpload");
after the upload is done.
The onUploadEvent() methods of the SFSB is called but it is not the instance of
the SFSB in the conversation scope. It seems that another SFSB is instantiated
and its method called.
It is not clear in the doc if the Events framework is only for Stateless bean
or not. When an event is raised, does the event manager looks up in the
differents scopes to find instances of already created components, or just
instantiate a new one?
If I'm not supposed to use the events with a stateful bean, then what would be
the best approach to implement the behaviour I descibed?
Thanks,
Richard
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3978120#3978120
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3978120
_______________________________________________
jboss-user mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/jboss-user