1

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.

Sudipta B
  • 51
  • 1

1 Answers1

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