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

Ignore local nodes in read repair filtering #1613

Merged
merged 1 commit into from Sep 19, 2018

Conversation

Projects
None yet
2 participants
@nickva
Contributor

nickva commented Sep 19, 2018

Previosly local node revisions were causing badmatch failures in read repair
filter. Node sequences already filtered out local nodes while NodeRevs didn't, so
during matching {Node, NodeSeq} = lists:keyfind(Node, 1, NodeSeqs) Node would
not be found in the list and crash.

Example of crash:

fabric_rpc:update_docs/3 error:{badmatch,false}
 [{fabric_rpc,'-read_repair_filter/3-fun-1-',4,[{file,"src/fabric_rpc.erl"},{line,360}]},

Checklist

  • Code is written and works correctly;
  • Changes are covered by tests;
Ignore local nodes in read repair filtering
Previosly local node revisions were causing `badmatch` failures in read repair
filter. Node sequences already filtered out local nodes while NodeRevs didn't, so
during matching `{Node, NodeSeq} = lists:keyfind(Node, 1, NodeSeqs)` Node would
not be found in the list and crash.

Example of crash:

```
fabric_rpc:update_docs/3 error:{badmatch,false}
 [{fabric_rpc,'-read_repair_filter/3-fun-1-',4,[{file,"src/fabric_rpc.erl"},{line,360}]},
```
@davisp

davisp approved these changes Sep 19, 2018

+1

@nickva nickva merged commit 52ed7fb into apache:master Sep 19, 2018

1 check passed

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

@nickva nickva deleted the cloudant:open_revs_read_repair_fix branch Sep 19, 2018

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