Configuring Toplink Cache Coordination using JMS

After having spent one whole day reading documentation on the above topic, I did not get anywhere. I am looking for a direction to start aquainting myself with Oracle JMS basics to enable me with the configuration in toplink. I hope someone could please help me in getting started, direct me to documentation and/or examples and then I could have some specific and meaningful questions to ask.
As of now, I have these questions.
1) In order to configure Toplink Cache Coordination using JMS, do I use Oracle AS JMS or OJMS provider?
2) Should I be configuring OJMS before I could use Oracle AS JMS?
3) If I am using Oracle 10.1.2 Application Server, will OJMS Database Schema be defined and the resource adapter deployed by default or is there a way I check this using Oracle Enterprise Manager Console.
4) Should I be adding a JMS provider within the OC4J for the application I am using before I do any of the above?
Any help will be highly appreciated.
Thanks
Swapna

Ok. I found my answers
1) In order to configure Toplink Cache Coordination using JMS, do I use Oracle AS JMS or OJMS provider?
Either of the one can be used. Here is what I found regarding the trade off
OJMS and OracleAS JMS are both J2EE 1.3 compliant JMS providers from Oracle. OJMS has been integrated into OracleAS 10g using the JCA adapter while at the same time leveraging Advanced Queuing in the Oracle Database for persistence and recoverability. If database recoverability guarantees, SQL queriability, transparent application failover, message transformation, propagation are required then Oracle recommends using OJMS as the JMS provider.
OracleAS JMS is a lightweight, in-memory/file based queuing system that provides a complete J2EE 1.3 JMS implementation. It is suited for applications that do not require Oracle specific JMS extensions or the recoverability guarantees that OJMS provides.
2) Should I be configuring OJMS before I could use Oracle AS JMS?
No. OracleAS JMS is always provided and preconfigured, except for the topics and queues, with the OC4J installation.
3) If I am using Oracle 10.1.2 Application Server, will OJMS Database Schema be defined and the resource adapter deployed by default or is there a way I check this using Oracle Enterprise Manager Console.
No. The schema needs to be created by the admin and OJMS needs to be configured as the JMS Provider using this schema.
4) Should I be adding a JMS provider within the OC4J for the application I am using before I do any of the above?
Yes, if not using Oracle AS JMS.
Hope that was accurate.

