Jan Wieck wieck at lists.slony.info
Tue Jun 19 12:14:51 PDT 2007
Update of /home/cvsd/slony1/slony1-engine/src/slon
In directory main.slony.info:/tmp/cvs-serv24212/src/slon

Modified Files:
	remote_worker.c 
Log Message:
Let SYNC use the internally tracked ssy_seqno also for archive
logging.

Jan


Index: remote_worker.c
===================================================================
RCS file: /home/cvsd/slony1/slony1-engine/src/slon/remote_worker.c,v
retrieving revision 1.144
retrieving revision 1.145
diff -C2 -d -r1.144 -r1.145
*** remote_worker.c	14 Jun 2007 15:17:55 -0000	1.144
--- remote_worker.c	19 Jun 2007 19:14:49 -0000	1.145
***************
*** 3969,3980 ****
  			if (archive_dir)
  			{
  				slon_log(SLON_DEBUG2, "writing archive log...\n");
  				fflush(stderr);
  				fflush(stdout);
  				rc = archive_tracking(node, rtcfg_namespace, sub_set,
! 										 PQgetvalue(res1, tupno1, 1), seqbuf,
  										 event->ev_timestamp_c);
  				if (rc < 0)
  					slon_retry();
  			}
  		}
--- 3969,3992 ----
  			if (archive_dir)
  			{
+ 				for (pset = provider->set_head; pset; pset = pset->next)
+ 					if (pset->set_id == sub_set) break;
+ 				if (pset == NULL)
+ 				{
+ 					slon_log(SLON_ERROR, "remoteWorkerThread_%d: "
+ 							"set %d not found in runtime config\n",
+ 							node->no_id, sub_set);
+ 					slon_retry();
+ 				}
+ 
  				slon_log(SLON_DEBUG2, "writing archive log...\n");
  				fflush(stderr);
  				fflush(stdout);
  				rc = archive_tracking(node, rtcfg_namespace, sub_set,
! 										 pset->ssy_seqno, seqbuf,
  										 event->ev_timestamp_c);
  				if (rc < 0)
  					slon_retry();
+ 
+ 				strcpy(pset->ssy_seqno, seqbuf);
  			}
  		}



More information about the Slony1-commit mailing list