Fork me on GitHub
#onyx
<
2015-11-03
>
spangler18:11:01

Hello @michaeldrogalis! So now I am starting to deploy onyx to multiple servers, and I am a little uncertain of how to proceed with aeron. Do I need aeron on a separate server? And if so, how do I get multiple onyx instances to communicate with that aeron?

spangler18:11:17

Or will it still work if each node has their own aeron driver running?

lucasbradstreet18:11:34

Each node needs their own Aeron driver running

spangler18:11:10

Okay, cool. So it is just used for onyx internally then? Not to communicate between instances?

lucasbradstreet18:11:51

For performance, it's recommended that this is done out of process while in production but it'll be fine to run it via the peer group to get up and running initially

lucasbradstreet18:11:36

It's kind of a "driver" for a networking protocol. Onyx talks to it, and it talks to the other Aeron drivers on the other machines

spangler18:11:42

Ah, that sounds good. So how would I start it up out of process then?

lucasbradstreet19:11:09

Make sure you run it with -server JVM opts

spangler19:11:15

Aha, so I can just make a project that runs standalone?

lucasbradstreet19:11:42

Sure. It's also fine to run it from the same project but use lein run -m

spangler19:11:16

Ah, so it just has its own main then

spangler19:11:24

That would probably be simpler

spangler19:11:48

Have you guys had problems with running out of zookeeper ports?

spangler19:11:13

If I go above 50 peers it throws errors that I have run out of zookeeper ports

spangler19:11:39

Maybe I don't need that many...

spangler19:11:18

That is the one. Thank you again!

lucasbradstreet19:11:24

Off to sleep. Good luck

spangler19:11:20

Okay, so next trick! I submitted a job on one node, and the tasks are only being handled on that node. How do I get the nodes to share tasks?

spangler19:11:53

They are both connected to the same zookeeper...

michaeldrogalis19:11:16

@spangler: Are they all connected with the same :onyx/id?

spangler19:11:35

Different :onyx/id ....

spangler19:11:42

Does it need to be the same one?

spangler19:11:38

Interesting, okay

michaeldrogalis19:11:14

:onyx/id is used to denote tenancy. Moreover, it's what prevents one Onyx deployment from exclusively hogging ZooKeeper all to itself.

spangler19:11:46

So can I hardcode an :onyx/id, or do I need a different shared one each time I deploy?

michaeldrogalis19:11:14

Reuse it if you want jobs from the last time you deployed to stick around.

spangler19:11:21

Ah that is good

spangler19:11:27

Cool, trying now

spangler19:11:56

Hmm, how is the kafka support? Can I use that instead of aeron?

michaeldrogalis20:11:37

@spangler: Kafka is for I/O, Aeron is for internal message delivery. Aeron is the only medium that we offer for that.

spangler20:11:09

Aha, so kafka replaces core.async then

michaeldrogalis20:11:44

@spangler: Erm, they're both plugins, if that's what you mean.

spangler20:11:14

I mean, it plays the same role as core.async

spangler20:11:15

I would use kafka read and write in my catalog instead of core.async yes?

spangler20:11:23

is what I mean

michaeldrogalis20:11:33

Anyhow, yeah - I do recommend checking that out though. I think it would clear up a few misconceptions about how things work and pave the path forward for you. simple_smile

spangler20:11:54

Cool, will definitely read thanks!