More Control of Cache Synchronization in a Cluster?

If I understand correctly, the cache synchronization manager, by default, sends out a changeSet message to the network for any UOW write commit. Since I have a control on certain objects not using Toplink’s cache, I actually do not need the cache synchronization manger to broadcast any update on these objects. In other words, I do not want the cache synchronization manger to send out the changeSet message to the network if I only update those objects that are configured to always read from the database. In this way, I may be able to avoid some unnecessary changeSet message propagations.
My question is that whether I have a way, either in sessions.xml or in Java API, to tell the cache synchronization manger not to send out the changeSet message for a given specific UOW write commit (although I still need the data update to be committed to the database).

Many thanks for the reply and glad to see something better is on the way again!
If I choose to set the cache synchronization manager to null, do the UOW write for a given class which is always refreshed from the database, and then reset the cache synchronization manger back to the previous instance, do I need to do the following afterwards:
          // must login/re-login to initialize cache synchronization
          if (session.isConnected()) {
               session.logout();
          session.login();
to ensure the manager be reset properly?
Since the propagation of the changeSet message is triggered by the UOW, can I have more control at the UOW level to turn on/off the cache synchronization manager?
If I understand correctly, in Toplink 10.1.3, I can configure the cache synchronization manger globally at the session level, and also have the option in the same application to set a given number of classes not be cache synchronized in a cluster at the descriptor level to overrule the session global settings. I should not have to choose one over the other. Once these are done in configurations, what is the reason that I still have to choose either to send the changeSet or to invalidate the message?

Similar Messages

  • Toplink in Cluster without Cache Synchronization

    Hello,
    I’m trying to setup my J2EE app that uses Toplink for its persistence in a 9iAS cluster. For the first release I’m not planning to use Toplink Cache synchronization but planning to deploy the app in 9iAS cluster of nodes say A and B. By default all the requests goes to one app server (say A) in the cluster. When the app in node A goes down app in node B starts and accepts all the requests transparently. For this scenario:
    1.     Do I need to use any Toplink feature/API?
    2.     What design considerations I need to consider for my app so that I can achieve my short-term goal and the long-term goal of implementing Cache synchronization easily?
    Any references/pointers would help me.
    Thanks
    -Mani

    TopLink Cache Coordination (Synchronization) can be enabled at any point during your development. And is not required on a system running in a cluster. No special TopLink API's are required when running in the cluster.
    There should be no design decisions made now that would affect the use of Cache Coordination (Synchronization) in the future.
    --Gordon

  • Error handling for distributed cache synchronization

    Hello,
    Can somebody explain to me how the error handling works for the distributed cache synchronization ?
    Say I have four nodes of a weblogic cluster and 4 different sessions on each one of those nodes.
    On Node A an update happens on object B. This update is going to be propogated to all the other nodes B, C, D. But for some reason the connection between node A and node B is lost.
    In the following xml
    <cache-synchronization-manager>
    <clustering-service>...</clustering-service>
    <should-remove-connection-on-error>true</should-remove-connection-on-error>
    If I set this to true does this mean that the Toplink will stop sending updates from node A to node B ? I presume all of this is transparent. In order to handle any errors I do not have to write any code to capture this kind of error .
    Is that correct ?
    Aswin.

    This "should-remove-connection-on-error" option mainly applies to RMI or RMI_IIOP cache synchronization. If you use JMS for cache synchronization, then connectivity and error handling is provided by the JMS service.
    For RMI, when this is set to true (which is the default) if a communication exception occurs in sending the cache synchronization to a server, that server will be removed and no longer synchronized with. The assumption is that the server has gone down, and when it comes back up it will rejoin the cluster and reconnect to this server and resume synchronization. Since it will have an empty cache when it starts back up, it will not have missed anything.
    You do not have to perform any error handling, however if you wish to handle cache synchronization errors you can use a TopLink Session ExceptionHandler. Any cache synchronization errors will be sent to the session's exception handler and allow it to handle the error or be notified of the error. Any errors will also be logged to the TopLink session's log.

  • 10.1.3 JMS Cache Synchronization on OC4J

    Hi,
    We're using stand-alone OC4j 10.1.3.0 along with TopLink 10.1.3.0 (packaged with OC4j). In enabling JMS cache synchronization, I get the following error message:
    Exception [TOPLINK-12000] (Oracle TopLink - 10g Release 3 (10.1.3.0.0) (Build 060118)): oracle.toplink.exceptions.CommunicationException
    Exception Description: Error Sending connection service to jms/Topic/ToplinkCacheSync.
    Internal Exception: javax.jms.JMSException: TopicSubscriber[Oc4jJMS.Consumer.arkansas.6e2ec2b0:1117159d1ca:-7fff.65,Topic[ToplinkCacheSync],null,null,false]: cannot invoke method "setMessageListener" within the J2EE container.
    at oracle.toplink.exceptions.CommunicationException.errorSendingConnectionService(CommunicationException.java:40)
    at oracle.toplink.remote.CacheSynchronizationManager.addRemoteConnection(CacheSynchronizationManager.java:175)
    at oracle.toplink.remote.jms.JMSClusteringService.retreiveRemoteSessions(JMSClusteringService.java:198)
    at oracle.toplink.remote.jms.JMSClusteringService.run(JMSClusteringService.java:175)
    Caused by: javax.jms.JMSException: TopicSubscriber[Oc4jJMS.Consumer.arkansas.6e2ec2b0:1117159d1ca:-7fff.65,Topic[ToplinkCacheSync],null,null,false]: cannot invoke method "setMessageListener" within the J2EE container.
    at com.evermind.server.jms.JMSUtils.make(JMSUtils.java:1034)
    at com.evermind.server.jms.JMSUtils.toJMSException(JMSUtils.java:1114)
    at com.evermind.server.jms.JMSUtils.toJMSException(JMSUtils.java:1085)
    at com.evermind.server.jms.JMSUtils.assertNotContainer(JMSUtils.java:1500)
    at com.evermind.server.jms.EvermindMessageConsumer.setMessageListener(EvermindMessageConsumer.java:217)
    at oracle.toplink.remote.jms.JMSClusteringService.connectBackToRemote(JMSClusteringService.java:53)
    at oracle.toplink.remote.CacheSynchronizationManager.addRemoteConnection(CacheSynchronizationManager.java:168)
    ... 2 more
    It is, therefore, my assumption that Toplink is using JMS 1.0.2b while OC4J is using JMS 1.1. Who can:
    1) Verify or debunk my assumption?
    2) Point me to a work-around?
    Perhaps my config is incorrect? Here's a sessions.xml snippet, in case it helps:
    <cache-synchronization-manager>
    <clustering-service xsi:type="jms-clustering">
    <naming-service-url>ormi://localhost:23791/ems</naming-service-url>
    <jndi-user-name>oc4jadmin</jndi-user-name>
    <jndi-password>oc4j</jndi-password>
    <naming-service-initial-context-factory-name>com.evermind.server.rmi.RMIInitialContextFactory</naming-service-initial-context-factory-name>
    <jms-topic-connection-factory-name>jms/Topic/ToplinkCacheSyncConnectionFactory</jms-topic-connection-factory-name>
    <jms-topic-name>jms/Topic/ToplinkCacheSync</jms-topic-name>
    </clustering-service>
    <remove-connection-on-error>false</remove-connection-on-error>
    </cache-synchronization-manager>
    Many thanks in advance,
    --Todd                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

    Thank you very much for your contribution! Yes, indeed, that was my main issue. A sessions.xml section that looks like the following (instead of the <cache-synchronization-manager> section above) does fix the problem:
    <remote-command>
    <commands>
    <cache-sync>true</cache-sync>
    </commands>
    <transport xsi:type="jms-topic-transport">
    <topic-host-url>ormi://localhost:23791/ems</topic-host-url>
    <topic-connection-factory-name>jms/Topic/ToplinkCacheSyncConnectionFactory</topic-connection-factory-name>
    <topic-name>jms/Topic/ToplinkCacheSync</topic-name>
    <jndi-naming-service>
    <user-name>oc4jadmin</user-name>
    <password>oc4j</password>
    <initial-context-factory-name>com.evermind.server.rmi.RMIInitialContextFactory</initial-context-factory-name>
    </jndi-naming-service>
    </transport>
    </remote-command>
    Thanks again,
    --Todd                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

  • Cache Synchronization Exception Handling

    I am setting up cache synchronization on WebLogic using JMS. I am looking into writing an exception handler to handle cache synchronization exceptions. The following statement in the documentation caught my attention:
    “As mentioned above, the TopLink cache does not begin the merge or update process until the database transaction has already been committed. This is quite beneficial in that it avoids letting uncommitted data into the shared cache, but should be recognized where transactional synchronization is considered. In cases where a merge may have failed there is no way to roll back the changes made to the database (although it is questionable whether this would be a good idea in any case). As a consequence, failures during remote merging can leave the cache in an inconsistent state. This makes it important to handle any errors that occur by performing cache normalization actions, such as resetting the cache, or even the server.”
    Suppose we have two app server instances, A and B. Instance A commits a change and sends the update notification to instance B. The merge fails on instance B with an optimistic lock exception.
    - I assume that a CacheSynchronizationException will be thrown. Will it be thrown on instance A, B, or both?
    - At this point which cache is inconsistent; A, B, or both?
    - The documentation suggests resetting the cache, but this seems a rather severe way of dealing with the problem. Is it feasible / effective to just refresh the objects in the change set of the CacheSynchronizationException?
    This is a simple exception handler. On receiving a CacheSynchronizationException it resets the cache and re-throws the exception.
    class ToplinkExceptionHandler implements ExceptionHandler{
         public Object handleException(RuntimeException exception) throws DatabaseException{
              if(exception instanceof CacheSynchronizationException){){
                   myServerSession.initializeAllIdentityMaps();
                   throw exception;
              }else{
                   throw exception;
    - Is this approach effective?
    - Once the cache is reset should the exception be re-thrown or should I consider it handled and swallow it? If I do swallow it what should the method return?
    Any advice would be appreciated.

    I had to fix a few errors (in our code) before getting it working. Since I have multiple sessions, I had to specify different multicast ports (actually I used a different multicast address itself) for each of the sessions. I was not setting the announcement delay on one of the sesssions and that was why it was announcing immediately upon coming up. Also I had to explicitly set asynchronous to false because it is true by default.
    BTW, we are not using CMP (entity beans) rather Java Objects. Our deployment has two Apache/Tomcat machines and two WebLogic machines. The WebLogic servers are in a round-robin cluster. The cache synchronization seems to be working fine for this configuration.
    Thanks.
    Anand R

  • Cache Synchronization

    I am attempting to setup Toplink Cache synchronization using oracle.toplink.remote.rmi.RMIJNDIClusteringService in a clustered environment
    When I launch my server and perform operations I see messages as follows
    Announcement sent from 5ff7180-10598c5d31a--7fff192-168-0-4-381481356
    I configured my session file as follows
    <cache-synchronization-manager>
    <clustering-service>
    oracle.toplink.remote.rmi.RMIJNDIClusteringService
    </clustering-service>
    <naming-service-initial-context-factory-name>
    com.ibm.websphere.naming.WsnInitialContextFactory
    </naming-service-initial-context-factory-name>
    <naming-service-url>iiop://localhost:2809</naming-service-url>
    </cache-synchronization-manager>
    How does Toplink know about the existence of other servers in the cluster ? ( since I do not specify explictly about other members in the cluster in any toplink config file or otherwise)
    How can I ensure that all servers in the cluster are getting synchronized.
    Details
    Toplink version 9.0.4.5
    Application Server : WebSphere 5.0.2
    Thanks
    sk

    We have this setup with the following configuration:
    <cache-synchronization-manager>
    <clustering-service>oracle.toplink.remote.rmi.RMIJNDIClusteringService</clustering-service>
    <multicast-port>6018</multicast-port>
    <multicast-group-address>226.1.2.3</multicast-group-address>
    <is-asynchronous>false</is-asynchronous>
    <should-remove-connection-on-error>true</should-remove-connection-on-error>
    <naming-service-url>iiop://localhost:1900</naming-service-url>
    <naming-service-initial-context-factory>com.ibm.websphere.naming.WsnInitialContextFactory</naming-service-initial-context-factory>
    </cache-synchronization-manager>
    However, all attempts at locating any packets coming across that port have produced no results. Are we missing something?
    The problem we are seeing is that someone is modifying data in one session and another user in another session is not seeing the updates. The problem is intermittent.
    Thanks,
    Dan

  • JMS Cache Synchronization - Merge or Database Read?

    When an object in one JVM is changed does TopLink' JMS cache synchronization mechanism merge the changes into the other JVMS in a cluster or does it just signal that the object is dirty and the object is re-read from the database?
    If the answer is 'merge' does a post merge event get called on the object being merged?
    thanks
    Steve

    In TopLink 10.1.3 both can happen, the changes can be merged or an object can be marked invalid and TopLink will refresh the object as needed. In 9.0.4.X the changes will be merged into the other caches (if an object of correct version exists in that cache).
    In the case of a merge postMerge() event will be called.
    --Gordon

  • 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

  • Exception [TOPLINK-18001] (Cache synchronization)

    Hi,
    While trying to turn on cache synchronization, getting this exception (see below).
    What could be wrong?
    Interne Exception: weblogic.jms.common.JMSException: Error deserializing objec
         at oracle.toplink.exceptions.JMSProcessingException.buildDefault(JMSProcessingException.java:20
         at oracle.toplink.remote.jms.TopLinkMessageListener.onMessage(TopLinkMessageListener.java:60
         at weblogic.jms.client.JMSSession.onMessage(JMSSession.java:2596
         at weblogic.jms.client.JMSSession.execute(JMSSession.java:2516
         at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:197
         at weblogic.kernel.Kernel.execute(Kernel.java:336
         at weblogic.kernel.Kernel.execute(Kernel.java:360
         at weblogic.kernel.Kernel.execute(Kernel.java:348
         at weblogic.jms.client.JMSSession.pushMessage(JMSSession.java:2392
         at weblogic.jms.client.JMSSession.invoke(JMSSession.java:2919
         at weblogic.jms.dispatcher.Request.wrappedFiniteStateMachine(Request.java:609
         at weblogic.jms.dispatcher.DispatcherImpl.dispatchAsyncInternal(DispatcherImpl.java:128
         at weblogic.jms.dispatcher.DispatcherImpl.dispatchOneWay(DispatcherImpl.java:312
         at weblogic.jms.dispatcher.DispatcherImpl_WLSkel.invoke(Unknown Source
         at weblogic.rmi.internal.BasicServerRef.invoke(BasicServerRef.java:466
         at weblogic.rmi.internal.BasicServerRef$1.run(BasicServerRef.java:409
         at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:353
         at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:144
         at weblogic.rmi.internal.BasicServerRef.handleRequest(BasicServerRef.java:404
         at weblogic.rmi.internal.BasicExecuteRequest.execute(BasicExecuteRequest.java:30
         at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:197
         at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:170
    Please help!
    THX.

    Hi Gordon,
    Sorry i don't know what class.
    The Excpetion string don't give more information
    BEA-040368 14.06.2005 14.36 Uhr IRST Error JMS The following exception has occurred:
    Lokaler Exception-Stack:
    Exception [TOPLINK-18001] (OracleAS TopLink - 10g (9.0.4.5) (Build 040930)): oracle.toplink.exceptions.JMSProcessingExceptio
    Exception-Beschreibung: Fehler bei der Verarbeitung von ankommender JMS-Meldun
    Interne Exception: weblogic.jms.common.JMSException: Error deserializing objec
         at oracle.toplink.exceptions.JMSProcessingException.buildDefault(JMSProcessingException.java:20
         at oracle.toplink.remote.jms.TopLinkMessageListener.onMessage(TopLinkMessageListener.java:60
         at weblogic.jms.client.JMSSession.onMessage(JMSSession.java:2596
         at weblogic.jms.client.JMSSession.execute(JMSSession.java:2516
         at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:197
         at weblogic.kernel.Kernel.execute(Kernel.java:336
         at weblogic.kernel.Kernel.execute(Kernel.java:360
         at weblogic.kernel.Kernel.execute(Kernel.java:348
         at weblogic.jms.client.JMSSession.pushMessage(JMSSession.java:2392
         at weblogic.jms.client.JMSSession.invoke(JMSSession.java:2919
         at weblogic.jms.dispatcher.Request.wrappedFiniteStateMachine(Request.java:609
         at weblogic.jms.dispatcher.DispatcherImpl.dispatchAsyncInternal(DispatcherImpl.java:128
         at weblogic.jms.dispatcher.DispatcherImpl.dispatchOneWay(DispatcherImpl.java:312
         at weblogic.jms.dispatcher.DispatcherImpl_WLSkel.invoke(Unknown Source
         at weblogic.rmi.internal.BasicServerRef.invoke(BasicServerRef.java:466
         at weblogic.rmi.internal.BasicServerRef$1.run(BasicServerRef.java:409
         at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:353
         at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:144
         at weblogic.rmi.internal.BasicServerRef.handleRequest(BasicServerRef.java:404
         at weblogic.rmi.internal.BasicExecuteRequest.execute(BasicExecuteRequest.java:30
         at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:197
         at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:170
    >

  • How to get more control over DVR recordings

    Looking for some advice on how to make sure the DVR records (and keeps) the episodes I want.  
    An example:
    I want to record a series that is still producing new episodes, but is also in repeats in syndication.  For example, Big Bang Theory.  This has new episodes each week on CBS, but has about twenty or so repeats each day on TBS.
    Due to the high number of repeats, any new episodes pretty quickly get overwritten by the repeats.  So is there a way to record both first-run and repeat episodes, but prevent the first-runs from getting overwritten before I can watch them?

    GRubinstein1 wrote:
    I have no idea if the format has recently been changed or what the issue is, but when I try to get more control over my DVR recordings, I can't. What I mean by that is that I cannot alter "First-Run and Repeats" to "First-Run Only," I cannot specify the specific channel to record on, I cannot say how many episodes I want it to keep, etc. Here is a step-by-step guide of what I do and what the problem is:
    I press the "menu" button on the remote. I scroll down to DVR. I select the option of "manage series recordings." I select one of my shows. I'll use "Masters of Sex" as my example. I select "Masters of Sex." It's at this point where I get a problem. When I select "Masters of Sex," the only option I get is to cancel the series. No option to only record first-runs. No option to keep only 3 episodes instead of 5. No option to change it so it saves until I manually record it. Nothing. I've tried not selecting "Masters of Sex" and instead using the right arrow button to scrol over to the settings of the show. But nothing happens when I do that. It doesn't give me access to these options. This is incredibly frustrating because not only do the shows delete automatically at a certain point, but it records EVERY SINGLE AIRING OF EVERY SINGLE SHOW I RECORD. This means I have to go through several times a day to the "Scheduled Recordings" section and delete scheduled recordings of shows I have already seen. It's absolutely ridiculous, particularly for cable shows, which air episodes frequently throughout the week. Please help me if you can.
    Put simply, I cannot change the settings on how I record each show.
    Try the Box's Menu/customer support/tops support tools/Fix Fios TV option. (exact working may be different on your box)

  • Does anyone know how the cutout filter works and is there a way of achieving the same effect without using filters to get more control over final look?

    does anyone know how the cutout filter works and is there a way of achieving the same effect without using filters to get more control over final look?

    Several ways to get similar results.  Image > Adjustments > Posturize with low values similar to what you'd use n Cutout.  This is the most flexible way I can think of as you keep the image in RGB mode with layers intact.  A more radical approach would be to reduce bit depth using Indexed Colour.  You'll need to experiment with settings, try changing Forced to Primaries, and Matte to Foreground Color.  There's no going back from this route, although you can change the mode back to RGB to re-enable layers, adjustment layers etc.
    A nice thing about the Filter gallery filters is that you can change the layer to a Smart object with all the control that gives you.
    Now if only this forum could filter out bizarre content.

  • Re: More control over html tags needed

    I have trying for a while to find an elegant solution to printing reports in such a way as to have headers and footers repeated on every printed page.
    <BR><BR><BR>
    The two main solutions seem to be either using PDF (using FOP) or controlling the size of the regions anually (by hardcoding heights etc.). I am confident that with more control over the html tags (or the ability to place my own) around certain areas the problem could be solved very simply with CSS.
    <BR><BR><BR>
    What I would like is a way to change the way that Apex treats table headers.
    <BR><BR><BR>
    Presently it places the headers within a tbody tag and the uses th for every column. Ideally I would like to see this changes from tbody to thead. Given that the chances of this happening in the near future are minimal (not something that I am upset about as it would not be logical to change such things every time someone wants things to suite them better), I would like to be able to place a tag either before or after the tbody tag.
    <BR><BR><BR>
    Something like:
    <BR><BR><BR>
    div id="tableheaders"
    <BR><BR><BR>
    If anyone knows how to do this your help will be greatly appreciated. Given that, printing repeated headings can be controlled relatively simply.

    Hello Andrew,
    I believe the following might be of help - placing <thead> and </thead> around headers
    Regards,
    Arie.

  • Cache Synchronization with JMS and a Message Driven Bean (MDB)

    If I understand correctly, Toplink ueses the following configuration info to find the target to publish its session messages to a JMS server (having its URL as below) which provides the JNDI service that Toplink needs to look up the topic:
    <cache-synchronization-manager>
    <clustering-service> oracle.toplink.remote.jms.mdb.JMSPublishingOnlyClusteringService
    </clustering-service>
    <should-remove-connection-on-error>false</should-remove-connection-on-error>
    <!-- both of the following tags are user specified and must correspond to -->
    <!-- the settings that the user has made, manually, to the JMS Service -->
    <jms-topic-connection-factory-name> jms/TopLinkTopicConectionFactory
    </jms-topic-connection-factory-name>
    <jms-topic-name>jms/TopLinkCacheSynchTopic</jms-topic-name>
    <!-- both of the following tags will be required if OracleAS TopLink -->
    <!-- is not running in the same JVM as the JNDI service that is hosting the JMS Topic -->
    <naming-service-url>ormi://localhost:23791</naming-service-url>
    <naming-service-initial-context-factory> com.evermind.server.rmi.RMIInitialContextFactory </naming-service-initial-context-factory></cache-synchronization-manager>
    The MDB also uses the same JNDI service provided by the JMS server to listen to the topic which is named in the ejb-jar.xml file:
    <enterprise-beans>
    <message-driven>
    <display-name>TopLink clustering MDB</display-name>
    <ejb-name>TopLinkClusteringMDB</ejb-name>
    <ejb-class>com.mycompany.mdb.ClusteringMDB</ejb-class>
    <transaction-type>Container</transaction-type>
    <message-driven-destination> <destination-type>javax.jms.Topic</destination-type>
    </message-driven-destination>
    <env-entry>
    <description>TopLink session name</description>
    <env-entry-name>tl_session_name_for_mdb</env-entry-name>
    <env-entry-type>java.lang.String</env-entry-type>
    <env-entry-value>Employee_Session</env-entry-value>
    </env-entry>
    <resource-ref> <description>description</description>
    <res-ref-name>jms/TopLinkTopicConectionFactory</res-ref-name>
    <res-type>javax.jms.TopicConnectionFactory</res-type>
    <res-auth>Application</res-auth>
    <res-sharing-scope>Shareable</res-sharing-scope>
    </resource-ref>
    <resource-env-ref>
    <resource-env-ref-name> jms/TopLinkCacheSynchTopic</resource-env-ref-name>
    <resource-env-ref-type>javax.jms.Topic</resource-env-ref-type> </resource-env-ref>
    </message-driven></enterprise-beans>
    To do this, the EJB container that hosts the above MDB needs to be configured to know where the JMS server is by using the above URL same as in the Toplink sessions.xml file.
    I am not clear that who provides the JNDI service for the Toplink session name lookup used by the MDB:
    // Obtain the Session name configured in the environment variable
    String sessionName = (String) myEnv.lookup(TOPLINK_SESSION_NAME);
    session = SessionManager.getManager().getSession(sessionName);
    so that the MDB can find the currently running Toplink session and communicate with it.
    Can anybody help answer my above question and correct my understandings?
    Many thanks!

    Although TopLink is running in the application server’s VM, the only notable integration points with the server are for JTA and user-defined data sources. All of the work performed to get a session via SessionManager occurs solely within TopLink. When the call is made to retrieve a session, you aren’t getting the ‘active’ session identified by “Employee_Session” that is registered with the application server, rather a new session is created using the definition that exists for “Employee_Session” in sessions.xml.
    When the call ‘session = SessionManager.getManager().getSession(“Employee_Session”)’ is made, the SessionManager simply looks for sessions.xml at the root level of its deployed jars or classpath, then looks for the “Employee_Session” tag within sessions.xml. If a session exists in the file with that name then a TopLink session object is created and returned.
    Note that setting an environment entry as mentioned above simply allows for the session name to be declared dynamically. The call to ‘myEnv.lookup(“tl_session_name_for_mdb”)’ simply asks the bean’s environment for the <env-entry-value> that matches the <env-entry-name>. That string is then used in SessionManager (no different than a hard coded value would be) to identify the session in sessions.xml that is to be loaded.
    I hope this makes sense.

  • Controlling EJB Cache & Warning BEA-010001 in 8.1

    Background: Migrated from 6.1 to 8.1. Using CMP with template.j modified (migrated).
    Problem:
    1. Could not use any Entities which uses Entity Cache. It throws weblogic.ejb20.cache.CacheFullException
    during ejbLoad. My existing Cache parameters are (anyway, it is no different from
    6.1 where itz working fine)
    <pool>
    <max-beans-in-free-pool>100</max-beans-in-free-pool>
    </pool>
    <entity-cache>
    <max-beans-in-cache>100</max-beans-in-cache>
    <idle-timeout-seconds>610</idle-timeout-seconds>
    <read-timeout-seconds>60</read-timeout-seconds>
    <concurrency-strategy>Database</concurrency-strategy>
    </entity-cache>
    Is there any new configuration which needs to be set for 8.1? Redirection to
    some checklist for controlling there cache parameter would be helpful?
    2. While deploying my Beans it shows up Warning BEA-010001. Documentation says,
    specify in weblogic-ejb-jar.xml<weblogic-ejb-jar> <disable-warning>BEA-010001
    | BEA-010054</disable-warning>..</weblogic-ejb-jar>. I have thousands of beans
    deployed in the server my warning message dumps my console with these messages
    hiding critical error messages. Is there any 'additional parameters' to stop
    this warning or route this warning to a separate log file?
    TIA
    JAK

    Hi Jak,
    max-beans-in-cache equal 100 is way too low for any real life application.
    I'm not sure why it worked for you in 6.1. I remember setting it was broken
    in 6.1 at some point.
    Regards,
    Slava Imeshev
    "jak" <[email protected]> wrote in message
    news:3f07e7c9$[email protected]..
    >
    Background: Migrated from 6.1 to 8.1. Using CMP with template.j modified(migrated).
    >
    Problem:
    1. Could not use any Entities which uses Entity Cache. It throwsweblogic.ejb20.cache.CacheFullException
    during ejbLoad. My existing Cache parameters are (anyway, it is nodifferent from
    6.1 where itz working fine)
    <pool>
    <max-beans-in-free-pool>100</max-beans-in-free-pool>
    </pool>
    <entity-cache>
    <max-beans-in-cache>100</max-beans-in-cache>
    <idle-timeout-seconds>610</idle-timeout-seconds>
    <read-timeout-seconds>60</read-timeout-seconds>
    <concurrency-strategy>Database</concurrency-strategy>
    </entity-cache>
    Is there any new configuration which needs to be set for 8.1? Redirectionto
    some checklist for controlling there cache parameter would be helpful?
    2. While deploying my Beans it shows up Warning BEA-010001. Documentationsays,
    specify in weblogic-ejb-jar.xml<weblogic-ejb-jar><disable-warning>BEA-010001
    | BEA-010054</disable-warning>..</weblogic-ejb-jar>. I have thousands ofbeans
    deployed in the server my warning message dumps my console with thesemessages
    hiding critical error messages. Is there any 'additional parameters' tostop
    this warning or route this warning to a separate log file?
    TIA
    JAK

  • Installation guide Oracle cloud Control Agents on a Windows failover cluste

    Hello Experts,
    i have to install Oracle cloud control agent on windows fail-over cluster. i could not found any document on oracle support site/ internet.
    here are the requirement:
    i have two hosts (host1 and host2) which are in windows cluster environment (active/passive). means, one node will hold the cluster service/resource at a time.
    if primary node (host1) is down, Microsoft cluster ware will fail-over cluster resource to host2 automatically.
    any one deployed 12c Agents on windows fail-over clustered environment. if yes, please provide hints / procedure.
    Thanks
    pavan

    Hi Pavan,
    Please find the following document:
    How to Configure Grid Control Agents in Windows HA - Failover Cluster Environments (Doc ID 464191.1)
    For 12C Agent install, you can proceed with the silent install passing a virtual hostname in silent method also using the following document:
    How to Install EM 12c Agent using Silent Install Method with Response File (Doc ID 1360083.1)
    Best Regards,
    Venkat

Maybe you are looking for