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

Implement orders depth limit for Staggered Orders #386

Closed
bitphage opened this issue Nov 4, 2018 · 3 comments
Closed

Implement orders depth limit for Staggered Orders #386

bitphage opened this issue Nov 4, 2018 · 3 comments

Comments

@bitphage
Copy link
Collaborator

bitphage commented Nov 4, 2018

When Staggered Orders strategy is used with huge depth and big orders count, it causes long maintenance time and lots of orders replacements especially when we are adding new funds from outside.

To improve strategy speed, decrease overhead and maintenance time, I propose to limit orders count by N depth (user-defined parameter).

I would like to work on this.

@MarkoPaasila
Copy link
Collaborator

I don't want to say "don't do it". It doesn't sound like a massive job, so just do it. Would it worth checking first that it doesn't unnecessarily sort and iterate over the whole list every time or something else heavy? If not, then leaving further orders unplaced seems necessary.

@bitphage
Copy link
Collaborator Author

bitphage commented Nov 6, 2018

Well, it's actually possible to avoid loading of all own orders in some cases which may speed up initial orders placement and "silent" maintenance when nothing happening.

Though keeping N orders seems best to me because maintaining far-from-center orders is useless waste of own resources and blockchain nodes resources. While trading is happening around center, we are continuously replacing far orders to allocate profits. Settings adjustment like changing spread/increments also requires replacing of all orders. We actually interesting on maintaining only "operational depth" orders, which is vary depending on worker online %. The less worker is online, the more depth it needs, and vice versa.

@MarkoPaasila
Copy link
Collaborator

"Operational Depth" is a good term :-)

bitphage added a commit to bitphage/DEXBot that referenced this issue Nov 26, 2018
Operational depth limit allows to keep only N buy or sell orders and
adding more orders if needed (price movements).

Reasons for having depth limit:

* Decrease strategy maintenance time
* Reduce blockchain overhead by decreasing transactions count
* Increase initial order placement time

Closes: Codaone#386
bitphage added a commit to bitphage/DEXBot that referenced this issue Nov 26, 2018
Operational depth limit allows to keep only N buy or sell orders and
adding more orders if needed (price movements).

Reasons for having depth limit:

* Decrease strategy maintenance time
* Reduce blockchain overhead by decreasing transactions count
* Increase initial order placement time

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

No branches or pull requests

3 participants