olivere / elastic

Deprecated: Use the official Elasticsearch client for Go at https://github.com/elastic/go-elasticsearch
https://olivere.github.io/elastic/
MIT License
7.39k stars 1.15k forks source link

Can I use elastic.v7 with Elasticsearch 8.x for basic ES operations #1631

Closed cmadarsh closed 2 years ago

cmadarsh commented 2 years ago

Which version of Elastic are you using?

elastic.v7 (for Elasticsearch 8.x)

Problem statement

Tried implementing elastic v7 with Elasticsearch version 8.x, and its working fine.

Please describe the actual behavior

Basic connectivity and ES CRUD operations are working fine.

Query?

As basic things are working fine, what issues I can anticipate with this combination of versions elastic.v7 with elasticsearch 8.x?

olivere commented 2 years ago

Just can certainly try, but you're much better off using the official client.

cmadarsh commented 2 years ago

Thanks Olivere.. I basically needed a library with which I can build a wrapper for dynamic query generation and as this library provides structs for queries, mainly on nested and inner hits, it would help me. Official client does not provide structs, need to provide direct JSON queries.

The library is very good, for my usage, can I expect elastic v8 next year?

olivere commented 2 years ago

@cmadarsh Have you seen the latest changes to the official client that come with the typed client? It has a proper DSL now: For the requests now, for responses later.

As for Elastic v8: That won't happen. See my latest update in #1533.