rnewson commented on code in PR #5132:
URL: https://github.com/apache/couchdb/pull/5132#discussion_r1679247889
##########
src/couch/src/couch_bt_engine_header.erl:
##########
@@ -269,14 +270,14 @@ upgrade_epochs(#db_header{} = Header) ->
% was always an implicit assumption that a file was
% owned since eternity by the node it was on. This
% just codifies that assumption.
- [{node(), 0}];
- [{Node, _} | _] = Epochs0 when Node == node() ->
+ [{Node, 0}];
+ [{Node, S} | _] = Epochs0 when Header#db_header.update_seq >= S ->
% Current node is the current owner of this db
Epochs0;
- Epochs1 ->
+ [{_OtherNode, S} | _] = Epochs1 when Header#db_header.update_seq
>= S ->
Review Comment:
we'd get this level of info; ```2> Foo = fun(N) -> case N of N when N < 100
-> under; N when N > 200 -> over end end.
#Fun<erl_eval.42.3316493>
3> Foo(1).
under
4> Foo(300).
over
5> Foo(101).
** exception error: no case clause matching 101```
so we'd see the value that didn't match, but not the db_header.update_seq
context.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]