loopbackio / loopback-connector-elastic-search

Strongloop Loopback connector for Elasticsearch
MIT License
78 stars 57 forks source link

esv6 automatically create index if not exists #110

Closed prateekrastogi closed 6 years ago

prateekrastogi commented 6 years ago

Hi, @bharathkontham I was using esv6 connector, and while creating and deleting indexes frequently in dev environment, I found that we need to create index manually if it doesn't exists yet. In the older version of connector, this issue has already been fixed. It would be nice to be to support such functionality in esv6 version too for avoiding un-necessary manual hack. Thanks.

bharathkontham commented 6 years ago

Use version 1.0.2 https://www.npmjs.com/package/loopback-connector-esv6

pulkitsinghal commented 6 years ago

way to go @bharathkontham

prateekrastogi commented 6 years ago

@bharathkontham Thanks a lot. Just a minor remark that model's 'replaceOrCreate' is not working as per as the specs of PersistedModel api. Although, I managed to workaround using 'upsert' method.