Whamcloud - gitweb
LU-1331 changelog: allow changelog to extend record
authorLai Siyao <laisiyao@whamcloud.com>
Fri, 1 Jun 2012 11:46:44 +0000 (19:46 +0800)
committerAndreas Dilger <adilger@whamcloud.com>
Tue, 10 Jul 2012 04:04:23 +0000 (00:04 -0400)
commit7efcf4cd0e261389bcd1b5c222325c823845da7c
tree87ce6ea332087d1736660e9c21813991ed1aaa2b
parent4f181cce1ff0a4077f0cbdd37610c4e751484f1d
LU-1331 changelog: allow changelog to extend record

Previously rename is split into two records, this isn't natural and
makes replication hard because rename needs two records, but they
may not be consecutive.

To solve this, allow Changelog to extend record, add fields sfid/spfid
in changelog record to store source/parent fid, and pack both source
and target name into the record.

Added changelog flag CLF_RENAME_LAST: rename unlink of last hardlink
of the target.

Added macro HAVE_CHANGELOG_EXTEND_REC: liblustreapi receives all
changelog records in changelog_ext_rec format.

Signed-off-by: Lai Siyao <laisiyao@whamcloud.com>
Change-Id: I97b990687726e45e661cfb11609f80132c84825d
Reviewed-on: http://review.whamcloud.com/2577
Tested-by: Hudson
Reviewed-by: Thomas LEIBOVICI - CEA <thomas.leibovici@cea.fr>
Tested-by: Maloo <whamcloud.maloo@gmail.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
14 files changed:
lustre/include/lustre/liblustreapi.h
lustre/include/lustre/lustre_idl.h
lustre/include/lustre/lustre_user.h
lustre/mdc/mdc_request.c
lustre/mdd/mdd_device.c
lustre/mdd/mdd_dir.c
lustre/mdd/mdd_internal.h
lustre/obdclass/llog_swab.c
lustre/ptlrpc/wiretest.c
lustre/utils/lfs.c
lustre/utils/liblustreapi.c
lustre/utils/lustre_rsync.c
lustre/utils/wirecheck.c
lustre/utils/wiretest.c