os/bluestore: fix ondisk encoding for blobs #12488

Merged
merged 6 commits into from Dec 15, 2016

Projects

None yet

3 participants

@liewegas
Member

We were doing this pretty inefficiently! Fix.

varadakari and others added some commits Dec 14, 2016
@varadakari @liewegas varadakari os/bluestore/bluestore_types: fix bluestore_pextent_t encoding
Signed-off-by: Varada Kari <varada.kari@sandisk.com>
ab9b8e7
@liewegas liewegas os/bluestore/bluestore_types: single byte for blob struct_v
We forego decoding compatibility by older code by dropping
compat_v and len.  We have to keep struct_v per blob here because
decode doesn't have a feature bit argument (yet?).

Signed-off-by: Sage Weil <sage@redhat.com>
9be7c54
@liewegas liewegas include/denc: pass features through to decode() on featured objects
This allows featured objects the *option* to do something
meaningful with the features.  Generally the decoding is feature
independent, but in some cases decoding might be dependent on the
struct_v or features from a containing context and we need to
pass it through.

Signed-off-by: Sage Weil <sage@redhat.com>
2af1b02
@liewegas liewegas os/bluestore: version shard and spanning blob buffers, not each blob
Instead of versioning every blob encoding, and adding a full byte
per blob, instead version the entire shard or spanning blob
chunk, since they are always encoded together.

We overload the 'features' argument here to pass through a
struct_v.  This is slightly abusing an argument that is normally
used for feature bits, but only slightly.

Signed-off-by: Sage Weil <sage@redhat.com>
90ba4ee
@liewegas liewegas os/bluestore/bluestore_types: bluestore_blob_t: varint encode csum_da…
…ta length

Signed-off-by: Sage Weil <sage@redhat.com>
d4e4e8b
@varadakari varadakari was assigned by liewegas Dec 14, 2016
@liewegas liewegas added this to the kraken milestone Dec 14, 2016
@varadakari

Looks good to me.

@ifed01
Contributor
ifed01 commented Dec 15, 2016

+1

@varadakari @liewegas varadakari os/bluestore/bluestore_types: bluestore_onode_t: varint encoding
Changing the uint32_t encoding to varint encoding saves around 120 bytes
per onode.

Signed-off-by: Varada Kari <varada.kari@sandisk.com>
acd4473
@liewegas liewegas merged commit dd0a1b8 into ceph:master Dec 15, 2016

3 checks passed

Signed-off-by all commits in this PR are signed
Details
Unmodifed Submodules submodules for project are unmodified
Details
default Build finished.
Details
@liewegas liewegas deleted the liewegas:wip-bluestore-enc branch Dec 15, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment