onyx

FYI: alternative Onyx :onyx: chat is at <https://gitter.im/onyx-platform/onyx> ; log can be found at <https://clojurians-log.clojureverse.org/onyx/index.html>
Forrest 2017-12-15T00:11:22.000027Z

hey there. I am working on a project with a number of grouped tasks and when trying to query the state of said tasks (via the onyx-peer-http-query server), I’m not receiving anything back in the :contents when not supplying the groups in my query params.

Forrest 2017-12-15T00:12:00.000028Z

I’m curious if this is expected behavior and if so, where should I go to retrieve the group-ids relevant to my tasks (something I also can’t seem to figure out, lol).

lucasbradstreet 2017-12-15T00:43:07.000109Z

Onyx version?

lucasbradstreet 2017-12-15T00:43:17.000168Z

We did fix an issue like that in peer-http-query in the last month or so

lucasbradstreet 2017-12-15T00:44:27.000003Z

https://github.com/onyx-platform/onyx-peer-http-query/issues/5 hmm, probably not this issue

lucasbradstreet 2017-12-15T00:44:36.000147Z

Sounds like you’re just getting empty results instead.

lucasbradstreet 2017-12-15T00:45:00.000206Z

If you could fork http-peer-query and demonstrate the issue via https://github.com/onyx-platform/onyx-peer-http-query/blob/0.12.x/test/onyx/health_test.clj, that’d be great.

Forrest 2017-12-15T00:46:35.000050Z

we’re using 0.12.

Forrest 2017-12-15T00:47:20.000010Z

will take a look at forking right now

lucasbradstreet 2017-12-15T00:50:22.000340Z

K. Thanks. We may have seen something similar. Hopefully it’s easily reproducible. If not, let us know and we can dig in further

Forrest 2017-12-15T00:52:36.000198Z

k, so it looks like when I don’t specify a groups query param, the health test fails with the following:

FAIL in (health-test) (health_test.clj:137)

expected: (get-in (clojure.edn/read-string (:body response)) [:contents "A stealthy fo"])
  actual: nil

  values: (get-in
           {:contents {}
            :grouped? true
            :window {:window/aggregation :onyx.windowing.aggregation/count
                     :window/id :my-window-id
                     :window/range [5 :minutes]
                     :window/storage-strategy [:incremental :ordered-log]
                     :window/task :my/inc
                     :window/type :fixed
                     :window/window-key :event-time}}
           [:contents "A stealthy fo"])

Forrest 2017-12-15T00:53:12.000352Z

I simply commented out this line: https://github.com/onyx-platform/onyx-peer-http-query/blob/0.12.x/test/onyx/health_test.clj#L133

Forrest 2017-12-15T00:53:18.000224Z

and ran the tests

lucasbradstreet 2017-12-15T00:54:11.000096Z

Oh, I realised that it was by design (probably bad design)

Forrest 2017-12-15T00:54:17.000096Z

just to clarify, my expectation is that if I don’t specify groups, that I should get contents for all the groups

lucasbradstreet 2017-12-15T00:54:24.000148Z

Yeah, that’s really how it should work.

Forrest 2017-12-15T00:54:28.000007Z

:thumbsup:

lucasbradstreet 2017-12-15T00:55:02.000052Z

k, cool, thanks. I can fix that tonight.

Forrest 2017-12-15T00:55:14.000082Z

that would be awesome. thanks so much!

Forrest 2017-12-15T00:55:18.000114Z

you guys are awesome!

lucasbradstreet 2017-12-15T00:56:10.000177Z

How do you find the usability of that feature? I ummed and ahhed about providing a way to do it without supplying the allocation version, but I was worried that users would get at the state over an entire cluster in an inconsistent way. That said, it would make it simpler to play with.

Forrest 2017-12-15T00:59:35.000155Z

overall its been very useful. just had a curveball with a grouped task. all of the other tasks i have aren’t, so it’s been really great to be able to query the state and see what’s going on in my windowed tasks

Forrest 2017-12-15T01:00:06.000133Z

the params weren’t too difficult to get at either, which made it a really usable feature, imo

lucasbradstreet 2017-12-15T01:01:25.000319Z

Great 🙂

lucasbradstreet 2017-12-15T01:01:41.000045Z

Yeah, it’s been really nice for us too. Even if you only use it for debugging.

lucasbradstreet 2017-12-15T01:02:11.000242Z

Can you please give onyx-peer-http-query 0.12.0.1-20171215.010158-3 a try?

lucasbradstreet 2017-12-15T01:02:25.000220Z

If it works for you I’ll release 0.12.0.1

Forrest 2017-12-15T01:05:11.000063Z

well, unfortunately, i’d need to redeploy my onyx setup, which takes some time (and also my manager’s sign off 😄), so i’d probably need to test that in the morning.

lucasbradstreet 2017-12-15T01:05:25.000226Z

Understood 😄

lucasbradstreet 2017-12-15T01:05:35.000100Z

Well, let me know whenever and I’ll cut you a release.

Forrest 2017-12-15T01:05:53.000181Z

that’s awesome. thanks so much! will ping you tomorrow for sure

Forrest 2017-12-15T18:18:13.000593Z

hey @lucasbradstreet, good news. I tested out your change and it looks great! without specifying group keys I get back everything instead of nil. if I specify the groups, it still works as well. kudos! thanks so much for getting that out so quickly. :thumbsup:

lucasbradstreet 2017-12-15T18:20:04.000509Z

Great. Thanks for the update 🙂.

👍 1
lucasbradstreet 2017-12-15T18:20:41.000375Z

0.12.0.1 is going through our release process now.

✅ 1
Forrest 2017-12-15T18:20:53.000057Z

💥 awesome