Elastic - Elasticsearch Client for Go
Unofficial Elasticsearch client for Go with 7,500+ GitHub stars, in production since 2012.
- Go
- Elasticsearch
In 2012 Elasticsearch had no Go client, so we wrote one. olivere/elastic
stayed the default choice for Go applications talking to Elasticsearch for most
of a decade, until Elastic shipped an official driver of its own. By then the
library had 7,500 stars and 1,200 forks on GitHub, and it had been running in
production, ours and other people's, the whole time.
A decade of keeping up
Elasticsearch changed its API with every major release, from 0.90 through 7.x, and a client that lags behind is worse than none. Each major release got its own library version with a stable, idiomatic Go API, and the older ones kept working for the people who could not upgrade yet. Whether the library's adoption is the reason Elastic eventually built an official Go client, we cannot prove. The timing fits.
What it covers
The aim was the whole API, not the convenient half:
- the query DSL: match, term, bool, nested, function score and the rest
- aggregations: bucket, metrics and pipeline
- index management: mappings, settings, templates
- bulk operations, scroll, reindex, update-by-query
- snapshot and restore, ingest pipelines, task management
- X-Pack: security, monitoring, watcher
MIT licensed, with contributions from the community that used it.