This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2015-10-19
Channels
- # admin-announcements (2)
- # beginners (24)
- # boot (36)
- # business (1)
- # cbus (3)
- # cider (22)
- # cljs-dev (91)
- # clojure (101)
- # clojure-canada (9)
- # clojure-china (3)
- # clojure-czech (21)
- # clojure-nl (3)
- # clojure-russia (131)
- # clojure-sg (5)
- # clojure-uk (9)
- # clojure-ukraine (4)
- # clojure-za (2)
- # clojurebridge (18)
- # clojurescript (333)
- # clojurex (6)
- # devcards (1)
- # events (37)
- # hoplon (15)
- # ldnclj (23)
- # luminus (3)
- # off-topic (41)
- # om (258)
- # onyx (20)
- # re-frame (46)
- # reagent (7)
- # spacemacs (2)
@michaeldrogalis Okay another onyx question: I have a (stuart sierra style) component with a bunch of state in it, things like the db connection and a kafka channel, etc... What is the best way to access that from an onyx job?
but then I remember you saying all onyx workflows, catalogs and lifecycles are serializable things
Where should I provide access to the component so that I can use it in my onyx tasks?
@spangler: Correct, Onyx job data structures need to be serializable. You'd construct the Component through a lifecycle.
Note that you need to build the Component (e.g. call Start on it) within the lifecycle. Onyx intentionally makes it very hard to reach into a global state and gain access to an already running component.
@michaeldrogalis Ah okay, so every time a task fires up it will build the component and then tear it down when it is done?
Okay cool, I can do that. Another quick question: if my job branches into many tasks in the workflow, is each task potentially distributed among the virtual peers?
Can you rephrase that?
So like, 100 virtual peers, 10 tasks, ~ 10 vpeers per task?
Ah, I was just wondering if within the same call to submit job, if the various tasks in the workflow are distributed out to all the available virtual peers?
That's how it works, yes. You can control it via schedulers if you need anything other than a balanced workload: https://github.com/onyx-platform/onyx/blob/master/doc/user-guide/scheduling.md
Okay, that is what I assumed, just wanted to make sure I was thinking about it correctly
No prob.