What's the best way to implement an OR
condition in the query of a Tendermint websocket /subscribe
method?
https://docs.tendermint.com/master/rpc/#/Websocket/subscribe
Specifically I want to query message.sender='${address}' OR transfer.recipient='${address}'
.
The solution I have right now is to do 2 /subscribe
requests with the same jsonrpc id, but that's ugly, wasteful, and I have to filter out events that are triggered twice.
If I had AND
and NOT
then a OR b = NOT((NOT a) AND (NOT b))
, but it doesn't seem like NOT
is implemented: https://godoc.org/github.com/tendermint/tendermint/libs/pubsub/query#Operator
Thanks!