- Notifications
You must be signed in to change notification settings - Fork6
rs/rest-layer-es
Folders and files
| Name | Name | Last commit message | Last commit date | |
|---|---|---|---|---|
Repository files navigation
ThisREST Layer resource storage backend stores data in an ElasticSearch cluster usingolivere/elastic.
ElasticSearch v5+ is required.
import"github.com/rs/rest-layer-es"
Create an elastic client:
client,err:=elastic.NewClient()
Create a resource storage handler with a given DB/collection:
s:=es.NewHandler(client,"index","type")
Use this handler with a resource:
index.Bind("foo",foo,s,resource.DefaultConf)
You may want to create as many ElasticSearch handlers with different index and/or type. You can share the sameelastic client across all you handlers.
About
REST Layer ElasticSearch resource storage handler
Resources
Uh oh!
There was an error while loading.Please reload this page.
Stars
Watchers
Forks
Releases
No releases published
Packages0
No packages published
Contributors4
Uh oh!
There was an error while loading.Please reload this page.