I am not sure where and how I can call createIndex
or ensureIndex
to ensure I have 2dsphere
indexing on the associated mongo database upon application boot. Any pointers would be helpful.
Asked
Active
Viewed 589 times
1

Sudipta B
- 51
- 1
1 Answers
0
You need to enableGeoIndexing Set to true to enable 2d sphere indexing for model properties of type GeoPoint.
check https://loopback.io/doc/en/lb4/MongoDB-connector.html#installation additional property section.

raj23024
- 13
- 4