12 Replies Latest reply on Jul 31, 2006 9:41 PM by Prasanth Dhulipala-Oracle

    Problem in running application(using ADF) on BEA Weblogic Server

    524450
      Hi..,

      I am Gunardy Sutanto from Indonesia. Currently, I had a problem in deploying application which is using ADF framework in BEA Weblogic Server(WLS 8.1). I also add all the libraries which were required for running this application. But I found some error when I ran this application. About the error message that I found from log file which is generated by BEA Weblogic Server 8.1, herewith I attach the detail of the error message :

      <Error> <HTTP> <BEA-101020> <[ServletContext(id=27825828,name=bp_presentment,context-path
      =/bp_presentment)] Servlet failed with Exception
      oracle.jbo.PCollException: JBO-28030: Could not insert row into table PS_TXN, collection id 16,408, persistent id 1
      at oracle.jbo.PCollException.throwException(PCollException.java:39)
      at oracle.jbo.pcoll.OraclePersistManager.insert(OraclePersistManager.java:1845)
      at oracle.jbo.pcoll.PCollNode.passivateElem(PCollNode.java:561)
      at oracle.jbo.pcoll.PCollNode.passivate(PCollNode.java:684)
      at oracle.jbo.pcoll.PCollNode.passivateBranch(PCollNode.java:643)
      at oracle.jbo.pcoll.PCollection.passivate(PCollection.java:461)
      at oracle.jbo.server.DBSerializer.passivateRootAM(DBSerializer.java:294)
      at oracle.jbo.server.DBSerializer.passivateRootAM(DBSerializer.java:277)
      at oracle.jbo.server.ApplicationModuleImpl.passivateStateInternal(ApplicationModuleImpl.java:5119)
      at oracle.jbo.server.ApplicationModuleImpl.passivateState(ApplicationModuleImpl.java:5011)
      at oracle.jbo.server.ApplicationModuleImpl.doPoolMessage(ApplicationModuleImpl.java:7741)
      at oracle.jbo.common.ampool.ApplicationPoolImpl.sendPoolMessage(ApplicationPoolImpl.java:3923)
      at oracle.jbo.common.ampool.ApplicationPoolImpl.doManagedCheckin(ApplicationPoolImpl.java:2161)
      at oracle.jbo.common.ampool.ApplicationPoolImpl.releaseApplicationModule(ApplicationPoolImpl.java:1261)
      at oracle.jbo.common.ampool.SessionCookieImpl.releaseApplicationModule(SessionCookieImpl.java:717)
      at oracle.jbo.common.ampool.SessionCookieImpl.releaseApplicationModule(SessionCookieImpl.java:634)
      at oracle.jbo.common.ws.WSApplicationModuleImpl.endRequest(WSApplicationModuleImpl.java:2672)
      at oracle.adf.model.bc4j.DCJboDataControl.endRequest(DCJboDataControl.java:1283)
      at oracle.adf.model.servlet.ADFBindingFilter.invokeEndRequest(ADFBindingFilter.java:300)
      at oracle.adf.model.servlet.ADFBindingFilter.doFilter(ADFBindingFilter.java:249)
      at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:27)
      at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:6724)
      at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
      at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:121)
      at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServletContext.java:3764)
      at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.java:2644)
      at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:219)
      at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:178)
      ## Detail 0 ##
      java.lang.ClassCastException
      at oracle.jbo.pcoll.OraclePersistManager.updateBlobs(OraclePersistManager.java:1613)
      at oracle.jbo.pcoll.OraclePersistManager.insert(OraclePersistManager.java:1832)
      at oracle.jbo.pcoll.PCollNode.passivateElem(PCollNode.java:561)
      at oracle.jbo.pcoll.PCollNode.passivate(PCollNode.java:684)
      at oracle.jbo.pcoll.PCollNode.passivateBranch(PCollNode.java:643)
      at oracle.jbo.pcoll.PCollection.passivate(PCollection.java:461)
      at oracle.jbo.server.DBSerializer.passivateRootAM(DBSerializer.java:294)
      at oracle.jbo.server.DBSerializer.passivateRootAM(DBSerializer.java:277)
      at oracle.jbo.server.ApplicationModuleImpl.passivateStateInternal(ApplicationModuleImpl.java:5119)
      at oracle.jbo.server.ApplicationModuleImpl.passivateState(ApplicationModuleImpl.java:5011)
      at oracle.jbo.server.ApplicationModuleImpl.doPoolMessage(ApplicationModuleImpl.java:7741)
      at oracle.jbo.common.ampool.ApplicationPoolImpl.sendPoolMessage(ApplicationPoolImpl.java:3923)
      at oracle.jbo.common.ampool.ApplicationPoolImpl.doManagedCheckin(ApplicationPoolImpl.java:2161)
      at oracle.jbo.common.ampool.ApplicationPoolImpl.releaseApplicationModule(ApplicationPoolImpl.java:1261)
      at oracle.jbo.common.ampool.SessionCookieImpl.releaseApplicationModule(SessionCookieImpl.java:717)
      at oracle.jbo.common.ampool.SessionCookieImpl.releaseApplicationModule(SessionCookieImpl.java:634)
      at oracle.jbo.common.ws.WSApplicationModuleImpl.endRequest(WSApplicationModuleImpl.java:2672)
      at oracle.adf.model.bc4j.DCJboDataControl.endRequest(DCJboDataControl.java:1283)
      at oracle.adf.model.servlet.ADFBindingFilter.invokeEndRequest(ADFBindingFilter.java:300)
      at oracle.adf.model.servlet.ADFBindingFilter.doFilter(ADFBindingFilter.java:249)
      at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:27)
      at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:6724)
      at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
      at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:121)
      at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServletContext.java:3764)
      at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.java:2644)
      at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:219)
      at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:178)


      I hope this is enough for somebody for solving this problem. If someone have the solution for this problem, please contact me by e-mail to gunardy_sutanto@yahoo.com.

      Thanks,

      Gunardy
        • 1. Re: Problem in running application(using ADF) on BEA Weblogic Server
          dvohra21
          Set the jbo.server.internal_connection property.

          In the Applications-Navigator:
          -Select Application module>Test.
          -In the Connect frame select the Properties tab.
          -The jbo.server.internal_connection property is listed in the Properties.
          -Set the value to the JDBC Datasource. For example, jdbc/DBConenction1DS.

          Also refer
          http://www.oracle.com/technology/products/jdev/htdocs/bc4j/bc4j_temp_tables.html
          • 2. Re: Problem in running application(using ADF) on BEA Weblogic Server
            524450
            I already set the value for jbo.server.internal_connection and then deployed to Weblogic Server. When I was tested the application, all the records from table had shown on the screen but I found the application can't insert row to table PS_TXN. I I want to know it always happened?

            Herewith I attach the detail log from log file which was generated by Weblogic Server:
            oracle.jbo.PCollException: JBO-28030: Could not insert row into table PS_TXN, collection id 162, persistent id 1     at oracle.jbo.PCollException.throwException(PCollException.java:39)
                 at oracle.jbo.pcoll.OraclePersistManager.insert(OraclePersistManager.java:1845)
                 at oracle.jbo.pcoll.PCollNode.passivateElem(PCollNode.java:561)
                 at oracle.jbo.pcoll.PCollNode.passivate(PCollNode.java:684)
                 at oracle.jbo.pcoll.PCollNode.passivateBranch(PCollNode.java:643)
                 at oracle.jbo.pcoll.PCollection.passivate(PCollection.java:461)
                 at oracle.jbo.server.DBSerializer.passivateRootAM(DBSerializer.java:294)
                 at oracle.jbo.server.DBSerializer.passivateRootAM(DBSerializer.java:277)
                 at oracle.jbo.server.ApplicationModuleImpl.passivateStateInternal(ApplicationModuleImpl.java:5119)
                 at oracle.jbo.server.ApplicationModuleImpl.passivateState(ApplicationModuleImpl.java:5011)
                 at oracle.jbo.server.ApplicationModuleImpl.doPoolMessage(ApplicationModuleImpl.java:7741)
                 at oracle.jbo.common.ampool.ApplicationPoolImpl.sendPoolMessage(ApplicationPoolImpl.java:3923)
                 at oracle.jbo.common.ampool.ApplicationPoolImpl.doManagedCheckin(ApplicationPoolImpl.java:2161)
                 at oracle.jbo.common.ampool.ApplicationPoolImpl.releaseApplicationModule(ApplicationPoolImpl.java:1261)
                 at oracle.jbo.common.ampool.SessionCookieImpl.releaseApplicationModule(SessionCookieImpl.java:717)
                 at oracle.jbo.common.ampool.SessionCookieImpl.releaseApplicationModule(SessionCookieImpl.java:634)
                 at oracle.jbo.common.ws.WSApplicationModuleImpl.endRequest(WSApplicationModuleImpl.java:2672)
                 at oracle.adf.model.bc4j.DCJboDataControl.endRequest(DCJboDataControl.java:1283)
                 at oracle.adf.model.servlet.ADFBindingFilter.invokeEndRequest(ADFBindingFilter.java:300)
                 at oracle.adf.model.servlet.ADFBindingFilter.doFilter(ADFBindingFilter.java:249)
                 at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:27)
                 at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:6316)
                 at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:317)
                 at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:118)
                 at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServletContext.java:3622)
                 at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.java:2569)
                 at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:197)
                 at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:170)
            ## Detail 0 ##
            java.lang.ClassCastException
                 at oracle.jbo.pcoll.OraclePersistManager.updateBlobs(OraclePersistManager.java:1613)
                 at oracle.jbo.pcoll.OraclePersistManager.insert(OraclePersistManager.java:1832)
                 at oracle.jbo.pcoll.PCollNode.passivateElem(PCollNode.java:561)
                 at oracle.jbo.pcoll.PCollNode.passivate(PCollNode.java:684)
                 at oracle.jbo.pcoll.PCollNode.passivateBranch(PCollNode.java:643)
                 at oracle.jbo.pcoll.PCollection.passivate(PCollection.java:461)
                 at oracle.jbo.server.DBSerializer.passivateRootAM(DBSerializer.java:294)
                 at oracle.jbo.server.DBSerializer.passivateRootAM(DBSerializer.java:277)
                 at oracle.jbo.server.ApplicationModuleImpl.passivateStateInternal(ApplicationModuleImpl.java:5119)
                 at oracle.jbo.server.ApplicationModuleImpl.passivateState(ApplicationModuleImpl.java:5011)
                 at oracle.jbo.server.ApplicationModuleImpl.doPoolMessage(ApplicationModuleImpl.java:7741)
                 at oracle.jbo.common.ampool.ApplicationPoolImpl.sendPoolMessage(ApplicationPoolImpl.java:3923)
                 at oracle.jbo.common.ampool.ApplicationPoolImpl.doManagedCheckin(ApplicationPoolImpl.java:2161)
                 at oracle.jbo.common.ampool.ApplicationPoolImpl.releaseApplicationModule(ApplicationPoolImpl.java:1261)
                 at oracle.jbo.common.ampool.SessionCookieImpl.releaseApplicationModule(SessionCookieImpl.java:717)
                 at oracle.jbo.common.ampool.SessionCookieImpl.releaseApplicationModule(SessionCookieImpl.java:634)
                 at oracle.jbo.common.ws.WSApplicationModuleImpl.endRequest(WSApplicationModuleImpl.java:2672)
                 at oracle.adf.model.bc4j.DCJboDataControl.endRequest(DCJboDataControl.java:1283)
                 at oracle.adf.model.servlet.ADFBindingFilter.invokeEndRequest(ADFBindingFilter.java:300)
                 at oracle.adf.model.servlet.ADFBindingFilter.doFilter(ADFBindingFilter.java:249)
                 at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:27)
                 at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:6316)
                 at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:317)
                 at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:118)
                 at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServletContext.java:3622)
                 at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.java:2569)
                 at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:197)
                 at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:170)
            >

            Besides that, I found new error when I was starting Weblogic Server. Herewith, I attach the detail of the error message:
            java.lang.NoClassDefFoundError: org/apache/commons/collections/FastHashMap$KeySet
                 at org.apache.commons.collections.FastHashMap.keySet(Unknown Source)
                 at org.apache.struts.action.ActionServlet.destroyDataSources(ActionServlet.java:769)
                 at org.apache.struts.action.ActionServlet.destroy(ActionServlet.java:431)
                 at weblogic.servlet.internal.ServletStubImpl$ServletDestroyAction.run(ServletStubImpl.java:1086)
                 at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:317)
                 at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:118)
                 at weblogic.servlet.internal.ServletStubImpl.destroyServlet(ServletStubImpl.java:569)
                 at weblogic.servlet.internal.ServletStubImpl.destroyServlet(ServletStubImpl.java:596)
                 at weblogic.servlet.internal.ServletStubImpl.destroyServlet(ServletStubImpl.java:581)
                 at weblogic.servlet.internal.WebAppServletContext.destroyServlets(WebAppServletContext.java:5797)
                 at weblogic.servlet.internal.WebAppServletContext.destroy(WebAppServletContext.java:5675)
                 at weblogic.servlet.internal.ServletContextManager.removeContext(ServletContextManager.java:187)
                 at weblogic.servlet.internal.HttpServer.unloadWebApp(HttpServer.java:706)
                 at weblogic.servlet.internal.WebAppModule.destroyContexts(WebAppModule.java:764)
                 at weblogic.servlet.internal.WebAppModule.rollback(WebAppModule.java:742)
                 at weblogic.j2ee.J2EEApplicationContainer.rollbackModule(J2EEApplicationContainer.java:2942)
                 at weblogic.j2ee.J2EEApplicationContainer.rectifyClassLoaders(J2EEApplicationContainer.java:1429)
                 at weblogic.j2ee.J2EEApplicationContainer.prepare(J2EEApplicationContainer.java:1176)
                 at weblogic.j2ee.J2EEApplicationContainer.prepare(J2EEApplicationContainer.java:1031)
                 at weblogic.management.deploy.slave.SlaveDeployer$ComponentActivateTask.prepareContainer(SlaveDeployer.java:2634)
                 at weblogic.management.deploy.slave.SlaveDeployer$ActivateTask.createContainer(SlaveDeployer.java:2584)
                 at weblogic.management.deploy.slave.SlaveDeployer$ActivateTask.prepare(SlaveDeployer.java:2506)
                 at weblogic.management.deploy.slave.SlaveDeployer.processPrepareTask(SlaveDeployer.java:833)
                 at weblogic.management.deploy.slave.SlaveDeployer.prepareDelta(SlaveDeployer.java:542)
                 at weblogic.management.deploy.slave.SlaveDeployer.prepareUpdate(SlaveDeployer.java:500)
                 at weblogic.drs.internal.SlaveCallbackHandler$1.execute(SlaveCallbackHandler.java:25)
                 at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:197)
                 at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:170)
            >

            So, I need someone to sove this problem. I am looking forward for hearing from you.

            Thanks,

            Gunardy
            • 3. Re: Problem in running application(using ADF) on BEA Weblogic Server
              394178
              java.lang.NoClassDefFoundError: org/apache/commons/collections/FastHashMap$KeySet
              at org.apache.commons.collections.FastHashMap.keySet(Unknown Source)

              I would start by first checking that all required lib's are in place for the aplication.
              • 4. Re: Problem in running application(using ADF) on BEA Weblogic Server
                dvohra21
                Are all the runtime BC4J libraries deployed to WebLogic server?
                • 5. Re: Problem in running application(using ADF) on BEA Weblogic Server
                  524450
                  All BC4J Runtime was already installed in Weblogic before deploying the application.
                  • 6. Re: Problem in running application(using ADF) on BEA Weblogic Server
                    Prasanth Dhulipala-Oracle
                    Hi Gunardy,

                    -What DB are you using?
                    - The noclassdef error seems to stem from the commons-collection.jar being unavailable in the classpath. This is installed by the ADF installer. If you have installed the libraries,can you check if you are ensuring that the setupadf.cmd/sh is called during the server startup to ensure that the libraries are indeed being appended to the classpath?

                    Thanks
                    Prasanth
                    • 7. Re: Problem in running application(using ADF) on BEA Weblogic Server
                      524450
                      For database, I am using oracle v9.2.0.1. I also already checked that setupadf.cmd was triggered when I run startweblogic.cmd.
                      • 8. Re: Problem in running application(using ADF) on BEA Weblogic Server
                        Prasanth Dhulipala-Oracle
                        Hi Gunardy,
                        Could you please post the minimum steps to reproduce this issue? You could also send me you application (rename the .zip extension). My email id is prasanth dot dhulipala at oracle dot com

                        Thanks
                        Prasanth
                        • 9. Re: Problem in running application(using ADF) on BEA Weblogic Server
                          468840
                          Hi I'm here to represent Gunardy to post back to this forum.

                          Ignore about this error. This one due to Weblogic 8.1 SP1. If I try on SP4 this never occur.
                          java.lang.NoClassDefFoundError: org/apache/commons/collections/FastHashMap$KeySet
                          at org.apache.commons.collections.FastHashMap.keySet(Unknown Source)

                          Back to the core issue. Below the steps from creating app to deploying to Weblogic engine.

                          SYSTEM REQUIREMENTS:
                          jdk1.4.2_05-b04
                          weblogic 8.1.4.0
                          jdev 10.1.2.0.0(build 1811)

                          MODEL steps:
                          1. New Application Workspace
                          2. Create Database connection
                          3. Test connection and success
                          4. I call it bcaib
                          5. From Model, new business component from table using bcaib connection
                          6. At this stage I have ApplicationModule, ViewObject and EntityObject

                          VIEW CONTROLLER steps:
                          1. Start with struts-config.xml
                          2. Drag drop Data Page component and create corresponding jsp file
                          3. In JSP, drag drop ViewObject from DataControl Pallete
                          4. Add some navigational buttons

                          At this point try to run Data Page from struts-config.xml
                          Everything works fine

                          TRY TO CHANGE TO DATASOURCE steps:
                          1. Application Module is still at JDBC URL.
                          2. Right click-Configurations-Edit to change to DataSource
                          3. Supply DataSource name
                          4. I tried with jdbc/bcaibDS and re-run from struts-config.xml (local OC4J) and works as well
                          5. I also tried to put value for internal_connection properties as the same as DataSource name

                          DEPLOYMENT PROFILE steps:
                          1. New deployment WAR profile
                          2. Then right click to deploy to WAR file

                          Now I have WAR file to deploy to Weblogic

                          WEBLOGIC steps:
                          1. Startup Weblogic
                          2. setupadf.cmd (contains all ADF JARs) already included
                          3. Create connection pool
                          4. Create Data Source with name jdbc/bcaibDS
                          5. Deploy new Web Application Module and deploy the WAR file
                          6. Test and run the application

                          At this point the BEA console will write err message

                          <Jul 27, 2006 4:43:02 PM GMT+07:00> <Error> <HTTP> <BEA-101020> <[ServletContext(id=23640130,name=testAppProfile,context-path
                          =/testAppProfile)] Servlet failed with Exception
                          oracle.jbo.PCollException: JBO-28030: Could not insert row into table PS_TXN, collection id 17,431, persistent id 1
                          at oracle.jbo.PCollException.throwException(PCollException.java:39)
                          at oracle.jbo.pcoll.OraclePersistManager.insert(OraclePersistManager.java:1845)
                          ...
                          ...
                          ...

                          ## Detail 0 ##
                          java.lang.ClassCastException
                          at oracle.jbo.pcoll.OraclePersistManager.updateBlobs(OraclePersistManager.java:1613)
                          at oracle.jbo.pcoll.OraclePersistManager.insert(OraclePersistManager.java:1832)
                          ...
                          ...
                          ...

                          And in the browser error message will look like

                          JBO-29000: Unexpected exception caught: java.lang.NullPointerException, msg=null
                          OR
                          JBO-25046: Requested row not available in row set iterator BolehHapusView1

                          Did we miss something?
                          Why this occurs? And how to turnaround this issue?

                          Regards
                          erix
                          • 10. Re: Problem in running application(using ADF) on BEA Weblogic Server
                            Prasanth Dhulipala-Oracle
                            Hi Erix,
                            Thanks for the steps. I will try to reproduce this issue in my local setup. Question: Is there a reason you are not using the latest jdev production 10.1.3?

                            Thanks
                            Prasanth
                            • 11. Re: Problem in running application(using ADF) on BEA Weblogic Server
                              468840
                              Dear Prasanth,

                              Yup. The production machine is having BEA Weblogic 8.1 thus its requirement is up to jdk1.4 only. While jdev 10.1.3 recommends jdk1.5.

                              Thanks
                              Eric
                              • 12. Re: Problem in running application(using ADF) on BEA Weblogic Server
                                Prasanth Dhulipala-Oracle
                                Hi Eric,
                                1)What type mappings are you using to create BC4J Applications? If you are using Oracle Type Mappings, then the correct jar (bc4jdomorcl.jar) needs to be available in the classpath. If you are using Java type mappings the bc4jdomgnrc.jar should be used instead. By default, the bc4jdomgnrc jar is added to the setup.adf file. Could you please replace the classpath entry to point to :
                                set CLASSPATH=%CLASSPATH%;..\..\..\weblogic81\ADF\lib\bc4jdomorcl.jar
                                and restart the server and test your application and see if the error reproduces?

                                2)Although 10.1.3 recommends usage of jdk 1.5, it does not stop you from creating applications based on jdk 1.4. That way, you can get to use the latest and cool features of 10.1.3. This is especially true in the case of ADF, which has a whole bunch of new features. Have a look at this link:
                                http://download-west.oracle.com/otn_hosted_doc/jdeveloper/1013/adfdevguide.pdf

                                Section 22.8.3 deals with the deploy 10.1.3 based ADF applications in Weblogic 8.x

                                Thanks
                                Prasanth