Navigation Menu

Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

kvs: support ability to "revert" / "back out" merged commits #1346

Merged
merged 8 commits into from Mar 7, 2018

Commits on Mar 7, 2018

  1. modules/kvs: Update kvstxn comments

    Fix forgotten change to function name.
    chu11 committed Mar 7, 2018
    Copy the full SHA
    ba7c249 View commit details
    Browse the repository at this point in the history
  2. modules/kvs: Merge to new empty kvstxn_t

    In kvstxn_mgr_merge_ready_transactions(), instead of merging
    transactions into the current head ready transaction, create a
    new empty transaction and merge contents into it.  Then push
    that new transaction onto the head of the ready list.
    
    Requires users to call kvstxn_mgr_get_ready_commit() after the
    merge to get the new head.
    chu11 committed Mar 7, 2018
    Copy the full SHA
    1166c4c View commit details
    Browse the repository at this point in the history
  3. modules/kvs: Refactor internal kvstxn_merge()

    With recent changes, kvstxn_merge() no longer needs to be fully cleaned
    up on error.  An error code can be returned to the caller
    kvstxn_mgr_merge_ready_commits(), which will handle full cleanup.
    chu11 committed Mar 7, 2018
    Copy the full SHA
    c2d030d View commit details
    Browse the repository at this point in the history
  4. modules/kvs: Check flags on kvstxn merge

    When merging transactions, also ensure flags are identical.
    chu11 committed Mar 7, 2018
    Copy the full SHA
    3f0b313 View commit details
    Browse the repository at this point in the history
  5. modules/kvs: don't modify ready queue on error

    Alter logic in kvstxn_mgr_merge_ready_transactions(), so that
    on error, no modifications to the kvstxn ready queue occur.
    chu11 committed Mar 7, 2018
    Copy the full SHA
    9dd5fb7 View commit details
    Browse the repository at this point in the history
  6. modules/kvs: Add check in internal kvstxn API

    Add internal checks that ensures only kvstxn's that are
    ready for processing are passed to processing functions.
    
    Add unit tests appropriately.
    chu11 committed Mar 7, 2018
    Copy the full SHA
    79c176a View commit details
    Browse the repository at this point in the history
  7. modules/kvs: Preserve orig kvstxns during merge

    Do not destroy transactions after they have been merged.  Instead
    flag them as components of a larger merge.  When the kvstxn
    of a set of merged transactions completes/is removed, at that point
    in time remove all of the components of the larger merge.
    
    As a consequence of this change and for optimization purposes, once
    a merger of transactions has occured, there can no longer be any more
    mergers until the head merged transaction has completed.  If this were
    not done, the ready queue would constantly be iterted through and
    new head merged transactions would be created.  This can be optimized
    at a later time.
    
    Add unit tests.
    chu11 committed Mar 7, 2018
    Copy the full SHA
    06c7390 View commit details
    Browse the repository at this point in the history
  8. modules/kvs: try orig transactions on kvstxn error

    In kvstxn_mgr_remove_transaction() support flag for user to fallback
    a merged kvstxn to the original transactions that made up the merge.
    
    By doing so, the user need not send an error to all transactions merged
    into that kvstxn.  Instead, each of the original transactions
    can be replayed individually, and an error will only be sent to
    the offending commit/fence transaction.
    
    Support kvstxn_fallback_mergeable() so user knows if a kvstxn can
    be falled back on.
    
    In kvstxn_apply(), take advantage of this by not sending an error
    when a kvstxn's merging can be falled back on.  As an exception,
    do not fallback if it's a "death"-like error (e.g. ENOMEM).
    
    Add internal kvstxn API unit tests.
    
    Fixes flux-framework#1337
    chu11 committed Mar 7, 2018
    Copy the full SHA
    96b46c0 View commit details
    Browse the repository at this point in the history