gravitee-io / issues

Gravitee.io - API Platform - Issues
64 stars 26 forks source link

[Task] Improve MongoDB indexes #9194

Closed Okhelifi closed 1 year ago

Okhelifi commented 1 year ago

📝 Description

Mongo Atlas Performance Advisor raised warnings about:

Missing indexes:

On 3.19/3.20/4.0

node_monitoring: { type: 1, updatedAt: 1 }

events: { "properties.dictionary_id":1, "updatedAt" : -1}

On 4.0 only

apis: { "environmentId": 1, "name": 1, "definitionVersion": 1 }

subscriptions: { "updatedAt": 1 }

Redundant indexes.

On 3.19/3.20/4.0

events

{ "type" : 1 }

{ "properties.api_id" : 1 }

FYI, an index that is a prefix of another compound index is redundant and can be removed to improve write performance. Since these indexes are prefixes of another compound index, removing them will not affect your read performance.

🔎 Technical Details

No response

👽 Additional Information

No response

Okhelifi commented 1 year ago

Duplicate of #9162