Project

General

Profile

« Previous | Next » 

Revision 8959

Added by Jing Tao over 9 years ago

During the replication, the remote content will be saved without alteration.

View differences:

ReplicationHandler.java
364 364
      URL u = new URL(readDocURLString);
365 365

  
366 366
      // Get docid content
367
      String newxmldoc = ReplicationService.getURLContent(u);
367
      byte[] xmlBytes = ReplicationService.getURLBytes(u);
368
      String newxmldoc = new String(xmlBytes, "UTF-8");
368 369
      // If couldn't get skip it
369 370
      if ( newxmldoc.indexOf("<error>")!= -1 && newxmldoc.indexOf("</error>")!=-1)
370 371
      {
......
444 445
      // Write the document into local host
445 446
      DocumentImplWrapper wrapper = new DocumentImplWrapper(parserBase, false, false);
446 447
      String newDocid = wrapper.writeReplication(dbConn,
447
                              newxmldoc,
448
                              newxmldoc, xmlBytes,
448 449
                              docinfoHash.get("public_access"),
449 450
                              null,  /* the dtd text */
450 451
                              actions,

Also available in: Unified diff