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

Add bulkDepth functionality #98

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

AScripnic
Copy link

Add bulkDepth functionality that creates only one websocket connection, that will prevent people to overpopulate the server.
Created this functionality based on their documentation: https://github.com/binance-exchange/binance-official-api-docs/blob/master/web-socket-streams.md

@coveralls
Copy link

Coverage Status

Coverage decreased (-26.1%) to 66.667% when pulling 63ddfb4 on AScripnic:master into 3bc9479 on HyperCubeProject:master.

@balthazar
Copy link
Member

Interesting to see they added this functionality! I do think however it should not only be done for only the depth endpoint but for all of the sockets calls. It will also fix a lot of issues people were having.

@AScripnic
Copy link
Author

@balthazar Do you mean 1 method that will include in self all other functionalities or a method for every existing socket call?

@balthazar
Copy link
Member

No I'm saying that we could refactor all the websockets methods to use combined streams with one websocket instead of multiples. I was doing that because it was not a feature available previously, but this pretty much simplifies everything

@balthazar
Copy link
Member

Let me know if you need guidance and / or you really don't know what to do and would like me to do it, I'm just a bit overwhelmed lately

@AScripnic
Copy link
Author

@balthazar I can do it, but I'm not sure it's the right approach. I'd say to leave this ones, but to make the possibility to cancel a specific websocket request and leave all others.

@balthazar
Copy link
Member

I don't think there is a strong use-case to cancel a specific websocket if you want to open multiple channels. Even if you want to do something like that, it should be easier to clear the stream and reopen a new one. Creating one websocket instead of multiples like I was doing using a loop (and thus isolating the websocket instances) is not really the ideal solution. This would allow us to expose the instance easily for people to either clean, check status or do their own special sauce

@AScripnic
Copy link
Author

@balthazar I refer more to this one: #62

@AScripnic
Copy link
Author

AScripnic commented Jun 18, 2018

@balthazar for partial depth it returns only a single array bids, and I don't really know what are those bid or ask. Maybe we can update it partially at least?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants