Fork me on GitHub
#onyx
<
2017-04-11
>
theblackbox12:04:57

can someone check my understanding on the function of a custom refinement for a trigger on a session window. Refinements determine how state is handled for the trigger, but I was under the impression that any changes to the state are emitted to downstream stages... is that not the case?

theblackbox12:04:52

my use case: I want to tag data within a session so that a downstream stage can handle it accordingly.

theblackbox12:04:50

but after having implemented it, my window/trigger does not mutate the event data passing through it

gardnervickers12:04:06

Yes you'll want to use :trigger/emit

theblackbox12:04:53

cheers @gardnervickers instead of/along side?

gardnervickers12:04:27

@theblackbox in your case if you're tagging for further downstream tasks you'd want to use :trigger/emit instead of :trigger/sync

theblackbox12:04:02

hmm... I'm guessing that I need a newer onyx [was on a 10.x beta 7 ] so just updated and getting some unexpected issues with Onyx Kafka

theblackbox12:04:07

given that my kafka-consumer workflow specifies: :kafka/deserializer-fn :onyx.tasks.kafka/deserialize-message-json

theblackbox12:04:29

which should still be available as far as I can see

theblackbox12:04:46

hmm, seems if I include the dependency in my project.clj then it's fine so probably missing that somewhere?

gardnervickers13:04:35

@theblackbox hmm that's odd. Could you open an issue for that and we'll take a look later today?

theblackbox13:04:57

also, good work on the emit - just what I've been hunting for (MD pointed me at custom refinements only a week or so back [I think primarily based on DB interaction] but this implementation makes more sense)

gardnervickers13:04:05

:trigger/emit is pretty new, a direct consequence of switching the core of Onyx to use asynchronous barrier snapshotting. I don't think we have user guide docs for it yet even. Glad that sounds like it'll work for you.

theblackbox13:04:06

you have enough in the docs to make it useful 😉

michaeldrogalis15:04:15

Thanks for the bug report @theblackbox. Cheshire is in dev dependencies, might want to simply move it up out of the profiles. I guess that one’s evaded me since I’ve used Cheshire in conjunction with every project I use, heh.

theblackbox15:04:46

I figured it'd be something like that, tends to happen for those kind of ubiquitous tools

michaeldrogalis15:04:27

@theblackbox I put the patch on master. You can use the latest snapshot, or 0.10.0.0-20170411.151739-28. It will go out with th next beta release, too.

michaeldrogalis15:04:43

I think we’re going to get out 0.10.0 official out soon anyway. Been in a beta for a long time, and at this point we’re just sniping bugs as we find them in production.

georgek18:04:39

Just an update on the Onyx-Java front: My developer doing the unit tests is new to clojure so he’s also tackling the learning curve. He’s almost done with them and general cleanup. Looks like we should have things ready for code review this week. I’m starting to develop the instance-binding affordances now that will go in Onyx-Java and native-code support in a separate package: https://github.com/MissInterpret/onyx-native That’s finally getting under way actively now and should have a full draft ready for review in a couple of weeks I’ll keep everyone informed!

lellis18:04:57

hi all! how can i use spy in my read-log datomic-onyx-plugin function?

michaeldrogalis19:04:39

@lellis Inputs and Outputs can have an :onyx/fn

michaeldrogalis19:04:59

You might want to set up a lifecycle to log for after read batch though - that spy thing is just a quick trick.

lucasbradstreet19:04:15

@georgek awesome! Will review when you’re ready 🙂