Ensure series keys are sorted before searching
Ensure series keys are sorted before searching

The Cache.ApplyEntryFn iterates keys according to the partitions
and hashed values.  This can cause the deleteKeys slice to contain
unsorted keys when deleting series.  The code uses a binary search
on this slice later on and this can fail to detect that the series
should still exists.  The series is then removed from the index
even though it has data still.

Fixes #9116

influxdata/influxdb,linearb/influxdb,benbjohnson/influxdb,benbjohnson/influxdb,mark-rushakoff/influxdb,li-ang/influxdb,mark-rushakoff/influxdb,linearb/influxdb,li-ang/influxdb,influxdb/influxdb,mark-rushakoff/influxdb,linearb/influxdb,nooproblem/influxdb,influxdb/influxdb,nooproblem/influxdb,influxdb/influxdb,benbjohnson/influxdb,influxdata/influxdb,nooproblem/influxdb,mark-rushakoff/influxdb,influxdb/influxdb,benbjohnson/influxdb,linearb/influxdb,nooproblem/influxdb,mark-rushakoff/influxdb,influxdb/influxdb,nooproblem/influxdb,linearb/influxdb,influxdb/influxdb,mark-rushakoff/influxdb