<debate point>
The latest fad seems to be rushing into HTML5 and producng Fat Clients for FondleSlabs and Phones and forgetting the Enterprise systems that still are Server Centric (for good reason).
I mean; how many mashups can I digest in a day...
Personally I see the Fat Clients only accessing a small proportion of the capability of the systems I work on, and the thin client browser the majority, as the work needs to be done server side.
</debate point>
Anyhow; to this end...
Conversation Scope seems to be the poor relation in JEE 6 and I use it every day...
It was very well supported, in fact a critical part of, Seam
For J6EE I have to add this to my Conversational Controllers (Beans):
@SuppressWarnings("unused")
@URLQueryParameter("cid")
private String cid;
/*
* Hack to pass cid to prettyfaces so it can add it to URL - DONT remove.
*/
public String getCid() {
return this.conversation.getId();
}
public void setCid(String cid) {
this.cid = cid;
}
Then to get the page to pass this Param back I need to use:
<p:commandButton action="#{xxxController.finished}" value="#{messages.button_home}" immediate="true">
<f:param name="cid" value="#{xxxController.cid}" /> <!-- FORCE ConverstionId to be added -->
</p:commandButton>
This ends up being ugly on the URL line the browser that I had made pretty using "pretty faces" of course:
@URLMapping(id = "manageTerritories", pattern = "/territory/manage", viewId = "/pages/territory/manageTerritory.xhtml"),
as it gets tagged on as
...territory/manage?cid=3
I dont know it this is a WELD or PrettyFaces problem but I guess you guys know.
It would be nice to get Conversations "fixed" as most of my real business processes are stateful not stateless.
Thx
Comments