Hi everyone! I'm running Typesense in a HA fashio...
# community-help
a
Hi everyone! I'm running Typesense in a HA fashion and seeing one of my 3 nodes doesn't appear to be applying filters correctly. Any suggestions on how I can debug?
This is an example of the query I'm running and the inconsistent results:
Copy code
search_parameters = {
    "q": "*",
    "query_by": "name",
    "infix": "off",
    "offset": 0,
    "limit": 31,
}
# 'found': 15, 'hits': [{'document': {'_schema': '0.0.1', 'created_at_unix_secs': 1725475012, 'id': 'lqPWmVfWmWKqVjNWKJhg', 'name': 'test3', 'user_id': 'wsU5zkU2R4SHGeiTvzO85wMACiq1', ....

search_parameters = {
    "q": "*",
    "query_by": "name",
    "infix": "off",
    "offset": 0,
    "limit": 31,
    "filter_by": "user_id:=wsU5zkU2R4SHGeiTvzO85wMACiq1",
}
# 'found': 0, 'hits': [], 'out_of': 15, 'page': 1, 'request_params': ......
Weirdly seeing other nodes are returning different results with the same query:
Copy code
When running against a good node

search_parameters = {
    "q": "*",
    "query_by": "name",
    "infix": "off",
    "offset": 0,
    "limit": 31,
    "filter_by": "user_id:=wsU5zkU2R4SHGeiTvzO85wMACiq1",
}
# 'found': 3, 'hits': [{'document': {'_schema': '0.0.1', 'created_at_unix_secs': 1725475012, 'id': 'lqPWmVfWmWKqVjNWKJhg', 'name': 'test3', 'user_id': 'wsU5zkU2R4SHGeiTvzO85wMACiq1'
Have tried restarting the bad node but sadly didn't help
the debug, metrics, stats endpoints don't seem to share anything interesting either so a bit at a loss as to what to look at next
j
Could you try replicating this in v27 of Typesense?
a
It's currently working as expected (same code) in our Dev cluster which is also running 25,2
So I presume it is specifically something about our prod cluster itself which is why I was trying to work out if there was any other way to debug/get more information an existing implementation
k
See if you there are any errors in the logs that might offer a hint for why it diverged. To recover this node, you can stop it, delete the data directory and then start it back so that it catches up.
a
Would there be a way to do this for just a single collection?
k
No that's not possible because cluster state is global
a
Gotcha, thanks
Killing the single node and wiping it's data dir seemed to do the trick, thanks so much!
👍 1