schwartzmx / gremtune

Golang Gremlin Tinkerpop client with AWS Neptune compatibility
MIT License
26 stars 19 forks source link

Stream response as and when Neptune provides it #3

Closed rsrinathr closed 5 years ago

rsrinathr commented 5 years ago

Neptune provides 64 values per Response that is why Execute at present provides a [] of Response since it waits for all the responses to be retrieved and then provides it. I have added the ExecuteAsync method that takes a channel to provide the Response as request parameter and provides the Response as and when it is received from Neptune. The Response are streamed to the caller and once all the Response are provided the channel is closed.

Java driver has the Stream option http://tinkerpop.apache.org/javadocs/3.4.0/core/org/apache/tinkerpop/gremlin/driver/ResultSet.html#stream--

schwartzmx commented 5 years ago

thanks for the PR, good idea on implementing async response. I'll try to get this pulled down and reviewed tonight.

rsrinathr commented 5 years ago

Did you get a change to review the PR ? Let me know If you need any changes

rsrinathr commented 5 years ago

Did you get a change to review the PR ?

rsrinathr commented 5 years ago

I have fixed all the review comments https://github.com/schwartzmx/gremtune/pull/3/commits/a2b232c71094dba872009312fc38f2480e885b17

schwartzmx commented 5 years ago

Thanks @rsrinathr

rsrinathr commented 5 years ago

Thank you. Can you please create a new Tag ? so I can update it in my go.mod file to pull the latest changes.

schwartzmx commented 5 years ago

Added a new tag @rsrinathr https://github.com/schwartzmx/gremtune/releases/tag/v0.0.2