Fork me on GitHub
#onyx
<
2017-11-23
>
lucasbradstreet00:11:11

We will be releasing 0.12 very soon, if you’re able to upgrade. CI is building a 0.12 snapshot with the fix now.

lucasbradstreet00:11:45

I can deploy to clojars a 0.11 snapshot to tide you over if you really need it soon.

lucasbradstreet00:11:41

@kenny give onyx-kafka 0.11.1.2-20171123.001220-3 a go.

kenny00:11:57

We'll be upgrading to 0.12 soon. That release solves my issue. Thanks!

kenny00:11:09

BTW OCD thing: anyway you guys could update to a newer version of clj-fuzzy to get rid of this warning:

WARNING: any? already refers to: #'clojure.core/any? in namespace: clj-fuzzy.helpers, being replaced by: #'clj-fuzzy.helpers/any?
I have added it in my :dependencies temporarily to get rid of the warning 🙃

lucasbradstreet00:11:47

Yeah, I really should. I’ll get that in 0.12 too.

lucasbradstreet00:11:39

There were so many of those previously with 1.9 on the way that I had gotten a bit too used to tuning them out.

michaeldrogalis00:11:12

Incidentally when we drop Schema we can drop clj-fuzzy too

kenny00:11:10

Anyway.. The issue that led us down this rabbit hole is still present even after updating to onyx-kafka 0.11.1.1.

kenny00:11:48

I'll try and create an isolated reproduction of the problem.

lucasbradstreet00:11:40

Try validating your task map against the schema in the onyx.kafka.tasks file

lucasbradstreet00:11:04

That’s about as minimal as you can get here

kenny00:11:51

(schema/check kafka-tasks/KafkaOutputTaskMap
              {:onyx/type           :output
               :onyx/name           :kafka-out
               :onyx/plugin         :onyx.plugin.kafka/write-messages
               :onyx/medium         :kafka
               :kafka/offset-reset  :earliest
               :kafka/zookeeper     "127.0.0.1:2181"
               :kafka/topic         "test1"
               :kafka/serializer-fn :taoensso.nippy/freeze})
=> {(not (= (name (:kafka)) (namespace :kafka/offset-reset))) invalid-key}
:thinking_face:

lucasbradstreet00:11:51

Try retyping the kafka offset line?

lucasbradstreet00:11:59

Maybe it’s a weird Unicode thing?

kenny00:11:29

Same result.

lucasbradstreet00:11:24

Oh wait. You did it against the output task schema

kenny00:11:45

Isn't that what it is?

lucasbradstreet00:11:33

Offset reset is only for input tasks

kenny00:11:09

Wow that error was wonderful

lucasbradstreet00:11:22

I was looking at the first task the whole time.

lucasbradstreet00:11:46

So what’s happening is that we ban any kafka namespaced keywords that aren’t in the schema for the task. It would have been hard for us to specifically check whether you had mistakenly supplied an input task option.

kenny00:11:37

Makes sense. But still, quite the wild goose chase 😬

lucasbradstreet00:11:37

Not sure how to make that one better. I could improve the error message to say disallowed kafka namespaced keyword detected but I still wouldn’t have noticed that it was on the output since I would have looked at your input task immediately

michaeldrogalis00:11:54

I think a holiday project for me during the slow days is going to be switching this all out for Spec.

lucasbradstreet00:11:36

kafka.input/offset-reset may have been a better namespace choice

lucasbradstreet00:11:06

Well, that was certainly a win for Occum’s razor.

kenny01:11:19

Haha indeed.

akiel12:11:15

I have a question regarding the balanced task scheduler. Why does it skip task allocation if more peers are available as a given job can consume? In my case, I have two peers (with some tag) but I like to use only one (max-peers). In this case the job doesn’t start at all. Why?

michaeldrogalis18:11:20

@akiel May be a bug in the scheduler. Can you send us your job definition?

michaeldrogalis18:11:29

The fact that it doesn't start at all sounds wrong.

akiel18:11:52

I‘ll do that in one hour. Thanks.