Showing posts with label Assertions. Show all posts
Showing posts with label Assertions. Show all posts

Monday, 14 May 2012

Root cause of ServletException java.lang.AssertionError: CurrencyKey not preserved


After finishing up with the installation of AIA on SOA 11g when I access AIA home I was disappointed to see empty tabs of AIA including Project Life Cycle, CAVA, ect. When I check server log file I found following big error log.. which says....

Referer: http://localhost:7001/AIA/faces/oracle/apps/aia/home/ui/page/Home.jspx?_afrWindowMode=0&_afrLoop=8046694499161&_adf.ctrl-state=1b2migk5rh_9
Cookie: JSESSIONID=82k3PwvbRfLGCv3hGL5rK2sHQPJlzsWyBSmylvLLRptRhcmjS1T2!273321565; ADMINCONSOLESESSION=LMKjPwnCf10njbLYhNKwbPFGHX7cW2L94zgT7TC1jyYhJrJpyMyM!273321565
Content-Type: application/x-www-form-urlencoded
Content-Length: 263

]] Root cause of ServletException.
java.lang.AssertionError: CurrencyKey not preserved
    at org.apache.myfaces.trinidad.component.UIXCollection.encodeEnd(UIXCollection.java:540)
    at javax.faces.component.UIComponent.encodeAll(UIComponent.java:937)
    at org.apache.myfaces.trinidad.render.CoreRenderer.encodeChild(CoreRenderer.java:399)
    at oracle.adf.view.rich.render.RichRenderer.encodeChild(RichRenderer.java:2633)
    at oracle.adfinternal.view.faces.renderkit.rich.PanelStretchLayoutRenderer.encodeCenterFacet(PanelStretchLayoutRenderer.java:769)
    at oracle.adfinternal.view.faces.renderkit.rich.PanelStretchLayoutRenderer._encodeCenterPane(PanelStretchLayoutRenderer.java:1140)
    at oracle.adfinternal.view.faces.renderkit.rich.PanelStretchLayoutRenderer._encodeMiddlePanes(PanelStretchLayoutRenderer.java:348)
    at oracle.adfinternal.view.faces.renderkit.rich.PanelStretchLayoutRenderer.encodeAll(PanelStretchLayoutRenderer.java:313)
    at oracle.adf.view.rich.render.RichRenderer.encodeAll(RichRenderer.java:1396)
    at org.apache.myfaces.trinidad.render.CoreRenderer.encodeEnd(CoreRenderer.java:335)
    at org.apache.myfaces.trinidad.component.UIXComponentBase.encodeEnd(UIXComponentBase.java:767)
    at javax.faces.component.UIComponent.encodeAll(UIComponent.java:937)
    at org.apache.myfaces.trinidad.render.CoreRenderer.encodeChild(CoreRenderer.java:399)
    at oracle.adf.view.rich.render.RichRenderer.encodeChild(RichRenderer.java:2633)
    at oracle.adfinternal.view.faces.renderkit.rich.PanelStretchLayoutRenderer.encodeTopFacet(PanelStretchLayoutRenderer.java:781)

Solution
For this we need to update your Environment file which is available at following location
  
  <MiddlwareHome>/user_projects/domains/<Domainname>/bin/setSOADomainEnv.cmd  
                                                               OR
<MiddlwareHome>/user_projects/domains/<Domainname>/bin/setSOADomainEnv.sh 



set EXTRA_JAVA_PROPERTIES=%EXTRA_JAVA_PROPERTIES% -da:org.apache.myfaces.trinidad.component.UIXCollection
 
and restart the server... 
Now tabs will be successfully visible with no error