git: dmsg - refactor cluster and pfs identifiers

Matthew Dillon dillon at crater.dragonflybsd.org
Thu Mar 26 20:17:36 PDT 2015


commit 7750fd726d0264283608ff21d8a003fb8d7da03b
Author: Matthew Dillon <dillon at apollo.backplane.com>
Date:   Thu Mar 26 20:05:51 2015 -0700

    dmsg - refactor cluster and pfs identifiers
    
    Cleanup loose ends in the CONN/SPAN messages that prior work has exposed.
    DMSG now uses LNK_SPAN exclusively in its graph algorithms, so LNK_CONN
    has a different meaning than it used to.
    
    * Change the way cl_id and fs_id work.  Rename cl_id and most cluster fields
      as 'peer' identification fields.
    
      Reduce complexity and confusion by removing pfs_type and pfs_fsid from
      LNK_CONN.  Also remove pfs_mask and fs_label.  Change cl_label to
      peer_label.  peer_label is now always a human-readonable string identifier
      for the socket connection and no longer performs any connection filtering.
      This allows it to be passed in LNK_SPANs to make the trees more
      human-readable when dumped.
    
    * A LNK_CONN identifies the peer and not necessarily any particular cluster.
      Note that the peer_id in a LNK_CONN is a filter request, not an
      advertisement.
    
    * Make peer_label more meaningful by incorporating the hostname (needs more
      work).
    
    * Rename filesystem identifiers as 'pfs' identifiers.  A LNK_SPAN identifies
      a particular PFS.  Note that the peer_id in a LNK_SPAN is part of the PFS
      { cluster_id, pfs_id } advertisement.
    
    * Pad some in-memory structures for natural alignment (it's a general rule
      for all hammer2 structures, even in-memory structures when appropriate).

Summary of changes:
 lib/libdmsg/dmsg.h                |   2 +-
 lib/libdmsg/msg_lnk.c             | 140 +++++++++++++++++---------------------
 lib/libdmsg/service.c             |   4 +-
 lib/libdmsg/subs.c                |   6 +-
 sbin/hammer2/cmd_pfs.c            |   4 +-
 sbin/hammer2/main.c               |   2 +-
 sbin/hammer2/subs.c               |   2 +-
 sys/dev/disk/xdisk/xdisk.c        |  61 +++++++++--------
 sys/kern/subr_diskiocom.c         |  41 +++++++----
 sys/sys/dmsg.h                    |  61 ++++++++---------
 sys/vfs/hammer2/hammer2.h         |  33 +++++++++
 sys/vfs/hammer2/hammer2_cluster.c |  61 ++++++++++++++++-
 sys/vfs/hammer2/hammer2_disk.h    |  36 +++++++---
 sys/vfs/hammer2/hammer2_iocom.c   |  62 ++++++++---------
 14 files changed, 308 insertions(+), 207 deletions(-)

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/7750fd726d0264283608ff21d8a003fb8d7da03b


-- 
DragonFly BSD source repository



More information about the Commits mailing list