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

os/bluestore: put strings in mempool #12651

Merged
merged 7 commits into from Jan 15, 2017

Conversation

Projects
None yet
4 participants
@liewegas
Member

liewegas commented Dec 23, 2016

This adds string support to mempool, and then moves a few bluestore strings
into the blustore_meta_other pool. I don't think there are any remaining
strings of interest.

@liewegas

This comment has been minimized.

Show comment
Hide comment
@liewegas

liewegas Dec 23, 2016

Member

subsumes #12290

Member

liewegas commented Dec 23, 2016

subsumes #12290

@xiexingguo

This comment has been minimized.

Show comment
Hide comment
@xiexingguo

xiexingguo Dec 28, 2016

Member

Need rebase

Member

xiexingguo commented Dec 28, 2016

Need rebase

Show outdated Hide outdated src/os/kstore/KStore.cc
Show outdated Hide outdated src/os/bluestore/kv.h
@@ -56,7 +56,13 @@ class KeyValueDB {
const std::string &k, ///< [in] Key to set
const bufferlist &bl ///< [in] Value to set
) = 0;
virtual void set(
const std::string &prefix,

This comment has been minimized.

@ifed01

ifed01 Jan 9, 2017

Contributor

Perhaps it would be better to get rid of prefix+key split in the KeyValueDB::TransactionImpl interface and use single full key parameter for all functions. And force the client to create that full key from prefix+subkey via specific 'make_key' member function(s)?

@ifed01

ifed01 Jan 9, 2017

Contributor

Perhaps it would be better to get rid of prefix+key split in the KeyValueDB::TransactionImpl interface and use single full key parameter for all functions. And force the client to create that full key from prefix+subkey via specific 'make_key' member function(s)?

This comment has been minimized.

@liewegas

liewegas Jan 11, 2017

Member

Good idea. Let's do that with a separate changeset, though?

@liewegas

liewegas Jan 11, 2017

Member

Good idea. Let's do that with a separate changeset, though?

This comment has been minimized.

@ifed01

ifed01 Jan 11, 2017

Contributor

Sure.

@ifed01

ifed01 Jan 11, 2017

Contributor

Sure.

@xiexingguo

This comment has been minimized.

Show comment
Hide comment
@xiexingguo

xiexingguo Jan 11, 2017

Member

This fails the mempool UT

The following tests FAILED:
	 35 - unittest_mempool (Failed)
	116 - osd-crush.sh (Failed)
Member

xiexingguo commented Jan 11, 2017

This fails the mempool UT

The following tests FAILED:
	 35 - unittest_mempool (Failed)
	116 - osd-crush.sh (Failed)
@ifed01

This comment has been minimized.

Show comment
Hide comment
@ifed01

ifed01 Jan 11, 2017

Contributor

@liewegas - any feedback on my previous comments in this PR?

Contributor

ifed01 commented Jan 11, 2017

@liewegas - any feedback on my previous comments in this PR?

@liewegas

This comment has been minimized.

Show comment
Hide comment
@liewegas

liewegas Jan 11, 2017

Member

Hmm, unit test passes for me. :/

Member

liewegas commented Jan 11, 2017

Hmm, unit test passes for me. :/

Show outdated Hide outdated src/os/kv.h
@ifed01

ifed01 approved these changes Jan 11, 2017

LGTM except a nit in kv.,h

@liewegas liewegas added the needs-qa label Jan 11, 2017

allensamuels and others added some commits Dec 3, 2016

mempool: Add string to mempool data types.
Signed-off-by: Allen Samuels <allen.samuels@sandisk.com>
include/denc: parameterize string by allocator
Signed-off-by: Sage Weil <sage@redhat.com>
os/bluestore: use mempool string for onode_t attr map
Signed-off-by: Sage Weil <sage@redhat.com>
os/bluestore,kstore: combine kv helpers in header
Signed-off-by: Sage Weil <sage@redhat.com>
kv: add char* versions of get, set, rmkey
Signed-off-by: Sage Weil <sage@redhat.com>
os/bluestore: put Onode::key in mempool
This is a pain in the butt because std::string and
std::basic_string<...,custom allocator> are incompatible.

Signed-off-by: Sage Weil <sage@redhat.com>
os/bluestore: avoid substr
This creates an intermediate string, which is a waste.

Signed-off-by: Sage Weil <sage@redhat.com>

@liewegas liewegas merged commit 03236ed into ceph:master Jan 15, 2017

@liewegas liewegas deleted the liewegas:wip-mempool-string branch Jan 15, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment