Unable to Get the Portlet Binding Object for the Portlet Component and NullPointerException when JSFF Page Fragment with Portlet is Placed on JSF Page.
(Doc ID 1351545.1)
Last updated on JULY 28, 2023
Applies to:
Oracle WebCenter Portal - Version 11.1.1.4.0 to 11.1.1.9.8 [Release 11g]Information in this document applies to any platform.
Symptoms
In JDeveloper 11.1.1.4.0 version, placing a portlet on a page fragment(JSFF) and then placing this fragment on a JSF page, the following error is reported when the JSF page is executed:
<PortletBase> <getPortletBinding> Unable to get the portlet binding object for the portlet component Myfrag1:portlet1.
<LifecycleImpl> <_handleException> ADF_FACES-60098:Faces lifecycle receives unhandled exceptions in phase RENDER_RESPONSE 6
javax.faces.FacesException: javax.servlet.ServletException: OracleJSP error:
java.lang.NullPointerException
at com.sun.faces.context.ExternalContextImpl.dispatch(ExternalContextImpl.java:415)
at org.apache.myfaces.trinidad.context.ExternalContextDecorator.dispatch(ExternalContextDecorator.java:44)
at org.apache.myfaces.trinidad.context.ExternalContextDecorator.dispatch(ExternalContextDecorator.java:44)
at oracle.adfinternal.view.faces.config.rich.RecordRequestAttributesDuringDispatch.dispatch(RecordRequestAttributesDuringDispatch.java:44)
at org.apache.myfaces.trinidad.context.ExternalContextDecorator.dispatch(ExternalContextDecorator.java:44)
The following steps demonstrate the problem in JDeveloper 11.1.1.4:
1. Create a new application:
Name: application1
Template: Webcenter Portal Application
Project 1 name: Portal
Project 2 Name: PortalWebAssets
2. Start Integrated WLS Server ( run - Start Server Instance)
3. Register OmniPortlet Provider:
- Under application Resources
- Connection , Right Click New connection, Oracle PDK Java Producer
- Enter Name: Omniportletproducer
- URL http://127.0.0.1:<PORT>/portalTools/omniPortlet/providers/omniPortlet
- Finish
4. Under Portal - WebContent - oracle - webcenter - portalapp - pages
5. Right Click on Pages, New - JSF - JSF Page
Name: page1.jspx
Create as XML document ( .jspx)
Blank Page
6. Drag OmniPortlet from left onto the Page1, (Select ADF Rich Portlet)
7. Application - Secure - Users - Create a new test user, Close jazn-data.xml and Save changes
8. Right click on page 1 and go to Page definition of Page1 ,
9. At bottom left pane, right click on page1PageDef.xml , select Edit authorization
10. Grant to: Add user: Enter the test user name created in step 7.
11. Run Page1 ..... Login in the test user..... Page omniportlet is shown ( though not configured)
The steps so far shows Portlet placed on JSF page directly works ok.
12. Click on Page1, and delete the Omniportlet.
13. Under Portal - WebContent - oracle - webcenter - portalapp - pages
14. Right Click on Pages, New - JSF - JSF Page Fragment
Name: frag1.jsff
Blank Page
15. Drag OmniPortlet from left onto the frag1, ( Select ADF Rich Portlet)
16. Back to Page1, Drag frag1.jsff from left onto page1
Confirm Add SubViewElement: Yes, Component Identifier : Myfrag1
17. Click on SOURCE of the page1 , this is shown:
<f:subview id="myfrag1">
<jsp:include page="/oracle/webcenter/portalapp/pages/frag1.jsff"/>
</f:subview>
18. Run Page1 ..... Login in as the test user..... Get Blank Page.
19 In JDeveloper Server log:
<JUApplicationDefImpl> <logDefaultDynamicPageMapPattern> The definition at portal.DataBindings.cpx, uses a pagemap pattern match that hides other cpx files.
<PortletBase> <getPortletBinding> Unable to get the portlet binding object for the portlet component myfrag1:portlet1.
<LifecycleImpl> <_handleException> ADF_FACES-60098:Faces lifecycle receives unhandled exceptions in phase RENDER_RESPONSE 6
javax.faces.FacesException: javax.servlet.ServletException: OracleJSP error:
java.lang.NullPointerException
at com.sun.faces.context.ExternalContextImpl.dispatch(ExternalContextImpl.java:415)
at org.apache.myfaces.trinidad.context.ExternalContextDecorator.dispatch(ExternalContextDecorator.java:44)
at org.apache.myfaces.trinidad.context.ExternalContextDecorator.dispatch(ExternalContextDecorator.java:44)
at oracle.adfinternal.view.faces.config.rich.RecordRequestAttributesDuringDispatch.dispatch(RecordRequestAttributesDuringDispatch.java:44)
at org.apache.myfaces.trinidad.context.ExternalContextDecorator.dispatch(ExternalContextDecorator.java:44)
at org.apache.myfaces.trinidad.context.ExternalContextDecorator.dispatch(ExternalContextDecorator.java:44)
Changes
Cause
To view full details, sign in with your My Oracle Support account. |
|
Don't have a My Oracle Support account? Click to get started! |
In this Document
Symptoms |
Changes |
Cause |
Solution |
References |