views:

67

answers:

3

By default JSF appears to be very 'stateful'. I need to allow people to use our application with multiple tabs doing many things in different parts of the application.

I can't seem to find decent instruction on making this happen without a whole lot of re-engineering.

We do not currently use ICEfaces, but I just found this in the ICEfaces docs:

6.5.7. ICEfaces Portlets and Concurrent DOM Views

ICEfaces provides a feature called Concurrent DOM Views that controls whether or not the ICEfaces framework supports multiple views of a single application from the same browser. When running in a portlet container, ICEfaces needs to treat the separate portlets on a single portal page as distinct views so it is almost always necessary (and therefore safest) to have this parameter set to true.

Example 6.19. Enabling the ICEfaces Concurrent DOM Views feature in the WEB-INF/web.xml configuration file so that separate portlets on the same portal page are treated as distinct views

com.icesoft.faces.concurrentDOMViews true

So, I want to know whether this fabulous sounding functionality would possibly apply to my existing h:forms or whether it only works with ICEface components?

Can anyone offer any good advice to get a JSF app working in multiple tabs?

+1  A: 

MyFaces orchestra has a way of dealing with multiple tabs/windows (using the conversationContext get parameter).

Bozho
Thanks Bozho. I'll try it next.
Andrew
+1  A: 

Use Seam with the JSF framework you want.

The conversation context is perfect for using different tab. Just start a new conversation on each tab. :)

Take a look at the Booking demo

volothamp
+1  A: 

In JSF 2.0 you can use the view scope for this, annotable using @ViewScoped. You can even define custom scopes.

See also:

BalusC
Thanks BalusC. It was a lot of re-engineering as I feared, but using ViewScoped beans instead of session scoped is now a LOT better.
Andrew
You're welcome.
BalusC