Closed jorgeborges closed 3 years ago
hey @alberto-bottarini, I'm done with the changes required for this to be merged.
Take notice that your commits are also in this PR. Changes that I made:
v3
(this lib is currently v2
).Besides that, I also did the following:
HttpClient
that was being duplicated in the previous PR, moved the duplicated code to a private method.Everything else is working as in your PR.
If you are OK with these changes, I can merge right away and make a new release. Is this OK with you?
It's ok for me! Thanks a lot
Continues the work from #83 by @alberto-bottarini.
This PR allows you to batching multiple hits in a single request using
/batch
endpoint.It adds some new methods:
Here's an example that sends two hits.
The queue is emptied when the hits are sent, but it can also be empty manually with
emptyQueue
method.