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: add flux_kvs_copy(), flux_kvs_move() #1828

Merged
merged 7 commits into from Nov 12, 2018

Conversation

Projects
None yet
3 participants
@garlick
Copy link
Member

garlick commented Nov 10, 2018

This PR adds the flux_kvs_copy() and flux_kvs_move() composite operations that were discussed in #1747.

@codecov-io

This comment has been minimized.

Copy link

codecov-io commented Nov 10, 2018

Codecov Report

Merging #1828 into master will decrease coverage by <.01%.
The diff coverage is 74.35%.

@@            Coverage Diff             @@
##           master    #1828      +/-   ##
==========================================
- Coverage   79.74%   79.73%   -0.01%     
==========================================
  Files         196      197       +1     
  Lines       35223    35277      +54     
==========================================
+ Hits        28088    28128      +40     
- Misses       7135     7149      +14
Impacted Files Coverage Δ
src/cmd/flux-kvs.c 82.88% <100%> (+0.98%) ⬆️
src/common/libkvs/kvs_copy.c 72.22% <72.22%> (ø)
src/broker/modservice.c 79.8% <0%> (-0.97%) ⬇️
src/common/libflux/handle.c 83.99% <0%> (-0.7%) ⬇️
src/modules/kvs/kvs.c 65.41% <0%> (-0.16%) ⬇️
src/common/libflux/message.c 81.51% <0%> (ø) ⬆️

garlick added some commits Nov 4, 2018

libkvs/kvs_copy: add copy, move functions
Add flux_kvs_copy() and flux_kvs_move() based on composite
futures.

flux_kvs_copy() performs:
1) a lookup of the directory entry for the source key
2) a put, commit that sets the destination key to
a copy of the dirent.

kvs_move() performs:
1) a flux_kvs_copy()
2) an unlink, commit on the source key

Fixes #1747

@garlick garlick force-pushed the garlick:kvs_copy branch 3 times, most recently from 1f497bc to e283f70 Nov 10, 2018

@garlick garlick force-pushed the garlick:kvs_copy branch 3 times, most recently from c86d7aa to 171adba Nov 11, 2018

@chu11
Copy link
Contributor

chu11 left a comment

LGTM! Just one nit I list below

Show resolved Hide resolved t/t1009-kvs-copy.t Outdated

garlick added some commits Nov 10, 2018

cmd/flux-version: show libflux-security version
If flux-core is compiled --with-flux-security, include
the output of flux_security_version_string() in the
flux-version output.
testsuite: add kvs-copy/move sharness test
Break off (two) kvs-copy/move sharness tests to
a new script, t1009-kvs-copy.t, and improve
test coverage for copying between namespaces,
and copying directories versus values.
build: check for flux/security/version.h
version.h was added to flux-security recently.
Set HAVE_FLUX_SECURITY_VERSION_H if detected at
build time so that installed versions of flux-security
don't have to be immediately updated.

This can be replaced wtih a pkg-config minimum version
check after the next release.

@garlick garlick force-pushed the garlick:kvs_copy branch from 171adba to 30cce87 Nov 12, 2018

@chu11

This comment has been minimized.

Copy link
Contributor

chu11 commented Nov 12, 2018

LGTM!

@chu11 chu11 merged commit 81411fb into flux-framework:master Nov 12, 2018

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
@garlick

This comment has been minimized.

Copy link
Member Author

garlick commented Nov 12, 2018

Thanks!

@garlick garlick deleted the garlick:kvs_copy branch Nov 12, 2018

chu11 added a commit to chu11/flux-core that referenced this pull request Dec 14, 2018

modules/kvs-watch: Support WAITCREATE w/o WATCH
Support the ability to specify WAITCREATE w/o WATCH.  This option
will effectively allow users to do a lookup and wait until a key
has been created.

Fixes flux-framework#1828

chu11 added a commit to chu11/flux-core that referenced this pull request Dec 14, 2018

modules/kvs-watch: Support WAITCREATE w/o WATCH
Support the ability to specify WAITCREATE w/o WATCH.  This option
will effectively allow users to do a lookup and wait until a key
has been created.

Fixes flux-framework#1828
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.