关于开放自由的JSF 2.3。立即数javax.faces.application.ViewExpiredException

时间:2019-02-14 09:59:14

标签: jsf jsf-2.3 open-liberty

我正在尝试Open Liberty,并想尝试JSF-2.3支持。我必须做些愚蠢的事情,因为在尝试隐式导航时,我会立即得到异常:

javax.faces.application.ViewExpiredException: View "/view/index.xhtml" could not be restored.
    at org.apache.myfaces.lifecycle.RestoreViewExecutor.execute(RestoreViewExecutor.java:181)

我可以使用以下server.xml功能来呈现初始的Facelets页:

 <featureManager>
        <feature>servlet-4.0</feature>
        <feature>jsf-2.3</feature>
        <feature>el-3.0</feature>
        <feature>cdi-2.0</feature>
        <feature>jsp-2.3</feature>
    </featureManager>

我的页面非常简单,看起来像这样:

<h:body>
    <h:outputText value="It works!"/>
    <br/>

    <h:form>
        <h:commandLink value="NAvigate"  action="view/page2" />
        <h:commandButton value="NAvigate 2"  action="view/page2" />
    </h:form>
</h:body>

我有一个对应的page2.xhtml

单击commandLink或commandButton时,出现异常:

javax.faces.application.ViewExpiredException: View "/view/index.xhtml" could not be restored.
    at org.apache.myfaces.lifecycle.RestoreViewExecutor.execute(RestoreViewExecutor.java:181)
    at org.apache.myfaces.lifecycle.LifecycleImpl.executePhase(LifecycleImpl.java:195)
    at org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:142)

我是否在Open Liberty中配置错误,还是我的JSF-mojo严重缺乏?

1 个答案:

答案 0 :(得分:0)

嗯..在另一个浏览器(Safari)中进行测试后,它开始工作了。硬重置Chrome网站存储,然后解决了原始问题。

在自动重新启动之间,此问题一定已经浮出水面。