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

cls/cmpomap: add cls module for CMPXATTR-like functionality in omap #33982

Merged
merged 7 commits into from Apr 13, 2020

Commits on Apr 13, 2020

  1. buffer: comparison operators take const bufferlist&

    Signed-off-by: Casey Bodley <cbodley@redhat.com>
    cbodley committed Apr 13, 2020
    Configuration menu
    Copy the full SHA
    9f10d87 View commit details
    Browse the repository at this point in the history
  2. buffer: add missing != operator for bufferlist

    Signed-off-by: Casey Bodley <cbodley@redhat.com>
    cbodley committed Apr 13, 2020
    Configuration menu
    Copy the full SHA
    fd76017 View commit details
    Browse the repository at this point in the history
  3. objclass: expose cls_cxx_map_get_val in header

    this was defined in osd/objclass.cc but not declared in objclass/objclass.h
    
    Signed-off-by: Casey Bodley <cbodley@redhat.com>
    cbodley committed Apr 13, 2020
    Configuration menu
    Copy the full SHA
    ad990e8 View commit details
    Browse the repository at this point in the history
  4. objclass: add cls_cxx_map_get_vals_by_keys

    add an objclass api for CEPH_OSD_OP_OMAPGETVALSBYKEYS
    
    Signed-off-by: Casey Bodley <cbodley@redhat.com>
    cbodley committed Apr 13, 2020
    Configuration menu
    Copy the full SHA
    68b02d9 View commit details
    Browse the repository at this point in the history
  5. cls/cmpomap: add cls module for CMPXATTR-like functionality in omap

    provides a cmp_vals() op similar to librados' omap_cmp(), but with full
    support for the comparison modes and operations from cmpxattr(). if any
    of the requested key/value comparisons are unsuccessful, the op fails
    with -ECANCELED
    
    cmp_vals() can be composed with other ops like set_omap_vals() to make
    make them conditional on the successful comparison of all existing values
    
    also provides cmp_set_vals() and cmp_rm_keys(), which apply a mutation
    to only the keys that compare successfully. these enable batch
    operations where, unlike cmp_vals() + set_omap_vals(), you don't want
    one failed comparison to prevent operations on unrelated keys
    
    Signed-off-by: Casey Bodley <cbodley@redhat.com>
    cbodley committed Apr 13, 2020
    Configuration menu
    Copy the full SHA
    3d5c8e9 View commit details
    Browse the repository at this point in the history
  6. test: add ceph_test_cls_cmpomap

    Signed-off-by: Casey Bodley <cbodley@redhat.com>
    cbodley committed Apr 13, 2020
    Configuration menu
    Copy the full SHA
    577f211 View commit details
    Browse the repository at this point in the history
  7. options: add cmpomap to osd_class_load_list

    Signed-off-by: Casey Bodley <cbodley@redhat.com>
    cbodley committed Apr 13, 2020
    Configuration menu
    Copy the full SHA
    e1acaef View commit details
    Browse the repository at this point in the history