elastic / elasticsearch-rs

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

[REFACTOR] Rename status_code to status? #47

Closed mwilliammyers closed 4 years ago

mwilliammyers commented 4 years ago

Should we rename status_code everywhere to status to match reqwest?

russcam commented 4 years ago

Thanks for opening the conversation, @mwilliammyers.

I intentionally named it status_code to differentiate it from any notion of a status that can be returned from Elasticsearch. For example, many responses return the status code in a status field on the response; I understand that a response body needs to be read to get to this, but I wanted to avoid any confusion between a status related to Elasticsearch, and a status related to the HTTP library. What do you think?

mwilliammyers commented 4 years ago

Ahhh makes sense. I agree 100% then.

russcam commented 4 years ago

Cool cool. I'll close this issue 👍