Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

metric query API support #45

Merged
merged 1 commit into from
May 18, 2015
Merged

metric query API support #45

merged 1 commit into from
May 18, 2015

Conversation

yannmh
Copy link
Member

@yannmh yannmh commented Apr 24, 2015

  • Add support for metric query API
  • Allows to re-set _timeout parameter dynamically

@yannmh yannmh self-assigned this Apr 24, 2015
@yannmh yannmh force-pushed the yann/query-endpoint branch 4 times, most recently from 829de96 to eabd2bf Compare April 27, 2015 14:16

# `from` is a reserved keyword in Python, therefore
# `api.Metric.query(from=...)` is not permited
# -> map `start` to `from` and `end` to `to`
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's better anyway since the rest of the api seems to expect start and end parameters when searching for something (I checked api//events.py)

@degemer
Copy link
Member

degemer commented Apr 27, 2015

Really nice @yannmh !
I would have preferred some more 🅰️ - 💤, but it doesn't really matter.
Could you just add a real integration test (probably retrieving the metrics sent here https://github.com/DataDog/datadogpy/blob/master/tests/integration/api/test_api.py#L346) ?

:type start: POSIX timestamp

:param end: timestamp of the end of the query.
:param end: query start timestamp
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

typo s/start/end

@yannmh yannmh force-pushed the yann/query-endpoint branch from eabd2bf to ce56efb Compare May 8, 2015 15:26
@yannmh yannmh force-pushed the yann/query-endpoint branch from ce56efb to 51f755e Compare May 18, 2015 21:43
@yannmh
Copy link
Member Author

yannmh commented May 18, 2015

Added a real integration test. Thanks for your feedback @degemer !

yannmh added a commit that referenced this pull request May 18, 2015
@yannmh yannmh merged commit 9225a63 into master May 18, 2015
@yannmh yannmh deleted the yann/query-endpoint branch May 19, 2015 14:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants