w1ld3r / crypto-signal

The #1 Automated Technical Analysis (TA) & Algo. Trading tool for Coinbase, Bittrex, Binance, and more! (Track over 500+ coins)
http://cryptosignal.dev
MIT License
76 stars 37 forks source link

Problem with Worker interval and Notifications #28

Closed velajos closed 3 years ago

velajos commented 3 years ago

Hello! I'm having problems with the "workers" because the second one starts working when the first one has not yet finished. Then, after a 30 or 45 minutes working well, I stop receiving notifications. Apparently workers overlap and this prevents them from working properly.

This is my configuration in "settings":

update_interval: 300 start_worker_interval: 60 market_data_chunk_size: 20

I also have tried several combinations with update_interval , start_worker_interval and market_data_chunk_size, but after a short period of time there is a lag and it goes out of control.

This is what the program looks like running, but it doesn't send any notifications:

Sleeping for 300 seconds Beginning analysis of XLMDOWN/USDT PPT/BTC: Beginning analysis of XLM/BTC CVC/BTC: Beginning analysis of THETA/BTC Beginning analysis of binance Beginning analysis of BAR/USDT Beginning analysis of binance Beginning analysis of KEY/USDT enabled notifers: ['telegram'] Starting Worker-27 Starting default analyzer... Using the following exchange(s): ['binance'] Getting data for ['XVG/USDT', 'ATA/BTC', 'ATA/USDT', 'GTC/BTC', 'GTC/USDT', 'TORN/BTC', 'TORN/USDT', 'BAKE/BTC'] Starting Worker-5

Optimally, the next worker should start work when the first worker has completed the analysis and has notified, regardless of the time it takes to complete the analysis to avoid overlapping.

w1ld3r commented 3 years ago

Sorry for the delay. Have you been able to resolve your issue ? If yes, how ?

velajos commented 3 years ago

Sorry for the delay. Have you been able to resolve your issue ? If yes, how ?

Hi, I hope you are well.

What I did:

I timed how long each worker took to do its job and based on those results I managed to configure everything manually based on the speed of my internet internet connection. I think that each configuration is different because it depends on the power of the computer and the speed of the Internet connection.

But generally speaking everything is fine, you just have to know how to adjust the times to avoid overlaps.

velajos commented 3 years ago

Can you check the other Telegram Issue I have opened? Thanks

w1ld3r commented 3 years ago

Sorry for the delay. Have you been able to resolve your issue ? If yes, how ?

Hi, I hope you are well.

What I did:

I timed how long each worker took to do its job and based on those results I managed to configure everything manually based on the speed of my internet internet connection. I think that each configuration is different because it depends on the power of the computer and the speed of the Internet connection.

But generally speaking everything is fine, you just have to know how to adjust the times to avoid overlaps.

Have you resolve your issue using the two settings options described in "Advanced Settings" documentation ?

w1ld3r commented 3 years ago

Can you check the other Telegram Issue I have opened? Thanks

I'll implement the functionality next week.

velajos commented 3 years ago

settings options described in "Advanced Settings" documentation ?

Yes. Once I understood how they work, I was able to configure them based on what I needed. Currently everything works perfectly. By the way, what is the maximum number of workers? The most I've seen is 54

w1ld3r commented 3 years ago

There is no limit on the number of worker. If you set themarket_data_chunk_size to 1, you will have one worker per pair. So if you are requesting info on 54 pairs, there will be 54 workers.