Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[eclipselink-users] JMS Cache Coordination problem (glassfish/EclipseLink)



Hi,

i'm facing a problem which makes me crazy !

i'm trying to configure a JMS Cache coordination, between two separate glassfish server (on two different machine) WITHOUT cluster ;) (maybe clustering will be the next step)

So, i have implements my SessionCustomizer like this:
public void customize(Session session) throws Exception {
        System.out.println("WAAAAA customize [sessionCust] !");
        session.setProperty("cachecoordination.protocol", "jms" );

RemoteCommandManager commandMgr = new RemoteCommandManager((CommandProcessor)session); JMSTopicTransportManager transportMgr = new JMSTopicTransportManager(commandMgr); transportMgr.setTopicHostUrl("file:///D:/dev/programs/HmersJMS-1.13/objectStore");
        transportMgr.setTopicConnectionFactoryName("wsConnectionFactory");
        transportMgr.setTopicName("cacheCoordinationTopic");
        transportMgr.setUserName("admin");
        transportMgr.setPassword("admin");
transportMgr.setInitialContextFactoryName("com.sun.jndi.fscontext.RefFSContextFactory");

        commandMgr.setTransportManager(transportMgr);
        ((DatabaseSession)session).setCommandManager(commandMgr);
        ((DatabaseSession)session).setShouldPropagateChanges(true);

        // Start joining the cluster
        if(session.isConnected ()) {
            ((DatabaseSession)session).getCommandManager().initialize();
        } else {
            ((DatabaseSession)session).login();
        }
    }

I created my object store with imqadmin, my TopicConnectionFactory and my topic. I deploy my webapp on my two glassfish without problems, when a change is made on one instance, a JMS message is successfully sent to the another.

BUT ! when the instance received the JMS message i have a strange warning

[#|2010-04-15T16:32:18.191 0200|WARNING|sun-appserver2.1|org.eclipse.persistence.session.file:/D:/dev/programs/servers/glassfishV2.1.1/domains/domain1/applications/j2ee-modules/WebSuivi2.0-Web-1.4.1-SNAPSHOT/WEB-INF/lib/Data-core-1.2-SNAPSHOT.jar_data-client|_ThreadID=35;_ThreadName=Thread-1666;_RequestID=8c5cc585-2c67-4199-ba23-499eea8948d3;|Warning: Local JMSTopicRemoteConnection[Service[EclipseLinkCommandChannel, f284b4ca-85ec-467d-b584-f15b79afa97d, file:///D:/dev/programs/HmersJMS-1.13/objectStore], topic cacheCoordinationTopic]:

received message containg an object of type org.eclipse.persistence.sessions.coordination.MergeChangeSetCommand instead of expected type RemoteCommand.|#]


and the coordination doesn't work,

any idea ?
best regards




Back to the top