[jboss-user] [JBoss Seam] - Re: Conversation id is already in use?

Delphi's Ghost do-not-reply at jboss.com
Thu Jun 7 11:50:09 EDT 2007


Ok, now I think I know what the problem is (but not the answer).


  | <conversation name="bookConv" parameter-name="bookId" parameter-value="#{book.id}" /> 
  | 

This xml lets seam detect an existing conversation for the same entity, and switches to it instead of creating a new one. It works fine when starting a new conversation (i.e. editing a book from the search list). 

However, in most cases, it throws a conversation id is in use error.

I have a search page which lists books. Books are edited from the list by clicking a link with the bookId as a param. Editing books is done within a bookEdit pageflow, and involves one other page where you can pick an author from the list. Upon selection, the pageflow takes you back to the bookEdit page.

Here's a list of where and when the explicit conversation Id stuff works and raises the conversation Id in use exception.

bookSearch -> click edit link (try and start new conversation) -> ok
bookSearch -> Conv Switcher -> exception
bookEdit -> Conv Switcher -> ok
author Select -> select author (pageflow navigation)-> exception
author select -> Conv Switcher -> exception

If I remove the  xml from pages.xml, everything works fine, except that I can start editing two instances of the same book at the same time which is what avoids. 

As far as I can tell, the stuff is fairly new (currently undocumented in 1.2.1GA) and isn't used in any of the examples. With the possible deprecation of @begin annotations on methods in favour of this mechanism, I'm guessing this is the new Seam way. 

Anyone have any experience with this mechanism and gotten it working with conversation switchers and pageflow? 



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

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



More information about the jboss-user mailing list