ADF_FACES-30108:The view state of the page has expired because of inactivity. Reload the page

Problem:viewId:/Home.jspx - ADF_FACES-30108:The view state of the page has expired because of inactivity. Reload the page.
javax.faces.application.ViewExpiredException: viewId:/Home.jspx - ADF_FACES-30108:The view state of the page has expired because of inactivity.  Reload the page.
 at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl._restoreView(LifecycleImpl.java:548)

 

IDE:Jdeveloper 11.1.1.0

 

Solution:该问题是由于session time out带出来的重定向问题。根据http://download.oracle.com/docs/cd/E14571_01/web.1111/b31974/taskflows_complex.htm的资料,对于类似如此的异常处理需要客户化的Exception handler:

  1. In the Application Navigator, expand the project where you want to write the custom and navigate to the Application Sources/META-INF node.

  2. Create a folder named services under the META-INF node.

  3. Create a text file named oracle.adf.view.rich.context.ExceptionHandler in the services folder.

  4. Write the package name and class name of the code custom that you wrote to handle exceptions in the text file named oracle.adf.view.rich.context.ExceptionHandler.

    For example, if you want to register the custom code in Example 18-3, write the following:

    oracle.fodemo.frmwkext.CustomExceptionHandler

  5. Save and close the text file.

检查工程发现,拆分后的项目缺少了名为oracle.adf.view.rich.context.ExceptionHandler的文件和services文件夹。原因是在拆分原工程时,没有把该工程转移到新的工程下所致,新增该文件,问题解决。

你可能感兴趣的:(ADF_FACES-30108:The view state of the page has expired because of inactivity. Reload the page)