MikaLendingBot icon indicating copy to clipboard operation
MikaLendingBot copied to clipboard

[Feature Request] Bitfinex and Poloniex both at the same time

Open jasoncharles opened this issue 7 years ago • 12 comments

Hi, Is it possible to run a single instance of poloniexlendingbot to manage lending for both Poloniex and Bitfinex at the same time? As I tried entering both API keys in the default.cfg file but only saw Bitfinex on the bot's web page.

Thanks for you help Jason

jasoncharles avatar Sep 01 '17 09:09 jasoncharles

No, that's not supported at this time.

rnevet avatar Sep 01 '17 09:09 rnevet

I've been thinking about this for a long time. We need to introduce a true threading model where each exchange is Thread'd off and runs on it's own. We can serialize/synchronize access to the botlog so that both can write to it. Will probably have to nest the bot log 1 level deeper and keep 'exchange' at the top level.

lendingbot.js can do .each('exchange') and create a tab-style interface for each exchange.

utdrmac avatar Sep 01 '17 19:09 utdrmac

I've been also thinking about it, and I think it's way to complicated to make it a priority for development. Things like Market Analysis, Lending History which are db based need to be also separated for example.

In the end merging them just so they run in different threads doesn't bring much...

rnevet avatar Sep 01 '17 20:09 rnevet

It would bring an easier user experience. Wouldn't have to run two bots in two different screen sessions on two different web ports.

utdrmac avatar Sep 01 '17 23:09 utdrmac

Separating the databases is easy, just prepend the exchange name to each file.

utdrmac avatar Sep 01 '17 23:09 utdrmac

"easy" :D

utdrmac avatar Sep 01 '17 23:09 utdrmac

Well, that can be handled on web side, could link to bots.. without running in one instance. Could even use one webserver.

rnevet avatar Sep 02 '17 20:09 rnevet

We could create a plug-in for multi-purpose, only telling the JS where to read the JSON from.

rnevet avatar Sep 02 '17 20:09 rnevet

I agree that for now there are more important features/issues and running two bots in two screen sessions is tolerable. But perhaps start designing with this feature in mind (like the db segregation that was brought up) so there is not a lot of re-work. Thank you guys!

JCBauza avatar Sep 04 '17 18:09 JCBauza

I think having a good UI for a "Main/Others bots" scenario is much easier to achieve and would actually be the main benefit. Some people are running multiple bots for multiple accounts, not necessarily different exchanges.

rnevet avatar Sep 04 '17 18:09 rnevet

that's very true, good point

JCBauza avatar Sep 04 '17 18:09 JCBauza

My latest PR simplifies multiple bots. You get a docker container for each bot and an nginx proxy that automatically points to the web interface of the bot.

You can start as many as you like.

https://github.com/BitBotFactory/poloniexlendingbot/pull/515

I would however also like to see multiple exchanges in one bot. I actually want to be able to Tx funds between exchanges. Not a big deal for BTC, but it's massive for some of the alts.

laxdog avatar Sep 08 '17 14:09 laxdog