Pull replication doesn't work with DB2

acct4sf
2005-07-25
2013-04-22
  • acct4sf
    acct4sf
    2005-07-25

    I'm exploring the use of Replicator 1.8 and have the a problem.

    I have the following environment set-up:
    1) Two database servers (DB2) on two different machines.
    2) Both publisher and subscriber runs on a single machine each one connected to a different DB server.
    I'm using JDBC type 2 for both subscriber and publisher.
    Table is registered with full name (schema.table) and is the same in both database instances, the connection is done with different database user though for each server.

    snapshot replications works okay (only from the second try, first one fails due to some internal error).
    Pull replications fails constantly due to SQL error:

    com.daffodilwoods.replication.RepException:
        Problem in pull replication data due to -- 'Problem in synchronizing data for Subscription 'Sub01' due to -- 'COM.ibm.db2.jdbc.app.DB2ResultSet.getStatement()Ljava/sql/Statement;'.'.

    Can you please advise what could be wrong?

     
    • subesingh
      subesingh
      2005-07-26

      Hi,

      Please post the Exception from ERROR.lg file which is created in user_home/Replication/Log directory. It help us to trace out the problem.

      Run the Daffodil Replicator in debug mode. For more information on debugging please refer the Daffodil Replicator console guide.

      Sube Singh

       
    • acct4sf
      acct4sf
      2005-07-26

      Hi Sube,

      Thanks for the prompt reply.

      Here is the log (below).

      Chen

      2005-07-26 11:01:30.814

          Problem in synchronizing data for Subscription 'Sub01' due to -- 'COM.ibm.db2.jdbc.app.DB2ResultSet.getStatement()Ljava/sql/Statement;'.

      com.daffodilwoods.replication.Publication.createXMLForClient(Publication.java:726)sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)java.lang.reflect.Method.invoke(Method.java:585)sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:294)sun.rmi.transport.Transport$1.run(Transport.java:153)java.security.AccessController.doPrivileged(Native Method)sun.rmi.transport.Transport.serviceCall(Transport.java:149)sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:701)java.lang.Thread.run(Thread.java:595)sun.rmi.transport.StreamRemoteCall.exceptionReceivedFromServer(StreamRemoteCall.java:247)sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java:223)sun.rmi.server.UnicastRef.invoke(UnicastRef.java:126)com.daffodilwoods.replication.Publication_Stub.createXMLForClient(Unknown Source)com.daffodilwoods.replication.Subscription.pull(Subscription.java:926)poc.replicator.ReplicatorSubscriberPullTest.testSubscriberPull(ReplicatorSubscriberPullTest.java:159)sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)java.lang.reflect.Method.invoke(Method.java:585)junit.framework.TestCase.runTest(TestCase.java:154)junit.framework.TestCase.runBare(TestCase.java:127)junit.framework.TestResult$1.protect(TestResult.java:106)junit.framework.TestResult.runProtected(TestResult.java:124)junit.framework.TestResult.run(TestResult.java:109)junit.framework.TestCase.run(TestCase.java:118)junit.framework.TestSuite.runTest(TestSuite.java:208)junit.framework.TestSuite.run(TestSuite.java:203)junit.framework.TestSuite.runTest(TestSuite.java:208)junit.framework.TestSuite.run(TestSuite.java:203)junit.textui.TestRunner.doRun(TestRunner.java:116)junit.textui.TestRunner.doRun(TestRunner.java:109)poc.replicator.Main.main(Main.java:24)

      2005-07-26 11:01:30.834

          Problem in pull replication data due to -- 'Problem in synchronizing data for Subscription 'Sub01' due to -- 'COM.ibm.db2.jdbc.app.DB2ResultSet.getStatement()Ljava/sql/Statement;'.'.

      com.daffodilwoods.replication.Publication.createXMLForClient(Publication.java:726)sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)java.lang.reflect.Method.invoke(Method.java:585)sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:294)sun.rmi.transport.Transport$1.run(Transport.java:153)java.security.AccessController.doPrivileged(Native Method)sun.rmi.transport.Transport.serviceCall(Transport.java:149)sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:701)java.lang.Thread.run(Thread.java:595)sun.rmi.transport.StreamRemoteCall.exceptionReceivedFromServer(StreamRemoteCall.java:247)sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java:223)sun.rmi.server.UnicastRef.invoke(UnicastRef.java:126)com.daffodilwoods.replication.Publication_Stub.createXMLForClient(Unknown Source)com.daffodilwoods.replication.Subscription.pull(Subscription.java:926)poc.replicator.ReplicatorSubscriberPullTest.testSubscriberPull(ReplicatorSubscriberPullTest.java:159)sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)java.lang.reflect.Method.invoke(Method.java:585)junit.framework.TestCase.runTest(TestCase.java:154)junit.framework.TestCase.runBare(TestCase.java:127)junit.framework.TestResult$1.protect(TestResult.java:106)junit.framework.TestResult.runProtected(TestResult.java:124)junit.framework.TestResult.run(TestResult.java:109)junit.framework.TestCase.run(TestCase.java:118)junit.framework.TestSuite.runTest(TestSuite.java:208)junit.framework.TestSuite.run(TestSuite.java:203)junit.framework.TestSuite.runTest(TestSuite.java:208)junit.framework.TestSuite.run(TestSuite.java:203)junit.textui.TestRunner.doRun(TestRunner.java:116)junit.textui.TestRunner.doRun(TestRunner.java:109)poc.replicator.Main.main(Main.java:24)

      2005-07-26 11:01:31.585

          Problem in synchronizing data for Subscription 'Sub01' due to -- 'COM.ibm.db2.jdbc.app.DB2ResultSet.getStatement()Ljava/sql/Statement;'.

      com.daffodilwoods.replication.Publication.createXMLForClient(Publication.java:726)sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)java.lang.reflect.Method.invoke(Method.java:585)sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:294)sun.rmi.transport.Transport$1.run(Transport.java:153)java.security.AccessController.doPrivileged(Native Method)sun.rmi.transport.Transport.serviceCall(Transport.java:149)sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:701)java.lang.Thread.run(Thread.java:595)sun.rmi.transport.StreamRemoteCall.exceptionReceivedFromServer(StreamRemoteCall.java:247)sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java:223)sun.rmi.server.UnicastRef.invoke(UnicastRef.java:126)com.daffodilwoods.replication.Publication_Stub.createXMLForClient(Unknown Source)com.daffodilwoods.replication.Subscription.pull(Subscription.java:926)poc.replicator.ReplicatorSubscriberPullTest.testSubscriberPull2(ReplicatorSubscriberPullTest.java:182)sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)java.lang.reflect.Method.invoke(Method.java:585)junit.framework.TestCase.runTest(TestCase.java:154)junit.framework.TestCase.runBare(TestCase.java:127)junit.framework.TestResult$1.protect(TestResult.java:106)junit.framework.TestResult.runProtected(TestResult.java:124)junit.framework.TestResult.run(TestResult.java:109)junit.framework.TestCase.run(TestCase.java:118)junit.framework.TestSuite.runTest(TestSuite.java:208)junit.framework.TestSuite.run(TestSuite.java:203)junit.framework.TestSuite.runTest(TestSuite.java:208)junit.framework.TestSuite.run(TestSuite.java:203)junit.textui.TestRunner.doRun(TestRunner.java:116)junit.textui.TestRunner.doRun(TestRunner.java:109)poc.replicator.Main.main(Main.java:24)

      2005-07-26 11:01:31.595

          Problem in pull replication data due to -- 'Problem in synchronizing data for Subscription 'Sub01' due to -- 'COM.ibm.db2.jdbc.app.DB2ResultSet.getStatement()Ljava/sql/Statement;'.'.

      com.daffodilwoods.replication.Publication.createXMLForClient(Publication.java:726)sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)java.lang.reflect.Method.invoke(Method.java:585)sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:294)sun.rmi.transport.Transport$1.run(Transport.java:153)java.security.AccessController.doPrivileged(Native Method)sun.rmi.transport.Transport.serviceCall(Transport.java:149)sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:701)java.lang.Thread.run(Thread.java:595)sun.rmi.transport.StreamRemoteCall.exceptionReceivedFromServer(StreamRemoteCall.java:247)sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java:223)sun.rmi.server.UnicastRef.invoke(UnicastRef.java:126)com.daffodilwoods.replication.Publication_Stub.createXMLForClient(Unknown Source)com.daffodilwoods.replication.Subscription.pull(Subscription.java:926)poc.replicator.ReplicatorSubscriberPullTest.testSubscriberPull2(ReplicatorSubscriberPullTest.java:182)sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)java.lang.reflect.Method.invoke(Method.java:585)junit.framework.TestCase.runTest(TestCase.java:154)junit.framework.TestCase.runBare(TestCase.java:127)junit.framework.TestResult$1.protect(TestResult.java:106)junit.framework.TestResult.runProtected(TestResult.java:124)junit.framework.TestResult.run(TestResult.java:109)junit.framework.TestCase.run(TestCase.java:118)junit.framework.TestSuite.runTest(TestSuite.java:208)junit.framework.TestSuite.run(TestSuite.java:203)junit.framework.TestSuite.runTest(TestSuite.java:208)junit.framework.TestSuite.run(TestSuite.java:203)junit.textui.TestRunner.doRun(TestRunner.java:116)junit.textui.TestRunner.doRun(TestRunner.java:109)poc.replicator.Main.main(Main.java:24)

       
    • subesingh
      subesingh
      2005-07-27

      Hi,

      We are looking into the problem. But we have tested Daffodil Replicator using  "DB2 Universal JDBC Driver " . So please try it.

      JDBC differences between the DB2 Universal JDBC Driver and other DB2 JDBC drivers

      The DB2 Universal JDBC Driver differs from the DB2 JDBC Type 2 Driver for Linux, UNIX and Windows (DB2 JDBC Type 2 Driver) in the following areas:

      Supported methods

      The DB2 Universal JDBC Driver supports a number of JDBC methods that the other drivers do not support, and does not support several methods that the other drivers support. For details, see Comparison of driver support for JDBC APIs.

      Support for scrollable and updatable ResultSets
      The DB2 Universal JDBC Driver supports scrollable and updatable ResultSets.

      The DB2 JDBC Type 2 Driver supports scrollable ResultSets but not updatable ResultSets.

      For more detail visit to the following web link:

      http://publib.boulder.ibm.com/infocenter/db2help/index.jsp?topic=/com.ibm.db2.udb.doc/ad/rjvjcdif.htm

      Sube Singh

       
    • acct4sf
      acct4sf
      2005-07-27

      Thank You.