Similar Messages

  • Issues with TopLink Cache Coordination using JMS for manual DB updates

    Hi,
    We are having 2 web application using same Database and Toplink library but 2 session objects for both the applications. We are using JMS for cache coordination. JMS propagating messages successfully between the applications and able to see the same object changes in both the applications properly. Now, we are trying to refresh cache for manual updates in Database. We are trying to refresh single object which is modified in database in one application, refreshing in one application from which refresh happened but not in other application (JMS publishing the topic but updating one).
    Our intention is refreshing in one application so that JMS should coordinate and update in others when DB manual updates. Please let us know any comments for the same.
    Database using: Oracle 11g
    Toplink Version:- 9.0.3

    See,
    http://www.coderanch.com/t/592919/ORM/databases/Toplink-Cache-coordination-JMS-manual

  • Toplink Cache Coordination using JMS - doesn't work, gives a warning

    Hi, I am trying to implement cache coordination on Oracle App Server 9.0.4 in a clustered environment. I have two application sessions configured to use JMS for cache coordination. When I make an update to one of the objects in one application which is cached and used by both the applications, I get the below warning in the log file and the changes does not propogate to the other application.
    [TopLink Warning]: 2007.10.23 01:45:17.463--ServerSession(802908582)--Thread(Thread[Thread-112,5,ApplicationServerThreadGroup])--null
    command failed due to: javax.jms.JMSException: getObject
    at com.evermind.server.jms.JMSUtils.makeJMSException(JMSUtils.java:1899)
    at com.evermind.server.jms.JMSUtils.toJMSException(JMSUtils.java:1915)
    at com.evermind.server.jms.EvermindObjectMessage.getObject(EvermindObjectMessage.java:128)
    at oracle.toplink.internal.remotecommand.jms.JMSTopicRemoteConnection.onMessage(JMSTopicRemoteConnection.java:73)
    at oracle.toplink.remotecommand.jms.JMSTopicTransportManager$JMSOnMessageHelper.run(JMSTopicTransportManager.java:261)
    I have no clue from the warning above as to what could be wrong. Does anybody have any idea? Is there a way I could debug and see what really is happening?
    Thanks
    Swapna

    Hi, thanks for your response.
    I set the logging level to all and this is the complete stack trace I see in the log.
    [TopLink Finest]: 2007.10.25 01:54:04.547--ServerSession(2121070148)--Thread(Thread[Thread-465,5,main])--Retreived remote message from
    JMS topic: ICMS Toplink topic
    [TopLink Warning]: 2007.10.25 01:54:04.555--ServerSession(2121070148)--Thread(Thread[Thread-465,5,main])--null command failed due to:
    javax.jms.JMSException: getObject
    at com.evermind.server.jms.JMSUtils.makeJMSException(JMSUtils.java:1899)
    at com.evermind.server.jms.JMSUtils.toJMSException(JMSUtils.java:1915)
    at com.evermind.server.jms.EvermindObjectMessage.getObject(EvermindObjectMessage.java:128)
    at oracle.toplink.internal.remotecommand.jms.JMSTopicRemoteConnection.onMessage(JMSTopicRemoteConnection.java:73)
    at oracle.toplink.remotecommand.jms.JMSTopicTransportManager$JMSOnMessageHelper.run(JMSTopicTransportManager.java:261)
    I am using toplink version 10.1.3.1. I contacted Oracle Technical support but so far they were not able to figure this out. I will try using RMI as you suggested to make sure.
    I have another question to ask you about logging. I am working on a different application which is in production and uses toplink version 9.0.3. Due to excessive logging, I am trying to set the logging level to warning and I don't see this as an option in 9.0.3. The documentation does talk about it but using toplink workbench and I can't open the session.xml using Toplink workbench 9.0.3. Is it doable at all in toplink version 9.0.3?
    Thanks
    Swapna

  • Toplink Cache sync using JMS

    Hi,
    I am using toplink cache synchronization using Orion JMS. While starting the application I get the following erorr message.
    Oracle apps server version is 10.1.2.0.0 toplink 9.0.4.5
    Local Exception Stack:
    Exception [TOPLINK-15016] (OracleAS TopLink - 10g (9.0.4.5) (Build 040930)): oracle.toplink.exceptions.SynchronizationException
    Exception Description: Could not gain access to SynchronizationService class
    Internal Exception: Exception [TOPLINK-15013] (OracleAS TopLink - 10g (9.0.4.5) (Build 040930)): oracle.toplink.exceptions.SynchronizationException
    Exception Description: Could not find JMS Service Topic named: jms/MyCacheSyncTopic
    Internal Exception: javax.naming.NameNotFoundException: jms/MyTopicFactory not found
    at oracle.toplink.exceptions.SynchronizationException.errorGettingSyncService(SynchronizationException.java:139)
    at oracle.toplink.remote.CacheSynchronizationManager.initialize(CacheSynchronizationManager.java:114)
    at oracle.toplink.publicinterface.DatabaseSession.login(DatabaseSession.java:534)
    at oracle.toplink.tools.sessionmanagement.SessionManager.getSession(SessionManager.java:250)
    at oracle.toplink.tools.sessionmanagement.SessionManager.getSession(SessionManager.java:181)
    at com.starkey.cqm.dao.PersistenceService.initializeService(PersistenceService.java:67)
    at com.starkey.cqm.bcs.CQMServiceManager.createService(CQMServiceManager.java:68)
    at com.starkey.cqm.web.util.CQMInitServlet.init(CQMInitServlet.java:40)
    I have made the modifications in sessions.xml as follows
              <cache-synchronization-manager>
                   <clustering-service>oracle.toplink.remote.jms.JMSClusteringService</clustering-service>
                   <jms-topic-connection-factory-name>jms/MyTopicFactory</jms-topic-connection-factory-name>
                   <jms-topic-name>jms/MyCacheSyncTopic</jms-topic-name>     
              </cache-synchronization-manager>
    Changes in JMS xml
    <topic name="MyCacheSyncTopic" location="jms/MyCacheSyncTopic"/>
    <topic-connection-factory
              host="cqtest1"
              port="3702"
              name="Cache Sync Topic Factory"
              location="jms/MyTopicFactory" />
    Has any one encountered this before ?
    Thanks
    Priya

    Hi Steve,
    Servers 1 and 2 may have dropped the connections to 3. One way that this can happen is if at some point an object delta is sent to a target server that does not have the object deployed, or on its classpath. Make sure that log-debug is turned on for the TopLink session. You should see warnings on servers 1 and 2 about the connections being dropped to 3.
    If none of this seems to help or if you can't find the answers from the debug traces then the logs of the three servers would help support in determining where the problem occurred.
    -Mike

  • Toplink cache coordination

    I'm just getting started on setting up clustered Toplink caches.
    I'm attracted to the JMS option because setting up message brokers on our system also opens up a number of other possibilities, in particular ensuring caches are invalidated following batch updates, arranging for Swing programs to update their displayed data and so on.
    I'd like to hear some experience from people using various message brokers for Toplink cache coordination. Particularly with Toplink web apps under Oracle application server.
    And incidentally, anyone know how to configure cache coordination for old ADF applications where the Toplink stuff is rather well hidden?

    I raised a TAR with Oracle. The short answer is that you can't do cache coordination either with ADF business objects, or with Toplink Essentials (as opposed to Oracle Toplink, which doesn't yet support JPA).

  • Setting up cache synchronization using JMS on Tomcat

    I'm trying to enable cache synchronization using JMS on Tomcat 5.0; Does anyone have any tips on how to do this?

    Configure the TIBCO service to provide a Topic and a TopicConnectionFactory for TopLink to use.
    You will need to register for a pre-login event configured on the session that will configure the JMSClusteringService for the TIBCO service.
    ie.
    JMSClusteringService clusteringService = new JMSClusteringService(event.getSession());
    event.getSession().setClusteringService(clusteringService);
    Hashtable env = new Hashtable();
    env.put(javax.naming.Context.INITIAL_CONTEXT_FACTORY , "TIBCOFactoryClassName");
    env.put(javax.naming.Context.PROVIDER_URL, "url");
    env.put(javax.naming.Context.SECURITY_PRINCIPAL, "userName"));
    env.put(javax.naming.Context.SECURITY_CREDENTIALS,"password");
    clusteringService.setInitialContextProperties(env);
    --Gordon                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

  • Toplink cache coordination problem with opmn lookup

    Dear all,
    We encounter some problems when we use opmn url and jms to realize the toplink cache coordination.
    Scenario:
    1. Using oracle application server 10g, create three processes(jvm) on one oc4j instance
    2. Using oc4j in memory jms server for cache coordination
    3. Using opmn url to lookup jms topic connection factory and connection, opmn url: opmn:ormi://shasudv4:6004:OC4J_TTS/tts
    When we start oc4j instance, we find the log, all the toplink cache coordination properites has been set to toplink framework, and remote command manager has been initialized successfully. All in memory jms server has also been started successfully, there are three listeners on the topic.
    But, when we test the synchronization, the data can't be synchronized between all the processes, two of them is ok, the rest of them has some problem to coordinate with the other two. There are no exceptions, we have set the level of toplink log to 'all'.
    I have checked the thread dump, I find that "HTTPThreadGroup", "RMICallHandler" and "JMSRequestHandler" threads are involved in cache synchronization.
    So, we are obliged to change the opmn url to ormi url, so we can only set a bound for rmi ports of processes, because the ormi port is dynamicly assigned.
    &lt;port id="rmi" range="12405-12407" /&gt;
    This seems ok, and involved thread are: "RMICallHander" and "JMSRequestHandler". But we also concern that we have restricted the port bound of ormi port of every instance.
    Thanks of any advice.

    I raised a TAR with Oracle. The short answer is that you can't do cache coordination either with ADF business objects, or with Toplink Essentials (as opposed to Oracle Toplink, which doesn't yet support JPA).

  • Error in Toplink 10.1.3 cache coordination using Websphere JMS

    I' am trying to setup Cache Coordination for Toplink 10.1.3 in Websphere 7 using Websphere's implementation of JMS. However I' am getting a NamingException
    when I try to lookup the Topic and TopicFactory from the JNDI tree. Admin Security is enabled in the server but not application security. I' am able to lookup
    the queues using InitialContext. Upgrading to Toplink 11 is not an option right now for us. Please help in finding out if anything is missing in my Toplink configuration.
    <?xml version="1.0" encoding="UTF-8"?>
    <toplink-sessions
         version="10g Release 3 (10.1.3.0.0)"
         xmlns:xsd="http://www.w3.org/2001/XMLSchema"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
         <session xsi:type="server-session">
              <name>default</name>
              <remote-command>
                   <commands>
                        <cache-sync>true</cache-sync>
                   </commands>
                   <transport xsi:type="jms-topic-transport">
                        <topic-connection-factory-name>jms/jobtrax.TCF</topic-connection-factory-name>
                        <topic-name>jms/jobtrax.ToplinkTopic</topic-name>
                        <jndi-naming-service>
                             <url>corbaloc:rir:/NameServiceServerRoot</url>
                             <initial-context-factory-name>com.ibm.websphere.naming.WsnInitialContextFactory</initial-context-factory-name>
                        </jndi-naming-service>
                   </transport>
              </remote-command>
    <!--<event-listener-classes>
    <event-listener-class>com.pstechnology.eaf.persistence.toplink.PostBeginTransactionListener</event-listener-class>
    </event-listener-classes>
              -->
              <logging xsi:type="toplink-log">
                   <log-level>fine</log-level>
                   <logging-options>
                        <log-exception-stacktrace>true</log-exception-stacktrace>
                        <print-thread>true</print-thread>
                        <print-session>false</print-session>
                        <print-connection>false</print-connection>
                        <print-date>true</print-date>
                   </logging-options>
              </logging>
              <primary-project xsi:type="class">com.pstechnology.toplink.ToplinkProject</primary-project>
              <login xsi:type="database-login">
                   <platform-class>com.pstechnology.eaf.persistence.toplink.Oracle10Platform</platform-class>
                   <external-connection-pooling>true</external-connection-pooling>
                   <external-transaction-controller>false</external-transaction-controller>
                   <sequencing>
                        <default-sequence xsi:type="native-sequence">
                             <name>Default</name>
                        </default-sequence>
                   </sequencing>
                   <datasource>jdbc/jobtrax_job_datasource</datasource>
                   <bind-all-parameters>true</bind-all-parameters>
              </login>
         </session>
    </toplink-sessions>
    [2/17/11 16:22:10:696 EST] 00000018 SystemOut O [TopLink Warning]:
    2011.02.17 04:22:10.690--Thread(Thread[server.startup : 0,5,main])--Local
    Exception Stack:
    Exception [TOPLINK-22103] (Oracle TopLink - 10g Release 3 (10.1.3.0.0)
    (Build 060118)): oracle.toplink.exceptions.RemoteCommandManagerException
    Exception Description: Could not look up remote connection under name
    jms/jobtrax.TCF with URL corbaloc:rir:/NameServiceServerRoot
    Internal Exception: javax.naming.NamingException: Error during resolve
    [Root exception is javax.naming.AuthenticationException: Login failed:
    com.ibm.websphere.security.auth.WSLoginFailedException [Root exception is
    com.ibm.websphere.security.auth.WSLoginFailedException]]
    at
    oracle.toplink.exceptions.RemoteCommandManagerException.errorLookingUpRemoteConnection
    (RemoteCommandManagerException.java:75)
    at
    oracle.toplink.remotecommand.jms.JMSTopicTransportManager.getTopicConnectionFactory
    (JMSTopicTransportManager.java:206)
    at
    oracle.toplink.remotecommand.jms.PstJMSTopicTransportManager.createJMSTopicRemoteConnection
    (PstJMSTopicTransportManager.java:67)
    at
    oracle.toplink.remotecommand.jms.JMSTopicTransportManager.createLocalConnection
    (JMSTopicTransportManager.java:106)
    at
    oracle.toplink.remotecommand.jms.JMSTopicDiscoveryManager.startDiscovery
    (JMSTopicDiscoveryManager.java:44)
    at oracle.toplink.remotecommand.RemoteCommandManager.initialize
    (RemoteCommandManager.java:132)
    at oracle.toplink.publicinterface.DatabaseSession.login
    (DatabaseSession.java:517)
    at oracle.toplink.tools.sessionmanagement.SessionManager.getSession
    (SessionManager.java:379)
    at
    com.pstechnology.eaf.persistence.toplink.TopLinkRepository.getServerSession
    (TopLinkRepository.java:163)
    at
    com.pstechnology.eaf.persistence.toplink.TopLinkRepository.getClientSession
    (TopLinkRepository.java:198)
    at
    com.pstechnology.eaf.persistence.toplink.TopLinkRepository.getReadSession
    (TopLinkRepository.java:216)
    at com.pstechnology.eaf.persistence.toplink.TopLinkRepository.read
    (TopLinkRepository.java:318)
    at
    com.pstechnology.repository.admin.ApplicationPropertyRepository.findApplicationPropertyByEnumId
    (ApplicationPropertyRepository.java:70)
    at
    com.pstechnology.service.admin.AdministrationService.findApplicationPropertyValue
    (AdministrationService.java:179)
    at
    com.pstechnology.scheduling.trigger.AbolishedTaskSimpleTrigger.getTimerRepeatIntervalValue
    (AbolishedTaskSimpleTrigger.java:45)
    at
    com.pstechnology.scheduling.trigger.AbolishedTaskSimpleTrigger.afterPropertiesSet
    (AbolishedTaskSimpleTrigger.java:30)
    at
    org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods
    (AbstractAutowireCapableBeanFactory.java:1198)
    at
    org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean
    (AbstractAutowireCapableBeanFactory.java:1167)
    at
    org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean
    (AbstractAutowireCapableBeanFactory.java:427)
    at org.springframework.beans.factory.support.AbstractBeanFactory
    $1.getObject(AbstractBeanFactory.java:249)
    at
    org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton
    (DefaultSingletonBeanRegistry.java:155)
    at
    org.springframework.beans.factory.support.AbstractBeanFactory.getBean
    (AbstractBeanFactory.java:246)
    at
    org.springframework.beans.factory.support.AbstractBeanFactory.getBean
    (AbstractBeanFactory.java:160)
    at
    org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons
    (DefaultListableBeanFactory.java:291)
    at
    org.springframework.context.support.AbstractApplicationContext.refresh
    (AbstractApplicationContext.java:352)
    at
    org.springframework.context.support.ClassPathXmlApplicationContext.<init>
    (ClassPathXmlApplicationContext.java:122)
    at
    org.springframework.context.support.ClassPathXmlApplicationContext.<init>
    (ClassPathXmlApplicationContext.java:66)
    at com.pstechnology.service.SchedulingContext.initialize
    (SchedulingContext.java:56)
    at com.pstechnology.servlet.InitializationServlet.init
    (InitializationServlet.java:52)
    at com.ibm.ws.webcontainer.servlet.ServletWrapper.init
    (ServletWrapper.java:358)
    at com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.init
    (ServletWrapperImpl.java:169)
    at com.ibm.ws.webcontainer.servlet.ServletWrapper.initialize
    (ServletWrapper.java:1809)
    at
    com.ibm.wsspi.webcontainer.extension.WebExtensionProcessor.createServletWrapper
    (WebExtensionProcessor.java:98)
    at com.ibm.ws.webcontainer.webapp.WebApp.initializeTargetMappings
    (WebApp.java:678)
    at com.ibm.ws.webcontainer.webapp.WebApp.commonInitializationFinally
    (WebApp.java:429)
    at com.ibm.ws.webcontainer.webapp.WebAppImpl.initialize
    (WebAppImpl.java:304)
    at com.ibm.ws.webcontainer.webapp.WebGroupImpl.addWebApplication
    (WebGroupImpl.java:100)
    at com.ibm.ws.webcontainer.VirtualHostImpl.addWebApplication
    (VirtualHostImpl.java:166)
    at com.ibm.ws.webcontainer.WSWebContainer.addWebApp
    (WSWebContainer.java:731)
    at com.ibm.ws.webcontainer.WSWebContainer.addWebApplication
    (WSWebContainer.java:616)
    at com.ibm.ws.webcontainer.component.WebContainerImpl.install
    (WebContainerImpl.java:376)
    at com.ibm.ws.webcontainer.component.WebContainerImpl.start
    (WebContainerImpl.java:668)
    at com.ibm.ws.runtime.component.ApplicationMgrImpl.start
    (ApplicationMgrImpl.java:1122)
    at
    com.ibm.ws.runtime.component.DeployedApplicationImpl.fireDeployedObjectStart
    (DeployedApplicationImpl.java:1319)
    at com.ibm.ws.runtime.component.DeployedModuleImpl.start
    (DeployedModuleImpl.java:609)
    at com.ibm.ws.runtime.component.DeployedApplicationImpl.start
    (DeployedApplicationImpl.java:944)
    at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplication
    (ApplicationMgrImpl.java:725)
    at com.ibm.ws.runtime.component.ApplicationMgrImpl.start
    (ApplicationMgrImpl.java:2046)
    at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start
    (CompositionUnitMgrImpl.java:439)
    at com.ibm.ws.runtime.component.CompositionUnitImpl.start
    (CompositionUnitImpl.java:123)
    at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start
    (CompositionUnitMgrImpl.java:382)
    at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.access$300
    (CompositionUnitMgrImpl.java:110)
    at com.ibm.ws.runtime.component.CompositionUnitMgrImpl
    $CUInitializer.run(CompositionUnitMgrImpl.java:949)
    at com.ibm.wsspi.runtime.component.WsComponentImpl
    $_AsynchInitializer.run(WsComponentImpl.java:349)
    at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1563)
    Internal Exception Stack:
    javax.naming.NamingException: Error during resolve [Root exception is
    javax.naming.AuthenticationException: Login failed:
    com.ibm.websphere.security.auth.WSLoginFailedException [Root exception is
    com.ibm.websphere.security.auth.WSLoginFailedException]]
    at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup
    (CNContextImpl.java:1840)
    at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup
    (CNContextImpl.java:1749)
    at com.ibm.ws.naming.jndicos.CNContextImpl.lookupExt
    (CNContextImpl.java:1500)
    at com.ibm.ws.naming.jndicos.CNContextImpl.lookup
    (CNContextImpl.java:637)
    at com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:165)
    at com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:179)
    at javax.naming.InitialContext.lookup(InitialContext.java:455)
    at
    oracle.toplink.remotecommand.jms.JMSTopicTransportManager.getTopicConnectionFactory
    (JMSTopicTransportManager.java:204)
    at
    oracle.toplink.remotecommand.jms.PstJMSTopicTransportManager.createJMSTopicRemoteConnection
    (PstJMSTopicTransportManager.java:67)
    at
    oracle.toplink.remotecommand.jms.JMSTopicTransportManager.createLocalConnection
    (JMSTopicTransportManager.java:106)
    at
    oracle.toplink.remotecommand.jms.JMSTopicDiscoveryManager.startDiscovery
    (JMSTopicDiscoveryManager.java:44)
    at oracle.toplink.remotecommand.RemoteCommandManager.initialize
    (RemoteCommandManager.java:132)
    at oracle.toplink.publicinterface.DatabaseSession.login
    (DatabaseSession.java:517)
    at oracle.toplink.tools.sessionmanagement.SessionManager.getSession
    (SessionManager.java:379)
    at
    com.pstechnology.eaf.persistence.toplink.TopLinkRepository.getServerSession
    (TopLinkRepository.java:163)
    at
    com.pstechnology.eaf.persistence.toplink.TopLinkRepository.getClientSession
    (TopLinkRepository.java:198)
    at
    com.pstechnology.eaf.persistence.toplink.TopLinkRepository.getReadSession
    (TopLinkRepository.java:216)
    at com.pstechnology.eaf.persistence.toplink.TopLinkRepository.read
    (TopLinkRepository.java:318)
    at
    com.pstechnology.repository.admin.ApplicationPropertyRepository.findApplicationPropertyByEnumId
    (ApplicationPropertyRepository.java:70)
    at
    com.pstechnology.service.admin.AdministrationService.findApplicationPropertyValue
    (AdministrationService.java:179)
    at
    com.pstechnology.scheduling.trigger.AbolishedTaskSimpleTrigger.getTimerRepeatIntervalValue
    (AbolishedTaskSimpleTrigger.java:45)
    at
    com.pstechnology.scheduling.trigger.AbolishedTaskSimpleTrigger.afterPropertiesSet
    (AbolishedTaskSimpleTrigger.java:30)
    at
    org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods
    (AbstractAutowireCapableBeanFactory.java:1198)
    at
    org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean
    (AbstractAutowireCapableBeanFactory.java:1167)
    at
    org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean
    (AbstractAutowireCapableBeanFactory.java:427)
    at org.springframework.beans.factory.support.AbstractBeanFactory
    $1.getObject(AbstractBeanFactory.java:249)
    at
    org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton
    (DefaultSingletonBeanRegistry.java:155)
    at
    org.springframework.beans.factory.support.AbstractBeanFactory.getBean
    (AbstractBeanFactory.java:246)
    at
    org.springframework.beans.factory.support.AbstractBeanFactory.getBean
    (AbstractBeanFactory.java:160)
    at
    org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons
    (DefaultListableBeanFactory.java:291)
    at
    org.springframework.context.support.AbstractApplicationContext.refresh
    (AbstractApplicationContext.java:352)
    at
    org.springframework.context.support.ClassPathXmlApplicationContext.<init>
    (ClassPathXmlApplicationContext.java:122)
    at
    org.springframework.context.support.ClassPathXmlApplicationContext.<init>
    (ClassPathXmlApplicationContext.java:66)
    at com.pstechnology.service.SchedulingContext.initialize
    (SchedulingContext.java:56)
    at com.pstechnology.servlet.InitializationServlet.init
    (InitializationServlet.java:52)
    at com.ibm.ws.webcontainer.servlet.ServletWrapper.init
    (ServletWrapper.java:358)
    at com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.init
    (ServletWrapperImpl.java:169)
    at com.ibm.ws.webcontainer.servlet.ServletWrapper.initialize
    (ServletWrapper.java:1809)
    at
    com.ibm.wsspi.webcontainer.extension.WebExtensionProcessor.createServletWrapper
    (WebExtensionProcessor.java:98)
    at com.ibm.ws.webcontainer.webapp.WebApp.initializeTargetMappings
    (WebApp.java:678)
    at com.ibm.ws.webcontainer.webapp.WebApp.commonInitializationFinally
    (WebApp.java:429)
    at com.ibm.ws.webcontainer.webapp.WebAppImpl.initialize
    (WebAppImpl.java:304)
    at com.ibm.ws.webcontainer.webapp.WebGroupImpl.addWebApplication
    (WebGroupImpl.java:100)
    at com.ibm.ws.webcontainer.VirtualHostImpl.addWebApplication
    (VirtualHostImpl.java:166)
    at com.ibm.ws.webcontainer.WSWebContainer.addWebApp
    (WSWebContainer.java:731)
    at com.ibm.ws.webcontainer.WSWebContainer.addWebApplication
    (WSWebContainer.java:616)
    at com.ibm.ws.webcontainer.component.WebContainerImpl.install
    (WebContainerImpl.java:376)
    at com.ibm.ws.webcontainer.component.WebContainerImpl.start
    (WebContainerImpl.java:668)
    at com.ibm.ws.runtime.component.ApplicationMgrImpl.start
    (ApplicationMgrImpl.java:1122)
    at
    com.ibm.ws.runtime.component.DeployedApplicationImpl.fireDeployedObjectStart
    (DeployedApplicationImpl.java:1319)
    at com.ibm.ws.runtime.component.DeployedModuleImpl.start
    (DeployedModuleImpl.java:609)
    at com.ibm.ws.runtime.component.DeployedApplicationImpl.start
    (DeployedApplicationImpl.java:944)
    at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplication
    (ApplicationMgrImpl.java:725)
    at com.ibm.ws.runtime.component.ApplicationMgrImpl.start
    (ApplicationMgrImpl.java:2046)
    at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start
    (CompositionUnitMgrImpl.java:439)
    at com.ibm.ws.runtime.component.CompositionUnitImpl.start
    (CompositionUnitImpl.java:123)
    at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.start
    (CompositionUnitMgrImpl.java:382)
    at com.ibm.ws.runtime.component.CompositionUnitMgrImpl.access$300
    (CompositionUnitMgrImpl.java:110)
    at com.ibm.ws.runtime.component.CompositionUnitMgrImpl
    $CUInitializer.run(CompositionUnitMgrImpl.java:949)
    at com.ibm.wsspi.runtime.component.WsComponentImpl
    $_AsynchInitializer.run(WsComponentImpl.java:349)
    at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1563)
    Caused by: javax.naming.AuthenticationException: Login failed:
    com.ibm.websphere.security.auth.WSLoginFailedException [Root exception is
    com.ibm.websphere.security.auth.WSLoginFailedException]
    at com.ibm.ws.naming.util.SecurityUtil.login(SecurityUtil.java:121)
    at com.ibm.ws.naming.jndicos.CNContextImpl.login
    (CNContextImpl.java:4516)
    at com.ibm.ws.naming.jndicos.CNContextImpl.cosResolve
    (CNContextImpl.java:2781)
    at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup
    (CNContextImpl.java:1790)
    ... 60 more
    Caused by: com.ibm.websphere.security.auth.WSLoginFailedException
    at com.ibm.ws.security.ltpa.LTPAServerObject.authenticate
    (LTPAServerObject.java:998)
    at com.ibm.ws.security.server.lm.ltpaLoginModule.login
    (ltpaLoginModule.java:643)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke
    (NativeMethodAccessorImpl.java:48)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke
    (DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:600)
    at javax.security.auth.login.LoginContext.invoke
    (LoginContext.java:795)
    at javax.security.auth.login.LoginContext.access$000
    (LoginContext.java:209)
    at javax.security.auth.login.LoginContext$4.run
    (LoginContext.java:709)
    at java.security.AccessController.doPrivileged
    (AccessController.java:251)
    at javax.security.auth.login.LoginContext.invokePriv
    (LoginContext.java:706)
    at javax.security.auth.login.LoginContext.login
    (LoginContext.java:603)
    at com.ibm.ws.security.auth.JaasLoginHelper.jaas_login
    (JaasLoginHelper.java:354)
    at com.ibm.ws.security.auth.ContextManagerImpl.login
    (ContextManagerImpl.java:4024)
    at com.ibm.ws.security.auth.ContextManagerImpl.login
    (ContextManagerImpl.java:3728)
    at com.ibm.ws.security.auth.ContextManagerImpl.login
    (ContextManagerImpl.java:3724)
    at com.ibm.ws.security.auth.ContextManagerImpl.login
    (ContextManagerImpl.java:3475)
    at com.ibm.ws.naming.util.SecurityUtil$1.run(SecurityUtil.java:115)
    at com.ibm.ws.naming.util.SecurityUtil$1.run(SecurityUtil.java:111)
    at com.ibm.ws.security.util.AccessController.doPrivileged
    (AccessController.java:118)
    at com.ibm.ws.naming.util.SecurityUtil.login(SecurityUtil.java:109)
    ... 63 more
    Caused by: com.ibm.websphere.security.PasswordCheckFailedException
    at com.ibm.ws.wim.registry.util.LoginBridge.checkPassword
    (LoginBridge.java:204)
    at com.ibm.ws.wim.registry.WIMUserRegistry$1.run
    (WIMUserRegistry.java:181)
    at com.ibm.ws.security.auth.ContextManagerImpl.runAs
    (ContextManagerImpl.java:4610)
    at com.ibm.ws.security.auth.ContextManagerImpl.runAsSystem
    (ContextManagerImpl.java:4698)
    at
    com.ibm.ws.wim.security.authz.jacc.JACCSecurityManager.runAsSuperUser
    (JACCSecurityManager.java:432)
    at
    com.ibm.ws.wim.security.authz.ProfileSecurityManager.runAsSuperUser
    (ProfileSecurityManager.java:964)
    at com.ibm.ws.wim.registry.WIMUserRegistry.checkPassword
    (WIMUserRegistry.java:170)
    at com.ibm.ws.security.registry.UserRegistryImpl.checkPassword
    (UserRegistryImpl.java:338)
    at com.ibm.ws.security.ltpa.LTPAServerObject.authenticate
    (LTPAServerObject.java:973)
    ... 83 more
    Caused by: com.ibm.websphere.wim.exception.PasswordCheckFailedException:
    CWWIM4537E No principal is found from the 'admin' principal name.
    at com.ibm.ws.wim.ProfileManager.loginImpl(ProfileManager.java:3607)
    at com.ibm.ws.wim.ProfileManager.genericProfileManagerMethod
    (ProfileManager.java:292)
    at com.ibm.ws.wim.ProfileManager.login(ProfileManager.java:400)
    at com.ibm.websphere.wim.ServiceProvider.login
    (ServiceProvider.java:485)
    at com.ibm.ws.wim.registry.util.LoginBridge.checkPassword
    (LoginBridge.java:169)

    We are taking another run at TopLink 10.1.3 and have run into this problem again.
    It turns out that this is fairly reproducable. It occurs when we remove the last item (or all of the items) from the parent collection.
    It occurs with transparent indirection on or off.
    I've added several tests to our Junit suite to detect this behavior with various objects. Sometimes they fail, sometimes they pass. Going back to TopLink 9, a couple of the tests that fail in 10 fail, but most of them pass.
    Given the number of folks who shared our probem in TopLink9, I wonder how many have a similar problem in 10. I also wonder why the behavior differs somewhat between 9 and 10. Though our expanded test suite is now detecting the behavior in 9, it is less frequent.

  • Toplink cache synchronization between two nodes using tomcat

    Hi,
    In our appcation we have two nodes. Using websphere we used to synchronize toplink cache between two nodes. Can we do same thing using tomcat.

    Yes, TopLink implements cache synchronization using JMS or RMI easily, which are not dependent on the server being used - though it JMS especially does require a JMS provider that is accessible from each node.  Cache synchronization is now cache coordination, and is described using JPA properties here:
    http://wiki.eclipse.org/EclipseLink/Examples/JPA/CacheCoordination
    the Toplink cache synchronization/coordination with JMS | EMBARCADEROS seems to be a good read for cache coordination over JMS, but is more aimed at TopLink's sessions.xml configuration.
    Best Regards,
    Chris

  • Cache coordination in 10.1.3

    Hi,
    I am using toplink cache coordination feature using JMS in version 10.1.3
    My sessions.xml for the cache coordination is given below
    <?xml version="1.0" encoding="UTF-8"?>
    <toplink-sessions version="9.0.4" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
    <session xsi:type="server-session">
    <name>CQMSession</name>
    <remote-command>
    <commands>
    <cache-sync>true</cache-sync>
    </commands>
    <transport xsi:type="jms-topic-transport">
    <!-- <topic-host-url>ormi://localhost:23791</topic-host-url> -->
    <topic-connection-factory-name>jms/CacheTopicConnectionFactory</topic-connection-factory-name>
    <topic-name>jms/CacheTopic</topic-name>
    <jndi-naming-service>
    <user-name>cqmuser</user-name>
    <password>BB742416276274A46959A54867978929</password>
    </jndi-naming-service>
    </transport>
    </remote-command>
    <event-listener-classes/>
    <logging xsi:type="toplink-log">
    <log-level>severe</log-level>
    </logging>
    I have JMS topic set up in jms.xml
    <!-- topic connection factories -->
    <topic-connection-factory
    location="jms/CacheTopicConnectionFactory"
    username="cqmuser"
    password="password"
    />
    <topic
    name="cache topic"
    location="jms/CacheTopic"
    >
    <description>topic used for cache sync</description>
    </topic>
    When I run the application, I get the exception
    Exception [TOPLINK-22103] (Oracle TopLink - 10g Release 3 (10.1.3.0.0) (Build 060118)): oracle.toplink.exceptions.RemoteCommandManagerException
    Exception Description: Could not look up remote connection under name jms/CacheTopicConnectionFactory with URL ormi://localhost:23791
    Internal Exception: javax.naming.NamingException: Lookup error: javax.naming.AuthenticationException: Not authorized; nested exception is:
         javax.naming.AuthenticationException: Not authorized [Root exception is javax.naming.AuthenticationException: Not authorized]
         at oracle.toplink.exceptions.RemoteCommandManagerException.errorLookingUpRemoteConnection(RemoteCommandManagerException.java:75)
         at oracle.toplink.remotecommand.jms.JMSTopicTransportManager.getTopicConnectionFactory(JMSTopicTransportManager.java:206)
         at oracle.toplink.remotecommand.jms.JMSTopicTransportManager.createJMSTopicRemoteConnection(JMSTopicTransportManager.java:84)
         at oracle.toplink.remotecommand.jms.JMSTopicTransportManager.createLocalConnection(JMSTopicTransportManager.java:106)
         at oracle.toplink.remotecommand.jms.JMSTopicDiscoveryManager.startDiscovery(JMSTopicDiscoveryManager.java:44)
         at oracle.toplink.remotecommand.RemoteCommandManager.initialize(RemoteCommandManager.java:132)
         at oracle.toplink.publicinterface.DatabaseSession.login(DatabaseSession.java:517)
         at oracle.toplink.tools.sessionmanagement.SessionManager.getSession(SessionManager.java:379)
         at oracle.toplink.tools.sessionmanagement.SessionManager.getSession(SessionManager.java:242)
    Any help appreciated.
    Thanks
    Priya

    Hi,
    This issue was resolved . Instead of using a custom user, use oc4jadmin and the password ( default - welcome).
    THanks
    Priya

  • Distributed Cache synchronization with JMS

    Hello,
    The documentation on Cache Synchronization using JMS lists steps to setting up JMS in the JMSClusteringService but does not list steps as to how to connect or setup connections to the various different servers inorder to synchronize between them. It lists steps for connecting to servers when using RMI but not JMS. Appreciate any additional documentation on doing this in JMS. Many thanks

    JMS, by its nature, provides the connections between the different 'servers'. If all servers connect to the same JMS service then there are no additional actions required to have the 'servers' synchronize.
    --Gordon                                                                                                                                                                                                                                                                                                                                                                                                                                                   

  • Toplink Cache not refreshed

    In my project, TOPLINK is used. To carry out the CRUD operation, Stored procedures are used on all objectcs.
    Toplink query is not used.
    In some cases, since we wanted to use the existing Stored procedures for running the business logic, toplink is not used.
    After running these procedures, we refresh the Toplink Cache by using "refreshObject(java.lang.Object p1)" method of UnitOfWork before we read the Object.
    When we read this object, the data appears to be in sinc with what is present in the database tables.
    But when we write the data once again to the database, Toplink some how refers to the Old data ( Data which was present before refreshing).
    It seems to be a strange issue.
    Kindly help.

    If you call refresh on an object already loaded in the UnitOfWork, and the object was modified before you call refresh, the refresh will override the modification done to the object.
    You should never need to call refresh.
    What you should do instead of refresh is to invalidate on session cache so when ever you read the object later, it will be refresh if was invalidated, so more efficient.
    If you use TopLink 11 JPA api you need to flush to get current transaction/uow see the modified data in db.
    But realistically, stored procedure do not work well with O-R framework, and you say Toplink query is not used, why not removing TopLink from the equation? If you want better JDBC you can use iBatis or Spring.

  • Memory leak when using JMS Cache Coordination

    We have two Weblogic Server 8.1 processes running Java 1.4.2 on Solaris using TOPLink 10.1.3 with JMS Cache Coordination. We observe that heap is filled with uncollectable instances of TOPLink-mapped classes. In our production system, under full load, this completely fills a 3.6 GB heap in 30 minutes, requiring a process restart. The problem goes away if we turn off cache coordination.
    It appears that these instances are UnitOfWork or some other kind of toplink-created clone. We have not yet been able to successfully analyse this problem with a heap profiler.
    Has anyone else experienced this this problem? Any suggestions for debugging?
    Thanks in advance.

    We do set the command manager to asychronous mode. (Our debug tracing confirms that the CommandPropagator method asynchronousPropagateCommand() is invoked, not synchronousPropagateCommand().) We started with asynchronous messaging and actually have never tried running in a synchronous mode.
    The Java bug I referenced in my last post (which I have confirmed with a stand-alone test case) indicates that, for Java 1.4.2 and earlier, is is never ok to not start() a Thread -- it will always produce a memory leak. So I am quite surprised than anyone on a pre-1.5 Java had ever had success with synchronous cache coordination messaging. Do you think it is possible all of the pre-release tests and existing customers installations of 10.1.3 cache coordination are using Java 1.5 ?!
    Our heap profiling indicates that the instances of CommandPropagator which are pinned (i.e., those not started) are allocated in the run() method of CommandPropagator itself. So it seems that the instance of CommandPropagator, after it is started, allocates another one in its run method. Looking at the bytecodes for the run() method (using javap -c) shows that in one branch of the code a second CommandPropagator is indeed allocated and then handed off to the launchContainerRunnable method of a ServerPlatform.
    Since these secondary CommandPropagators are the ones which are not started, we have looked into the WebLogic_8_1_Platform class and found that its implementation launchContainerRunnable (inherited from ServerPlatformBase) does a
    new Thread(runnable).start()where the argument runnable is the CommandPropagator.
    So the CommandPropagator itself is not started(), but is instead run an another Thread.
    We are experimenting with a custom ServerPlatform which overrides launchContainerRunnable:
        server.setServerPlatform(
            new WebLogic_8_1_Platform(server)
                public void launchContainerRunnable(Runnable runnable)
                   if (runnable instanceof Thread) ((Thread)runnable).start();
                   else super.launchContainerRunnable(runnable);
        );  This starts the argument Runnable directly if it is actually a Thread. Our early, small-scale tests indicate that this change eliminates the memory leak. We are testing now in a production-replicate environment under full load.
    But this feels like a hack. I have no idea what TOPLink behavior other than cache coordination flows through this method. Does anyone know what else this ServerPlatform method is used for? Is there a better way to do this? Are there any adverse conquences to our hack? Any suggestions would be appreciated.
    Thanks in advance.

  • TopLink 11g Cache Coordination failure in WebSphere 6.1

    Hello,
    I've recently upgraded to TopLink 11g and I am trying to make cache coordination feature work in WebSphere 6.1 using JMS. Once configured I am getting the following errors on the server side:
    [4/14/09 17:22:25:321 PDT] 00000032 SibMessage E [:] CWSIP0003E: An internal messaging error occurred Default.Topic.Space in com.ibm.ws.sib.processor.impl.LocalConsumerPoint, 1:1511:1.28, com.ibm.ws.sib.msgstore.ProtocolException: CWSIS1001E: The requested action could not be carried out as it does not comply with the resource manager's internal transaction protocol. at com.ibm.ws.sib.msgstore.transactions.MSDelegatingXAResource.addWork(MSDelegatingXAResource.java:140) at com.ibm.ws.sib.msgstore.cache.links.AbstractItemLink.cmdRemove(AbstractItemLink.java:1330) at com.ibm.ws.sib.msgstore.AbstractItem.remove(AbstractItem.java:828) at com.ibm.ws.sib.processor.impl.JSLocalConsumerPoint.receive(JSLocalConsumerPoint.java:1487) at com.ibm.ws.sib.processor.impl.ConsumerSessionImpl.receiveWithWait(ConsumerSessionImpl.java:421) at com.ibm.ws.sib.api.jms.impl.JmsMsgConsumerImpl.receiveInboundMessage(JmsMsgConsumerImpl.java:1525) at com.ibm.ws.sib.api.jms.impl.JmsMsgConsumerImpl.receive(JmsMsgConsumerImpl.java:707) at oracle.toplink.internal.remotecommand.jms.JMSTopicRemoteConnection.run(JMSTopicRemoteConnection.java:229) at java.lang.Thread.run(Thread.java:810)
    [4/14/09 17:22:25:353 PDT] 00000032 SystemOut O [TopLink Warning]: 2009.04.14 17:22:25.353--ServerSession(1261194028)--Thread(Thread[Thread-65,5,WebSphere_EJB_Timer_Service_WorkManager: WM Service Group])--Local Exception Stack:
    Exception [TOPLINK-22109] (Oracle TopLink - 11g (11.1.1.0.1) (Build 081030)): oracle.toplink.exceptions.RemoteCommandManagerException
    Exception Description: Failed to receive JMS message from JMS provider
    Internal Exception: javax.jms.JMSException: CWSIA0103E: An exception occurred while receiving a message: com.ibm.websphere.sib.exception.SIResourceException: CWSIP0003E: An internal messaging error occurred Default.Topic.Space in com.ibm.ws.sib.processor.impl.LocalConsumerPoint, 1:1526:1.28, com.ibm.ws.sib.msgstore.ProtocolException: CWSIS1001E: The requested action could not be carried out as it does not comply with the resource manager's internal transaction protocol..
         at oracle.toplink.exceptions.RemoteCommandManagerException.errorReceivingJMSMessage(RemoteCommandManagerException.java:139)
         at oracle.toplink.internal.remotecommand.jms.JMSTopicRemoteConnection.run(JMSTopicRemoteConnection.java:257)
         at java.lang.Thread.run(Thread.java:810)
    Caused by: javax.jms.JMSException: CWSIA0103E: An exception occurred while receiving a message: com.ibm.websphere.sib.exception.SIResourceException: CWSIP0003E: An internal messaging error occurred Default.Topic.Space in com.ibm.ws.sib.processor.impl.LocalConsumerPoint, 1:1526:1.28, com.ibm.ws.sib.msgstore.ProtocolException: CWSIS1001E: The requested action could not be carried out as it does not comply with the resource manager's internal transaction protocol..
         at com.ibm.ws.sib.api.jms.impl.JmsMsgConsumerImpl.receiveInboundMessage(JmsMsgConsumerImpl.java:1637)
         at com.ibm.ws.sib.api.jms.impl.JmsMsgConsumerImpl.receive(JmsMsgConsumerImpl.java:707)
         at oracle.toplink.internal.remotecommand.jms.JMSTopicRemoteConnection.run(JMSTopicRemoteConnection.java:229)
         ... 1 more
    Caused by: com.ibm.websphere.sib.exception.SIResourceException: CWSIP0003E: An internal messaging error occurred Default.Topic.Space in com.ibm.ws.sib.processor.impl.LocalConsumerPoint, 1:1526:1.28, com.ibm.ws.sib.msgstore.ProtocolException: CWSIS1001E: The requested action could not be carried out as it does not comply with the resource manager's internal transaction protocol.
         at com.ibm.ws.sib.processor.impl.JSLocalConsumerPoint.receive(JSLocalConsumerPoint.java:1521)
         at com.ibm.ws.sib.processor.impl.ConsumerSessionImpl.receiveWithWait(ConsumerSessionImpl.java:421)
         at com.ibm.ws.sib.api.jms.impl.JmsMsgConsumerImpl.receiveInboundMessage(JmsMsgConsumerImpl.java:1525)
         ... 3 more
    Caused by: com.ibm.ws.sib.msgstore.ProtocolException: CWSIS1001E: The requested action could not be carried out as it does not comply with the resource manager's internal transaction protocol.
         at com.ibm.ws.sib.msgstore.transactions.MSDelegatingXAResource.addWork(MSDelegatingXAResource.java:140)
         at com.ibm.ws.sib.msgstore.cache.links.AbstractItemLink.cmdRemove(AbstractItemLink.java:1330)
         at com.ibm.ws.sib.msgstore.AbstractItem.remove(AbstractItem.java:828)
         at com.ibm.ws.sib.processor.impl.JSLocalConsumerPoint.receive(JSLocalConsumerPoint.java:1487)
         ... 5 more
    Any idea what I am doing wrong here?
    Lukas

    Fixing listener is not enough. Old and lastest code has this for references to ServerPlatform.launchContainerRunnable, which WebSpherePlatform do not override:
    CommandPropagator:
    public void asynchronousPropagateCommand() {
    // The async logic is in the run() method
    rcm.logDebug("async_propagation", (Object[])null);
    this.rcm.getServerPlatform().launchContainerRunnable(this);
    public void propagateCommand(RemoteConnection conn) {
    Object[] arguments = { command.getClass().getName(), conn.getServiceId() };
    rcm.logDebug("propagate_command_to", arguments);
    try {
    // The result will be null on success, and an exception string on failure
    Object result = conn.executeCommand(command);
    if (result != null) {
    // An error occurred executing the remote command
    handleExceptionFromRemoteExecution(conn, (String)result);
    } catch (CommunicationException comEx) {
    // We got a comms exception.
    this.handleCommunicationException(conn, comEx);
    JMSTopicRemoteConnection:
    DiscoveryManager:
    public void startDiscovery() {
    if (rcm.isCommandProcessorASession()) {
    rcm.getCommandProcessor().processCommand(new ProfileDiscoveryStartedCommand());
    // Only start if we are currently stopped
    if (this.isDiscoveryStopped()) {
    this.rcm.getServerPlatform().launchContainerRunnable(this);
    JMSTopicTransportManager:
    public Hashtable getConnectionsToExternalServicesForCommandPropagation() {
    if(this.getConnectionsToExternalServices().isEmpty() && !this.rcm.isStopped()) {
    this.createExternalConnection();
    if(this.localConnection == null) {
    // It's a good time to create localConnection,
    // in a new thread - to return externalConnections promptly.
    this.rcm.getServerPlatform().launchContainerRunnable(new Runnable() {
    public void run() {
    try {
    createLocalConnection();
    } catch (RemoteCommandManagerException ex) {
    // Ignore exception - user had a chance to handle it in createLocalConnection method:
    // for instance to change host url and create a new local connection.
    return super.getConnectionsToExternalServicesForCommandPropagation();
    }

  • Deadlock in TopLink when using JMS listener on WebLogic

    I am experiencing a deadlock in TopLink 10.1.3 on WebLogic 9 in code that previously worked on TopLink 9.0.4 with WebLogic 8.1. As such, I'm not sure if it's due to the TopLink change, the WebLogic change or both. Anyway, we have a JMS listener (note, NOT a MessageDrivenBean) that is updating an existing TopLink cached domaing object. The JMS listener thread gets stuck when attempting to commit the transaction. The thread-dump shows that there is another thread which is blocked in the ConcurrencyManager waiting to obtain the lock on an object which is being updated by the listener thread. It appears to me that the root cause is that the Synchronization.afterCompletion() listener is running on a different thread than the one which owns the locks which were obtained beforeCompletion.
    See stack traces.
    First, the message listener thread which is waiting for participants in the transaction to commit:
    "[ACTIVE] ExecuteThread: '0' for queue: 'weblogic.kernel.Default (self-tuning)'" daemon prio=9 tid=0x3a4a4728 nid=0xa48 in Object.wait() [0x3a0cf000..0x3a0cfbec]
         at java.lang.Object.wait(Native Method)
         - waiting on <0x0c7a0908> (a weblogic.transaction.internal.ServerTransactionImpl)
         at weblogic.transaction.internal.ServerTransactionImpl.globalRetryCommit(ServerTransactionImpl.java:2665)
         - locked <0x0c7a0908> (a weblogic.transaction.internal.ServerTransactionImpl)
         at weblogic.transaction.internal.ServerTransactionImpl.globalCommit(ServerTransactionImpl.java:2570)
         at weblogic.transaction.internal.ServerTransactionImpl.internalCommit(ServerTransactionImpl.java:277)
         at weblogic.transaction.internal.ServerTransactionImpl.commit(ServerTransactionImpl.java:226)
         at weblogic.ejb.container.internal.BaseEJBObject.postInvoke1(BaseEJBObject.java:539)
         at weblogic.ejb.container.internal.StatelessEJBObject.postInvoke1(StatelessEJBObject.java:72)
         at weblogic.ejb.container.internal.BaseEJBObject.postInvokeTxRetry(BaseEJBObject.java:374)
         at com.avinamart.BusinessLogic.Bean.JobService.JobService_u1ylwo_EOImpl.submitJobAndRun(JobService_u1ylwo_EOImpl.java:1388)
         at com.avinamart.Framework.Event.Task.OptimizationTaskListener._submitAsAJob(OptimizationTaskListener.java:253)
         at com.avinamart.Framework.Event.Task.OptimizationTaskListener._submitAsAJob(OptimizationTaskListener.java:217)
         at com.avinamart.Framework.Event.Task.OptimizationTaskListener.processMessage(OptimizationTaskListener.java:344)
         at com.emptoris.base.event.EPASSMessageBaseListener.onMessage(EPASSMessageBaseListener.java:722)
         at weblogic.jms.client.JMSSession.onMessage(JMSSession.java:3824)
         at weblogic.jms.client.JMSSession.execute(JMSSession.java:3738)
         at weblogic.jms.client.JMSSession.pushMessage(JMSSession.java:3253)
         at weblogic.jms.client.JMSSession.invoke(JMSSession.java:4195)
         at weblogic.messaging.dispatcher.Request.wrappedFiniteStateMachine(Request.java:674)
         at weblogic.messaging.dispatcher.DispatcherServerRef.invoke(DispatcherServerRef.java:262)
         at weblogic.messaging.dispatcher.DispatcherServerRef.handleRequest(DispatcherServerRef.java:134)
         at weblogic.messaging.dispatcher.DispatcherServerRef.access$000(DispatcherServerRef.java:36)
         at weblogic.messaging.dispatcher.DispatcherServerRef$1.run(DispatcherServerRef.java:105)
         at weblogic.work.ExecuteThread.execute(ExecuteThread.java:207)
         at weblogic.work.ExecuteThread.run(ExecuteThread.java:179)
    Next, the other thread which is participating in the transaction which is stuck:
    "[ACTIVE] ExecuteThread: '2' for queue: 'weblogic.kernel.Default (self-tuning)'" daemon prio=5 tid=0x3adb80a0 nid=0xb30 in Object.wait() [0x3c7af000..0x3c7afd6c]
         at java.lang.Object.wait(Native Method)
         - waiting on <0x0c7a0000> (a oracle.toplink.internal.helper.ConcurrencyManager)
         at java.lang.Object.wait(Object.java:474)
         at oracle.toplink.internal.helper.ConcurrencyManager.acquire(ConcurrencyManager.java:76)
         - locked <0x0c7a0000> (a oracle.toplink.internal.helper.ConcurrencyManager)
         at oracle.toplink.internal.identitymaps.CacheKey.acquire(CacheKey.java:80)
         at oracle.toplink.internal.identitymaps.FullIdentityMap.remove(FullIdentityMap.java:164)
         at oracle.toplink.internal.identitymaps.HardCacheWeakIdentityMap.remove(HardCacheWeakIdentityMap.java:82)
         at oracle.toplink.internal.helper.WriteLockManager.releaseAllAcquiredLocks(WriteLockManager.java:363)
         at oracle.toplink.publicinterface.UnitOfWork.afterTransaction(UnitOfWork.java:2123)
         at oracle.toplink.transaction.AbstractSynchronizationListener.afterCompletion(AbstractSynchronizationListener.java:135)
         at oracle.toplink.transaction.JTASynchronizationListener.afterCompletion(JTASynchronizationListener.java:66)
         at weblogic.transaction.internal.ServerSCInfo.callAfterCompletions(ServerSCInfo.java:862)
         at weblogic.transaction.internal.ServerTransactionImpl.callAfterCompletions(ServerTransactionImpl.java:2913)
         at weblogic.transaction.internal.ServerTransactionImpl.afterCommittedStateHousekeeping(ServerTransactionImpl.java:2806)
         at weblogic.transaction.internal.ServerTransactionImpl.setCommittedUnsync(ServerTransactionImpl.java:2857)
         at weblogic.transaction.internal.ServerTransactionImpl.ackCommit(ServerTransactionImpl.java:1097)
         - locked <0x0c7a0908> (a weblogic.transaction.internal.ServerTransactionImpl)
         at weblogic.transaction.internal.CoordinatorImpl.ackCommit(CoordinatorImpl.java:211)
         at weblogic.transaction.internal.CoordinatorImpl_WLSkel.invoke(Unknown Source)
         at weblogic.rmi.internal.BasicServerRef.invoke(BasicServerRef.java:517)
         at weblogic.rmi.internal.BasicServerRef$1.run(BasicServerRef.java:407)
         at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:363)
         at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:147)
         at weblogic.rmi.internal.BasicServerRef.handleRequest(BasicServerRef.java:403)
         at weblogic.rmi.internal.BasicServerRef.access$300(BasicServerRef.java:56)
         at weblogic.rmi.internal.BasicServerRef$BasicExecuteRequest.run(BasicServerRef.java:934)
         at weblogic.work.ExecuteThread.execute(ExecuteThread.java:207)
         at weblogic.work.ExecuteThread.run(ExecuteThread.java:179)
    Is this the same concurrency bug which was fixed in 10.1.3.1??? As I am writing this, I am attempting to build the application with the updated TopLink jar to test for myself. Has anyone else seen this scenario with WebLogic? I should also point out that the problem only occurs when the listener is running on a separate server than the one hosting the JMS queue it reads from. It may be that when the listener runs on the same server, it does not use multiple threads in the transaction.
    Any ideas are greatly appreciated.
    - Bruno

    We've got the same kind of issue with toplink 10.1.3.0.0 and bea weblogic 8.1 SP5.
    I 've not tried with 10.1.3.1.0, did you?
    Do you have a new status for this issue.
    Chris

Maybe you are looking for