New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove unused rank indexes in place layer #1520
Remove unused rank indexes in place layer #1520
Conversation
Results evaluating commit 8e9f11f (merged with base f3dbb0a as 2bbf98e). See run details. PostgreSQL DB size in MB: 4926 ⇒ 4926 (0.0% change)
expand for details...
|
I think these indexes are used within |
How can we test that? They come up unused in the integrity script. |
My understanding of the update scripts are that they primarily use id fields in doing updates. |
Also - conceptually - an index only on the rank column is pretty pointless - we're not pulling out data by queries on rank, we're pulling them out by geometry or updating by ID. |
Reviewing the code, I'm confident that these rank indexes aren't solving a useful purpose. All of the queries that use rank are filtering by geometry, which would be the index used. |
Sorry was not available the past few days. Yeah after looking at the query in more detail you are correct the index will never be since the primary-key (id) will take precedence. Am currently also running a test-import and updates (#1516) so maybe we could still wait until i post results from |
Thanks, additional data would be great to ensure that I'm not missing anything. |
Have posted my results of the import and update run of a small region in the mentioned issue and you were correct these indexes have not been accessed during the update. |
Thanks a lot! |
Based on analysis from planet builds for this layer as well as running updates via the integrity script as discussed in #1516, these three indexes are not used and can be removed.