C++FLAGS = -g -D_GNU_SOURCE ; COMMON = $(DOTDOT)$(SLASH)common ; DEFINES += OS_$(OS) OS_$(OS)$(OSVER) OS_$(OS)$(OSPLAT) OS_$(OS)$(OSVER)$(OSPLAT) ; LINK = c++ ; OPTIM = ; OSINFO = $(OS)$(OSVER:E)$(OSPLAT:E) ; LIBS = $(DOTDOT)$(SLASH)$(DOTDOT)$(SLASH)lib.$(OSINFO:L) ; LOCATE_TARGET = $(DOTDOT)$(SLASH)$(DOTDOT)$(SLASH)bin.$(OSINFO:L) ; P4API = $(DOTDOT)$(SLASH)p4api$(SLASH)$(OSINFO:L) ; HDRS = $(COMMON) $(P4API)$(SLASH)include$(SLASH)p4 ; P4LIBS = $(P4API)$(SLASH)lib ; switch $(OSINFO) { case LINUX26X86 : C++FLAGS += -m32 ; LINKFLAGS += -m32 ; case LINUX26X86_64 : C++FLAGS += -m64 ; LINKFLAGS += -m64 ; case SOLARIS8SPARC : C++ = gcc ; LINK = gcc ; LINKLIBS = -lrt /usr/local/lib/libstdc++.a ; case SOLARIS10X86_64 : C++ = gcc ; C++FLAGS += -m64 ; LINK = gcc ; LINKFLAGS += -m64 ; LINKLIBS = -lrt -lstdc++ ; } Main p4jrep : p4jrep.cc journal.cc msgjrep.cc position.cc usage.cc ; LinkLibraries p4jrep : $(LIBS)/common.a $(P4LIBS)/libclient.a $(P4LIBS)/librpc.a $(P4LIBS)/libsupp.a ;
# | Change | User | Description | Committed | |
---|---|---|---|---|---|
#9 | 7887 | Michael Shields | p4jrep Version 0.92 (beta) binaries for 2010.2. | ||
#8 | 6473 | Michael Shields | Ported to SOLARIS10X86_64. | ||
#7 | 6167 | Michael Shields | Added -m64 for linux26x86_64 compiles and link. | ||
#6 | 6157 | Michael Shields |
There's probably no need for building p4jrep for Solaris 2.6 any longer. (Email me if you need it.) |
||
#5 | 6155 | Michael Shields |
Updated for the 2007.3 release while maintaining compatibility with prior releases. 2007.3 and later servers might rotate the journal by renaming it rather than copying and truncating it. A renamed journal is now detected by comparing the device and inode returned from statting by the journal's file name and statting by the journal's file descriptor. This algorithm (suggested by J.T. Goldstone; thanks J.T.!) is faster than reopening the journal and seeking if the journal was not rotated (~2.0 seconds vs. ~2.7 seconds for 1,000,000 iterations on my laptop). |
||
#4 | 5288 | Michael Shields | Updated to use the 2005.2 API. | ||
#3 | 5123 | Michael Shields |
p4jrep Version 0.88 (beta) for solaris8sparc (sunultra) and linux24x86 (suse). |
||
#2 | 5119 | Michael Shields |
Added -t delay in an attempt to ensure transactional atomicity. If no additional journal entries are written during this delay, the transaction is assumed complete, which closes the pipe, which terminates the command (which if includes a p4d -jr, releases the locks in the target server, allowing commands access to the replicated atomic transaction). By default, this delay is ten milliseconds. Locking the journal does not ensure transactional atomicity since the server locks the journal once for each journal entry written, not once per transaction. And we would like to avoid locking the journal since that would introduce a potential concurrency problem. Not all operations in the server are atomic transactions and therefore cannot be replicated atomically. For example, updating a client's have list as files are being synced is not an atomic transaction. But committing a submit is an atomic transaction, and this change (with perhaps some site-specific tuning of the -t delay) attempts to replicate the commit atomically. |
||
#1 | 4839 | Michael Shields | Pushing p4jrep source into the public depot. |