This content has been marked as final.
Show 3 replies
-
1. Re: New conversation starting on every method call
herberson Jul 21, 2010 10:02 AM (in response to pjputhenvila)How are you starting conversations?
Post you action source-code so we can help you better.
-
2. Re: New conversation starting on every method call
pjputhenvila Jul 21, 2010 9:59 PM (in response to pjputhenvila)@Name("registerAction") @Scope(ScopeType.CONVERSATION) public class RegisterAction extends BaseAppSimpleAction { /** * */ private static final long serialVersionUID = 1L; @In(create = true) private UserLocal userEjb; /** * Default constructor. */ public RegisterAction() { // TODO Auto-generated constructor stub } @Validate @Begin public String callMyRegister() { System.err.println("callMyRegister() userEjb " + userEjb.getName()); System.err.println("Conversation.instance() " + Conversation.instance().isLongRunning()); if (getErrorVec().isEmpty() && getWarningVec().isEmpty()) { return "success"; } return "inValid"; } public String back() { System.err.println("back() userEjb " + userEjb.getName()); System.err.println("Conversation.instance() " + Conversation.instance().isLongRunning()); return "back"; } public String save() { System.err.println("save() userEjb " + userEjb.getName()); System.err.println("Conversation.instance() " + Conversation.instance().isLongRunning()); return "save"; } @End public String close() { System.err.println("close() userEjb " + userEjb.getName()); System.err.println("Conversation.instance().getId(); " + Conversation.instance().isLongRunning()); return "close"; } @Override public IBaseBean getFormBean() { return userEjb; } }
-
3. Re: New conversation starting on every method call
herberson Jul 22, 2010 8:14 AM (in response to pjputhenvila)Try join your conversations, so your
@Begin
annotation will be something like@Begin(join=true)
.This way of begining a conversation ensure that the conversation will be joined (or merged) on begining of a new one.