db: respect changed filters in SetOptions#1631
Conversation
Rebuild the iterator stack if filters (block or table) are modified. Fix cockroachdb#1621.
nicktrav
left a comment
There was a problem hiding this comment.
Reviewed 3 of 4 files at r1, 1 of 1 files at r2, 1 of 1 files at r3, all commit messages.
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @jbowens)
iterator.go, line 1751 at r2 (raw file):
compare the filter closures.
Function pointer comparison as a high level check? It's a little gross though.
jbowens
left a comment
There was a problem hiding this comment.
TFTR!
Reviewable status: all files reviewed, 1 unresolved discussion (waiting on @erikgrinaker and @nicktrav)
iterator.go, line 1751 at r2 (raw file):
Previously, nicktrav (Nick Travers) wrote…
compare the filter closures.
Function pointer comparison as a high level check? It's a little gross though.
I'm hoping we can remove the TableFilter altogether soon, replacing it exclusively with block property filters. They're subject to a similar problem, but I suppose we could add an equal method to the interface.
Rebuild the iterator stack if filters (block or table) are modified.
Fix #1621.