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

check if datatype or sc, skip del operation in put path #457

Merged
merged 1 commit into from
Feb 23, 2015

Conversation

zeeshanlakhani
Copy link
Contributor

Fixes https://bashoeng.atlassian.net/browse/RIAK-1504 (#452).

Initial comments/PR #452.

Improves performance by avoiding an extra delete operation to remove siblings through Solr on the put path when riak datatypes or strong consistency is used. Initial patch/issue was discovered by @drewkerrigan, https://github.com/basho-labs/yokozuna_perf_patch.

@zeeshanlakhani
Copy link
Contributor Author

@seancribbs benchmarks:

local runs

The consolidated fix seems to work well.

Yokozuna Develop - Sets

Mean ops/s for put-check/before-load-fruit: 574.530657
Mean ops/s for put-check/current: 574.530657

The mean median latency for put-check/before-load-fruit/load-fruit-pb_latencies.csv: 51.932547
The mean median latency for put-check/current/load-fruit-pb_latencies.csv: 51.932547

The mean 95th latency for put-check/before-load-fruit/load-fruit-pb_latencies.csv: 103.327948
The mean 95th latency for put-check/current/load-fruit-pb_latencies.csv: 103.327948

Yokozuna Perf Put Path CRDTS w/ Fix - Sets

Mean ops/s for put-check/before-load-fruit: 682.978673
Mean ops/s for put-check/current: 682.978673

The mean median latency for put-check/before-load-fruit/load-fruit-pb_latencies.csv: 44.457306
The mean median latency for put-check/current/load-fruit-pb_latencies.csv: 44.457306

The mean 95th latency for put-check/before-load-fruit/load-fruit-pb_latencies.csv: 81.066028
The mean 95th latency for put-check/current/load-fruit-pb_latencies.csv: 81.066028

Yokozuna - Develop - Maps

Mean ops/s for put-check/before-load-fruit: 647.997282
Mean ops/s for put-check/current: 647.997282

The mean median latency for put-check/before-load-fruit/load-fruit-pb_latencies.csv: 45.288336
The mean median latency for put-check/current/load-fruit-pb_latencies.csv: 45.288336

The mean 95th latency for put-check/before-load-fruit/load-fruit-pb_latencies.csv: 93.365178
The mean 95th latency for put-check/current/load-fruit-pb_latencies.csv: 93.365178

Yokozuna Perf Put Path CRDTS w/ Fix - Maps

Mean ops/s for put-check/before-load-fruit: 696.033863
Mean ops/s for put-check/current: 696.033863

The mean median latency for put-check/before-load-fruit/load-fruit-pb_latencies.csv: 43.415865
The mean median latency for put-check/current/load-fruit-pb_latencies.csv: 43.415865

The mean 95th latency for put-check/before-load-fruit/load-fruit-pb_latencies.csv: 80.376965
The mean 95th latency for put-check/current/load-fruit-pb_latencies.csv: 80.376965

Here's Drew's work that he did initially on some powerful machines and just removing the delete operation altogether:

Drew’s BB work - PrePatch

Mean ops/s for 20150121_214413: 2654.752636

The mean median latency for 20150121_214413/post-map-targets-json5-v-json-h_latencies.csv: 39.811105

The mean 95th latency for 20150121_214413/post-map-targets-json5-v-json-h_latencies.csv: 142.582000

Drew’s BB work - PostPatch (Full removal of Delete Op to Solr)

Mean ops/s for 20150121_221042: 6322.768601

The mean median latency for 20150121_221042/post-map-targets-json5-v-json-h_latencies.csv: 39.639982

The mean 95th latency for 20150121_221042/post-map-targets-json5-v-json-h_latencies.csv: 76.038368

@seancribbs
Copy link

What is meant by "mean 95th"? Is that actually the average of the 95th percentile? (Same goes for median.) Are there basho_bench graphs?

Bucket = riak_object:bucket(Obj),
case riak_core_bucket:get_bucket(Bucket) of
BProps when is_list(BProps) ->
case is_datatype(BProps) of

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This whole case expression can be simplifed to:

is_datatype(BProps) orelse lists:member({consistent, true}, BProps)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

derp on me... totally right.

@zeeshanlakhani
Copy link
Contributor Author

@seancribbs was using the scripts that Ryan had been using in https://github.com/basho/yokozuna/tree/develop/misc/bench/bin (and documented in https://github.com/basho/yokozuna/blob/develop/docs/BENCHMARKING.md). And, yes, mean 95th is the avg of all 95th percentiles and median is the average of all the medians.

If you want I could showcase some graphs, but I thought to use what we had been doing previously.

@zeeshanlakhani zeeshanlakhani force-pushed the perf/zl/update-delete-op-to-solr-if-crdt-sc branch from 58dce67 to 1580c38 Compare February 22, 2015 04:37
@zeeshanlakhani zeeshanlakhani force-pushed the perf/zl/update-delete-op-to-solr-if-crdt-sc branch from 1580c38 to 263c265 Compare February 22, 2015 19:56
@zeeshanlakhani
Copy link
Contributor Author

@seancribbs new/different runs (same config), but showcasing the graphs.

develop

yz-develop-maps

w/ perf update

yz-perf-put-crdts-maps

@seancribbs
Copy link

👍 263c265

I'm convinced this is a significant-enough change. Good work!

borshop added a commit that referenced this pull request Feb 23, 2015
…f-crdt-sc

check if datatype or sc, skip del operation in put path

Reviewed-by: seancribbs
@zeeshanlakhani
Copy link
Contributor Author

@borshop merge

@borshop borshop merged commit 263c265 into develop Feb 23, 2015
@zeeshanlakhani zeeshanlakhani deleted the perf/zl/update-delete-op-to-solr-if-crdt-sc branch March 2, 2015 18:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants