When clicking on an s:link after a node has been taken down, the exception below is thrown. The s:link will only work if the page is refreshed first so it is served by the new JBoss instance, but that negates transparent failover.
Method of reproducing:
- Two EAP 5.1 nodes fronted with mod_jk. No firewall, sticky sessions + session replication definitely enabled.
- JBDS Seam generated ear + a simple @Clustered EJB3 which has a method that takes a parameter and prints the EL parametrized text (I don't think EL parametrization is relevant here)
- Click on the s:link on the page, it invokes fine, go back in the browser. Shutdown the active JBoss instance. Click the s:link again which is redirected to the 2nd JBoss now and receive:
14:17:42,995 ERROR [Exceptions] handled and logged exception
java.lang.IllegalStateException: Unable to read view /home.xhtml to execute action "#
SafeActions.java:67 isn't so telling:
String viewId = id.substring(0, loc);
String action = "\"#
InputStream is = FacesContext.getCurrentInstance().getExternalContext().getResourceAsStream(viewId);
if (is==null) throw new IllegalStateException("Unable to read view " + "/" + viewId + " to execute action " + action);
The code says the InputStream is null on failover, so the getResourceAsStream(viewId) failed to return anything.