elastic / elasticsearch-rs

Official Elasticsearch Rust Client
https://www.elastic.co/guide/en/elasticsearch/client/rust-api/current/index.html
Apache License 2.0
705 stars 72 forks source link

Add user agent version based on cargo package version #26

Closed russcam closed 4 years ago

russcam commented 4 years ago

This commit adds a default user-agent header to the client of the form

elasticsearch-rs/{version}

where version is the cargo package version. This format matches the agreed format for official language clients.

Update the package versions for the client and api_generator to match that of the REST API spec version from which the client is generated. The client versioning will follow at least the major/minor of Elasticsearch, similar to other official clients.