Remove surplus sort of labels in Ingester
This is not a documented feature of the remote write protocol; it happens to be the way Prometheus 2 works but Prometheus 1 didn't send labels sorted.
https://github.com/cortexproject/cortex/blob/f91f757e97b29d96e0ede41c4a2aeb6687e4005f/pkg/distributor/distributor.go#L252-L253
If we decide Cortex has this requirement we should document it and remove the surplus Sort() here:
https://github.com/cortexproject/cortex/blob/f91f757e97b29d96e0ede41c4a2aeb6687e4005f/pkg/ingester/index/index.go#L143
This issue has been automatically marked as stale because it has not had any activity in the past 60 days. It will be closed in 15 days if no further activity occurs. Thank you for your contributions.
I don't think this should be closed.
Distributor now sorts labels, if they are not sorted (most of the time they are). https://github.com/cortexproject/cortex/pull/1964
This is not a documented feature of the remote write protocol; it happens to be the way Prometheus 2 works but Prometheus 1 didn't send labels sorted.
https://github.com/cortexproject/cortex/blob/f91f757e97b29d96e0ede41c4a2aeb6687e4005f/pkg/distributor/distributor.go#L252-L253
Btw, this checked didn't work before (it never set lastLabelName to anything else other than ""), which is why I started to look at it.
All sorting after distributor can be removed. Code needs to be checked for such places.
Closing this issue as chunk engine has been removed from Cortex.