[jboss-user] [JBoss Seam] - How can I end/destroy other conversations different from the

bgrossi do-not-reply at jboss.com
Wed Jun 6 08:39:22 EDT 2007


I need to force the end of some other seam's conversations in my application, based on a request parameter, but I can't do that..

I try that code:

String[] ids = ... //The ids of conversations to end
if (ids!=null && ids.length>0) {
	ConversationEntries instance = ConversationEntries.instance();
	for (String id : ids) {
		ConversationEntry conversationEntry = instance.getConversationEntry(id);
		if (conversationEntry!=null && !conversationEntry.isCurrent()) {
			conversationEntry.end();
			conversationEntry.destroy();
		}
	}
}


But this cause only the last conversation to be destroied, and "Manager.instance().getCurrentConversationId()" returns that conversation's id (this can cause some unexpected behavior).

I need to destroy some conversations because I known that it'll not be used anymore, and I known the ids..

Can anyone help me?


Bruno E. Grossi

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4051696#4051696

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4051696



More information about the jboss-user mailing list