1 Reply Latest reply on Sep 4, 2011 10:49 PM by hamoncules

    Receiving "CacheException: Can not manage object. It must be either instrumented, a collection, an array, or Serializable" when trying to use the @Replicable annotation. Deployed on weblogic 11GR1.

    hamoncules

      I'm sure it is an issue loading the pojocache-aop.xml but I've tried everything.

       

      If I have my class implement Serializable the attach works fine.

       

      Does anyone have any suggestions how I can successfully add the pojocache-aop.xml file to the CLASSPATH as required on weblogic 11GR1 application server so I can take adavange of the annotation?

       

      Thanks in advance.

       

      PS: Jboss Cache 3.0.

        • 1. Re: Receiving "CacheException: Can not manage object. It must be either instrumented, a collection, an array, or Serializable" when trying to use the @Replicable annotation. Deployed on weblogic 11GR1.
          hamoncules

          I'd like to add a bit more information to the above scenario.

           

          The actual error I'm receiving is:

           

          ####<4-Sep-2011 9:09:25 o'clock PM EDT> <Error> <HTTP> <dlaptop> <AdminServer> <[ACTIVE] ExecuteThread: '19' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <> <1315184965304> <BEA-101020> <[ServletContext@15202739[app:iBATISWebEAR module:iBATISWeb path:/iBATISWeb spec-version:2.5]] Servlet failed with Exception

          org.jboss.cache.pojo.PojoCacheException: attach failed /Profile/Damion

              at org.jboss.cache.pojo.impl.PojoCacheImpl.attach(PojoCacheImpl.java:111)

              at org.jboss.cache.pojo.impl.PojoCacheImpl.attach(PojoCacheImpl.java:93)

              at org.jboss.cache.pojo.impl.PojoCacheImpl.attach(PojoCacheImpl.java:88)

              at test.pojo.attach.doGet(attach.java:39)

              at javax.servlet.http.HttpServlet.service(HttpServlet.java:707)

              at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)

              at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)

              at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)

              at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:300)

              at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:183)

              at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.wrapRun(WebAppServletContext.java:3717)

              at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3681)

              at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)

              at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)

              at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2277)

              at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2183)

              at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1454)

              at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)

              at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)

          Caused By: org.jboss.cache.CacheException: Can not manage object. It must be either instrumented, a collection, an array, or Serializable: com.mydomain.domain.UserProfile

              at org.jboss.cache.pojo.impl.PojoCacheDelegate.getHandler(PojoCacheDelegate.java:168)

              at org.jboss.cache.pojo.impl.PojoCacheDelegate.putObject(PojoCacheDelegate.java:122)

              at org.jboss.cache.pojo.impl.PojoCacheImpl.attach(PojoCacheImpl.java:102)

              at org.jboss.cache.pojo.impl.PojoCacheImpl.attach(PojoCacheImpl.java:93)

              at org.jboss.cache.pojo.impl.PojoCacheImpl.attach(PojoCacheImpl.java:88)

              at test.pojo.attach.doGet(attach.java:39)

              at javax.servlet.http.HttpServlet.service(HttpServlet.java:707)

              at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)

              at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)

              at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)

              at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:300)

              at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:183)

              at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.wrapRun(WebAppServletContext.java:3717)

              at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3681)

              at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)

              at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)

              at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2277)

              at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2183)

              at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1454)

              at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)

              at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)

           

          The server startup console reports the following:

           

          .

          .

          JAVA Memory arguments: -Xms256m -Xmx512m -XX:CompileThreshold=8000 -XX:PermSize=48m  -XX:MaxPermSize=128m

          .

          WLS Start Mode=Development

          .

          CLASSPATH=D:\Oracle\SOAMID~1\patch_wls1035\profiles\default\sys_manifest_classpath\weblogic_patch.jar;D:\Oracle\SOAMID~1\patch_oepe1050\profiles\default\sys_manifest_classpath\weblogic_patch.jar;D:\Oracle\SOAMID~1\patch_ocp360\profiles\default\sys_manifest_classpath\weblogic_patch.jar;D:\Oracle\SOAMID~1\JDK160~1\lib\tools.jar;D:\Oracle\SOAMID~1\WLSERV~1.3\server\lib\weblogic_sp.jar;D:\Oracle\SOAMID~1\WLSERV~1.3\server\lib\weblogic.jar;D:\Oracle\SOAMID~1\modules\features\weblogic.server.modules_10.3.5.0.jar;D:\Oracle\SOAMID~1\WLSERV~1.3\server\lib\webservices.jar;D:\Oracle\SOAMID~1\modules\ORGAPA~1.1/lib/ant-all.jar;D:\Oracle\SOAMID~1\modules\NETSFA~1.0_1/lib/ant-contrib.jar;D:\Oracle\SOAMID~1\WLSERV~1.3\common\derby\lib\derbyclient.jar;D:\Oracle\SOAMID~1\WLSERV~1.3\server\lib\xqrl.jar

          .

          PATH=D:\Oracle\SOAMID~1\patch_wls1035\profiles\default\native;D:\Oracle\SOAMID~1\patch_oepe1050\profiles\default\native;D:\Oracle\SOAMID~1\patch_ocp360\profiles\default\native;D:\Oracle\SOAMID~1\WLSERV~1.3\server\native\win\32;D:\Oracle\SOAMID~1\WLSERV~1.3\server\bin;D:\Oracle\SOAMID~1\modules\ORGAPA~1.1\bin;D:\Oracle\SOAMID~1\JDK160~1\jre\bin;D:\Oracle\SOAMID~1\JDK160~1\bin;C:\oraclexe\app\oracle\product\10.2.0\server\bin;C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common;C:\Program Files\Common Files\Microsoft Shared\Windows Live;C:\Program Files (x86)\Common Files\Microsoft Shared\Windows Live;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Windows;C:\Windows\system32;C:\Windows\system32\Wbem;C:\Program Files (x86)\Common Files\DivX Shared\;C:\Program Files\WIDCOMM\Bluetooth Software\;C:\Program Files\WIDCOMM\Bluetooth Software\syswow64;C:\Program Files (x86)\Windows Live\Shared;C:\Program Files (x86)\IDM Computer Solutions\UltraEdit\;C:\Program Files (x86)\IDM Computer Solutions\UltraCompare\;D:\Oracle\SOAMID~1\WLSERV~1.3\server\native\win\32\oci920_8

          .

          ***************************************************

          *  To start WebLogic Server, use a username and   *

          *  password assigned to an admin-level user.  For *

          *  server administration, use the WebLogic Server *

          *  console at http:\\hostname:port\console        *

          ***************************************************

          starting weblogic with Java version:

          java version "1.6.0_24"

          Java(TM) SE Runtime Environment (build 1.6.0_24-b50)

          Java HotSpot(TM) Client VM (build 19.1-b02, mixed mode)

          Starting WLS with line:

          D:\Oracle\SOAMID~1\JDK160~1\bin\java -client   -Xms256m -Xmx512m -XX:CompileThreshold=8000 -XX:PermSize=48m  -XX:MaxPermSize=128m -Dweblogic.Name=AdminServer -Djava.security.policy=D:\Oracle\SOAMID~1\WLSERV~1.3\server\lib\weblogic.policy  -Xverify:none  -da -Dplatform.home=D:\Oracle\SOAMID~1\WLSERV~1.3 -Dwls.home=D:\Oracle\SOAMID~1\WLSERV~1.3\server -Dweblogic.home=D:\Oracle\SOAMID~1\WLSERV~1.3\server   -Dweblogic.management.discover=true  -Dwlw.iterativeDev= -Dwlw.testConsole= -Dwlw.logErrorsToConsole= -Dweblogic.ext.dirs=D:\Oracle\SOAMID~1\patch_wls1035\profiles\default\sysext_manifest_classpath;D:\Oracle\SOAMID~1\patch_oepe1050\profiles\default\sysext_manifest_classpath;D:\Oracle\SOAMID~1\patch_ocp360\profiles\default\sysext_manifest_classpath  weblogic.Server -Djboss.aop.path=D:\Oracle\SOAMiddleware\user_projects\domains\ibatis_domain\lib\pojocache-aop.xml

          <4-Sep-2011 10:13:59 o'clock PM EDT> <Info> <Security> <BEA-090905> <Disabling CryptoJ JCE Provider self-integrity check for better startup performance. To enable this check, specify -Dweblogic.security.allowCryptoJDefaultJCEVerification=true>

          <4-Sep-2011 10:13:59 o'clock PM EDT> <Info> <Security> <BEA-090906> <Changing the default Random Number Generator in RSA CryptoJ from ECDRBG to FIPS186PRNG. To disable this change, specify -Dweblogic.security.allowCryptoJDefaultPRNG=true>

          <4-Sep-2011 10:13:59 o'clock PM EDT> <Notice> <WebLogicServer> <BEA-000395> <Following extensions directory contents added to the end of the classpath:

          D:\Oracle\SOAMiddleware\user_projects\domains\ibatis_domain\lib\jboss-aop.jar>

          <4-Sep-2011 10:13:59 o'clock PM EDT> <Info> <WebLogicServer> <BEA-000377> <Starting WebLogic Server with Java HotSpot(TM) Client VM Version 19.1-b02 from Sun Microsystems Inc.>

          <4-Sep-2011 10:13:59 o'clock PM EDT> <Info> <Management> <BEA-141107> <Version: WebLogic Server 10.3.5.0  Fri Apr 1 20:20:06 PDT 2011 1398638 >

          <4-Sep-2011 10:14:00 o'clock PM EDT> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to STARTING>

          <4-Sep-2011 10:14:00 o'clock PM EDT> <Info> <WorkManager> <BEA-002900> <Initializing self-tuning thread pool>

          <4-Sep-2011 10:14:00 o'clock PM EDT> <Notice> <LoggingService> <BEA-320400> <The log file D:\Oracle\SOAMiddleware\user_projects\domains\ibatis_domain\servers\AdminServer\logs\AdminServer.log will be rotated. Reopen the log file if tailing has stopped. This can happen on some platforms like Windows.>

          <4-Sep-2011 10:14:00 o'clock PM EDT> <Notice> <LoggingService> <BEA-320401> <The log file has been rotated to D:\Oracle\SOAMiddleware\user_projects\domains\ibatis_domain\servers\AdminServer\logs\AdminServer.log00002. Log messages will continue to be logged in D:\Oracle\SOAMiddleware\user_projects\domains\ibatis_domain\servers\AdminServer\logs\AdminServer.log.>

          <4-Sep-2011 10:14:00 o'clock PM EDT> <Notice> <Log Management> <BEA-170019> <The server log file D:\Oracle\SOAMiddleware\user_projects\domains\ibatis_domain\servers\AdminServer\logs\AdminServer.log is opened. All server side log events will be written to this file.>

          <4-Sep-2011 10:14:02 o'clock PM EDT> <Notice> <Security> <BEA-090082> <Security initializing using security realm myrealm.>

          <4-Sep-2011 10:14:03 o'clock PM EDT> <Notice> <LoggingService> <BEA-320400> <The log file D:\Oracle\SOAMiddleware\user_projects\domains\ibatis_domain\servers\AdminServer\logs\access.log will be rotated. Reopen the log file if tailing has stopped. This can happen on some platforms like Windows.>

          <4-Sep-2011 10:14:03 o'clock PM EDT> <Notice> <LoggingService> <BEA-320401> <The log file has been rotated to D:\Oracle\SOAMiddleware\user_projects\domains\ibatis_domain\servers\AdminServer\logs\access.log00002. Log messages will continue to be logged in D:\Oracle\SOAMiddleware\user_projects\domains\ibatis_domain\servers\AdminServer\logs\access.log.>

          <4-Sep-2011 10:14:04 o'clock PM EDT> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to STANDBY>

          <4-Sep-2011 10:14:04 o'clock PM EDT> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to STARTING>

          <4-Sep-2011 10:14:06 o'clock PM EDT> <Notice> <LoggingService> <BEA-320400> <The log file D:\Oracle\SOAMiddleware\user_projects\domains\ibatis_domain\servers\AdminServer\logs\ibatis_domain.log will be rotated. Reopen the log file if tailing has stopped. This can happen on some platforms like Windows.>

          <4-Sep-2011 10:14:06 o'clock PM EDT> <Notice> <LoggingService> <BEA-320401> <The log file has been rotated to D:\Oracle\SOAMiddleware\user_projects\domains\ibatis_domain\servers\AdminServer\logs\ibatis_domain.log00002. Log messages will continue to be logged in D:\Oracle\SOAMiddleware\user_projects\domains\ibatis_domain\servers\AdminServer\logs\ibatis_domain.log.>

          <4-Sep-2011 10:14:06 o'clock PM EDT> <Notice> <Log Management> <BEA-170027> <The Server has established connection with the Domain level Diagnostic Service successfully.>

          <4-Sep-2011 10:14:06 o'clock PM EDT> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to ADMIN>

          <4-Sep-2011 10:14:06 o'clock PM EDT> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to RESUMING>

          <4-Sep-2011 10:14:06 o'clock PM EDT> <Notice> <Server> <BEA-002613> <Channel "Default[8]" is now listening on fe80:0:0:0:808f:4ce:748c:30fc:7001 for protocols iiop, t3, ldap, snmp, http.>

          <4-Sep-2011 10:14:06 o'clock PM EDT> <Notice> <Server> <BEA-002613> <Channel "Default[1]" is now listening on 192.168.125.1:7001 for protocols iiop, t3, ldap, snmp, http.>

          <4-Sep-2011 10:14:06 o'clock PM EDT> <Notice> <Server> <BEA-002613> <Channel "Default[4]" is now listening on fe80:0:0:0:0:5efe:c0a8:bf01:7001 for protocols iiop, t3, ldap, snmp, http.>

          <4-Sep-2011 10:14:06 o'clock PM EDT> <Notice> <Server> <BEA-002613> <Channel "Default" is now listening on 192.168.191.1:7001 for protocols iiop, t3, ldap, snmp, http.>

          <4-Sep-2011 10:14:06 o'clock PM EDT> <Notice> <Server> <BEA-002613> <Channel "Default[12]" is now listening on 127.0.0.1:7001 for protocols iiop, t3, ldap, snmp, http.>

          <4-Sep-2011 10:14:06 o'clock PM EDT> <Notice> <Server> <BEA-002613> <Channel "Default[10]" is now listening on fe80:0:0:0:5ce8:352b:7bf:b2af:7001 for protocols iiop, t3, ldap, snmp, http.>

          <4-Sep-2011 10:14:06 o'clock PM EDT> <Notice> <Server> <BEA-002613> <Channel "Default[9]" is now listening on fe80:0:0:0:0:100:7f:fffe:7001 for protocols iiop, t3, ldap, snmp, http.>

          <4-Sep-2011 10:14:06 o'clock PM EDT> <Notice> <Server> <BEA-002613> <Channel "Default[5]" is now listening on fe80:0:0:0:0:5efe:c0a8:7d01:7001 for protocols iiop, t3, ldap, snmp, http.>

          <4-Sep-2011 10:14:06 o'clock PM EDT> <Notice> <Server> <BEA-002613> <Channel "Default[2]" is now listening on 192.168.0.195:7001 for protocols iiop, t3, ldap, snmp, http.>

          <4-Sep-2011 10:14:06 o'clock PM EDT> <Notice> <Server> <BEA-002613> <Channel "Default[11]" is now listening on fe80:0:0:0:245a:4c47:acc5:84f5:7001 for protocols iiop, t3, ldap, snmp, http.>

          <4-Sep-2011 10:14:06 o'clock PM EDT> <Notice> <Server> <BEA-002613> <Channel "Default[3]" is now listening on fe80:0:0:0:0:5efe:c0a8:c3:7001 for protocols iiop, t3, ldap, snmp, http.>

          <4-Sep-2011 10:14:06 o'clock PM EDT> <Notice> <Server> <BEA-002613> <Channel "Default[13]" is now listening on 0:0:0:0:0:0:0:1:7001 for protocols iiop, t3, ldap, snmp, http.>

          <4-Sep-2011 10:14:06 o'clock PM EDT> <Notice> <Server> <BEA-002613> <Channel "Default[6]" is now listening on fe80:0:0:0:c163:b3e3:b67:468f:7001 for protocols iiop, t3, ldap, snmp, http.>

          <4-Sep-2011 10:14:06 o'clock PM EDT> <Notice> <Server> <BEA-002613> <Channel "Default[7]" is now listening on fe80:0:0:0:5599:74ba:6fc5:fcf2:7001 for protocols iiop, t3, ldap, snmp, http.>

          <4-Sep-2011 10:14:06 o'clock PM EDT> <Notice> <WebLogicServer> <BEA-000331> <Started WebLogic Admin Server "AdminServer" for domain "ibatis_domain" running in Development Mode>

          <4-Sep-2011 10:14:06 o'clock PM EDT> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to RUNNING>

          <4-Sep-2011 10:14:06 o'clock PM EDT> <Notice> <WebLogicServer> <BEA-000360> <Server started in RUNNING mode>

           

          My startWeblogic.cmd adds the -Djboss.aop.path value as follows (as shown in the startup console):

           

          D:\Oracle\SOAMID~1\JDK160~1\bin\java -client   -Xms256m -Xmx512m -XX:CompileThreshold=8000 -XX:PermSize=48m  -XX:MaxPermSize=128m -Dweblogic.Name=AdminServer -Djava.security.policy=D:\Oracle\SOAMID~1\WLSERV~1.3\server\lib\weblogic.policy  -Xverify:none  -da -Dplatform.home=D:\Oracle\SOAMID~1\WLSERV~1.3 -Dwls.home=D:\Oracle\SOAMID~1\WLSERV~1.3\server -Dweblogic.home=D:\Oracle\SOAMID~1\WLSERV~1.3\server   -Dweblogic.management.discover=true  -Dwlw.iterativeDev= -Dwlw.testConsole= -Dwlw.logErrorsToConsole= -Dweblogic.ext.dirs=D:\Oracle\SOAMID~1\patch_wls1035\profiles\default\sysext_manifest_classpath;D:\Oracle\SOAMID~1\patch_oepe1050\profiles\default\sysext_manifest_classpath;D:\Oracle\SOAMID~1\patch_ocp360\profiles\default\sysext_manifest_classpath  weblogic.Server -Djboss.aop.path=D:\Oracle\SOAMiddleware\user_projects\domains\ibatis_domain\lib\pojocache-aop.xml

           

          As well as identifying that the jboss-aop.jar is being added to the classpath:

           

          <4-Sep-2011 10:13:59 o'clock PM EDT> <Notice> <WebLogicServer> <BEA-000395> <Following extensions directory contents added to the end of the classpath:

          D:\Oracle\SOAMiddleware\user_projects\domains\ibatis_domain\lib\jboss-aop.jar>

           

          -------------------------------------------------------------------------------------------------------------------------

           

          This is potentially a large problem for us as we are required to upgrade from our existing app servers (OC4J 10G) to Weblogic 11G and jboss pojo cache is used as the sole caching solution across our infrastructure. I'm at a bit of a loss as to where to go from here as it seems that the annotation class and configuration is correctly setup.

           

          Any help would be greatly appreciated.