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 Jansson Updates #1108

Merged
merged 26 commits into from Jul 21, 2017
Merged

KVS Jansson Updates #1108

merged 26 commits into from Jul 21, 2017

Commits on Jul 20, 2017

  1. Copy the full SHA
    7dbb496 View commit details
    Browse the repository at this point in the history
  2. Copy the full SHA
    eb5515b View commit details
    Browse the repository at this point in the history
  3. modules/kvs: Refactor build of unit tests

    Only build tests with the object files they require, instead
    of using all object files in the directory.  This will make it
    easier for testing as unit tests are updated one at a time.
    
    Eliminate unnecessary header inclusion in unit tests.
    chu11 committed Jul 20, 2017
    Copy the full SHA
    664eceb View commit details
    Browse the repository at this point in the history
  4. Copy the full SHA
    abaca23 View commit details
    Browse the repository at this point in the history
  5. Copy the full SHA
    627ee31 View commit details
    Browse the repository at this point in the history
  6. modules/kvs: Add comments & unit tests

    Add comments and unit tests to indicate json_compare() logic when
    a NULL pointer may be passed into it.
    chu11 committed Jul 20, 2017
    Copy the full SHA
    1084d85 View commit details
    Browse the repository at this point in the history
  7. Copy the full SHA
    a9bf434 View commit details
    Browse the repository at this point in the history
  8. Copy the full SHA
    ad89bc5 View commit details
    Browse the repository at this point in the history
  9. Copy the full SHA
    fc7a8fe View commit details
    Browse the repository at this point in the history
  10. Copy the full SHA
    d5ad1f1 View commit details
    Browse the repository at this point in the history
  11. modules/kvs: Convert lookup API to use jansson

    Conversion also requires elimination of use of proto.h.  Convert
    KVS_PROTO_READDIR, KVS_PROTO_READLINK, and KVS_PROTO_TREEOBJ
    to FLUX_KVS_READDIR, FLUX_KVS_READLINK, and FLUX_KVS_TREEOBJ
    respectively.
    chu11 committed Jul 20, 2017
    Copy the full SHA
    dbd93f0 View commit details
    Browse the repository at this point in the history
  12. modules/kvs: Update lookup tests for jansson

    Conversion also requires elimination of use of proto.h.  Convert
    KVS_PROTO_READDIR, KVS_PROTO_READLINK, and KVS_PROTO_TREEOBJ
    to FLUX_KVS_READDIR, FLUX_KVS_READLINK, and FLUX_KVS_TREEOBJ respectively.
    chu11 committed Jul 20, 2017
    Copy the full SHA
    457dca5 View commit details
    Browse the repository at this point in the history
  13. Copy the full SHA
    0187cb1 View commit details
    Browse the repository at this point in the history
  14. Copy the full SHA
    7c9ee78 View commit details
    Browse the repository at this point in the history
  15. modules/kvs: Add more unit tests to commit tests

    Add tests checking for deletes of invalid keys.
    Add tests for multiple fences and merged/unmerged multiple fences.
    Add test for giant directory.
    chu11 committed Jul 20, 2017
    Copy the full SHA
    1dec901 View commit details
    Browse the repository at this point in the history
  16. modules/kvs: Add json_strdump util function

    Add util function so different parts of KVS that need to call
    json_dumps() call it consistently.
    chu11 committed Jul 20, 2017
    Copy the full SHA
    fb820b1 View commit details
    Browse the repository at this point in the history
  17. modules/kvs: Convert kvs to use jansson

    Convert kvs to use jansson.  Use pack/unpack functions
    appropriately as needed to remove dependency on json-c
    functions.
    
    Conversion also requires elimination of use of proto.h.
    Convert KVS_PROTO_FIRST and KVS_PROTO_ONCE to KVS_WATCH_FIRST
    and KVS_WATCH_ONE appropriately.
    chu11 committed Jul 20, 2017
    Copy the full SHA
    59446c8 View commit details
    Browse the repository at this point in the history
  18. t/t1002-kvs-cmd.t: Fix testing corner case

    In some watch tests, the output can be in unsorted order, leading
    to a mismatch with "expected" output.  Add a small tweak to sort
    fields from the output before comparison.
    chu11 committed Jul 20, 2017
    Copy the full SHA
    c44bd6d View commit details
    Browse the repository at this point in the history
  19. common/libkvs: Remove proto.[ch]

    With modules/kvs conversion to jansson, proto.[ch] files and functions
    are no longer used anywhere in flux-core.
    
    Also remove lingering build dependency on proto.o in t/Makefile.am.
    chu11 committed Jul 20, 2017
    Copy the full SHA
    7cf13fb View commit details
    Browse the repository at this point in the history
  20. common/libkvs: Remove json_dirent.[ch]

    With modules/kvs conversion to jansson, json_dirent.[ch] files
    and functions are no longer used anywhere in flux-core.
    chu11 committed Jul 20, 2017
    Copy the full SHA
    8a70f49 View commit details
    Browse the repository at this point in the history
  21. modules/kvs: workaround cppcheck false positive

    cppcheck detects "Memory pointed to by 's1' is freed twice".
    
    This is believed to be false positive.  Set s1 to NULL after free
    to workaround it.
    chu11 committed Jul 20, 2017
    Copy the full SHA
    fd3d358 View commit details
    Browse the repository at this point in the history
  22. modules/kvs: Remove json_compare

    With jansson conversion, json_compare() is now simply a call
    to json_equal().  Remove json_compare() everywhere and replace
    with direct call to json_equal().
    chu11 committed Jul 20, 2017
    Copy the full SHA
    2c1ab07 View commit details
    Browse the repository at this point in the history
  23. modules/kvs: Re-work commit unit tests

    Create own convenience function for unit tests instead of
    using j_dirent_append().
    chu11 committed Jul 20, 2017
    Copy the full SHA
    e4bac63 View commit details
    Browse the repository at this point in the history
  24. libkvs/jansson_dirent: drop j_dirent_append()

    The flux_kvs_txn_t object now abstracts the "op array"
    passed in a commit/fence request.  Drop j_dirent_append()
    which operates on these arrays.
    
    Remove it from the jansson_dirent unit test as well.
    garlick authored and chu11 committed Jul 20, 2017
    Copy the full SHA
    287f03c View commit details
    Browse the repository at this point in the history
  25. libkvs/jansson_dirent: Remove j_dirent_match

    With jansson conversions in modules/kvs and common/libkvs,
    j_dirent_match() was no longer used except in jansson_dirent
    unit tests.
    
    Remove function globally and use json_equal() in unit tests
    instead.
    chu11 committed Jul 20, 2017
    Copy the full SHA
    f30d735 View commit details
    Browse the repository at this point in the history
  26. modules/kvs: Rename json_util functions

    With use of jansson, some of the json_util function names may
    appear to be part of the jansson library.  To differentiate the
    functions, adjust names and have all of them prefixed with "kvs_util".
    
    Rename files appropriately, use appropriate new header file, and
    use new functions where appropriate.
    chu11 committed Jul 20, 2017
    Copy the full SHA
    f146b1c View commit details
    Browse the repository at this point in the history