Hi all! Somebody get this exception init a peer?
#error {
:cause offset=0 length=32 not valid for capacity=0
:via
[{:type java.lang.IllegalArgumentException
:message offset=0 length=32 not valid for capacity=0
:at [org.agrona.concurrent.UnsafeBuffer wrap UnsafeBuffer.java 211]}]
:trace
[[org.agrona.concurrent.UnsafeBuffer wrap UnsafeBuffer.java 211]
[org.agrona.concurrent.UnsafeBuffer init UnsafeBuffer.java 114]
[io.aeron.CncFileDescriptor createMetaDataBuffer CncFileDescriptor.java 166]
[io.aeron.CommonContext isDriverActive CommonContext.java 453]
[io.aeron.driver.MediaDriver ensureDirectoryIsRecreated MediaDriver.java 334]
[io.aeron.driver.MediaDriver init MediaDriver.java 102]
[io.aeron.driver.MediaDriver launch MediaDriver.java 218]
[onyx.messaging.aeron.embedded_media_driver.EmbeddedMediaDriver start embedded_media_driver.clj 33]
[onyx.messaging.aeron.messaging_group.AeronMessengerPeerGroup start messaging_group.clj 49]
[com.stuartsierra.component$fn__47046$G__47040__47048 invoke component.cljc 5]
[com.stuartsierra.component$fn__47046$G__47039__47051 invoke component.cljc 5]
[clojure.lang.AFn applyToHelper AFn.java 154]
[clojure.lang.AFn applyTo AFn.java 144]
[clojure.lang.Var applyTo Var.java 702]
[clojure.core$apply invokeStatic core.clj 659]
[clojure.core$apply invoke core.clj 652]
[com.stuartsierra.component$try_action invokeStatic component.cljc 117]
[com.stuartsierra.component$try_action invoke component.cljc 116]
[com.stuartsierra.component$update_system$fn__47097 invoke component.cljc 139]
[clojure.lang.ArraySeq reduce ArraySeq.java 114]
[clojure.core$reduce invokeStatic core.clj 6747]
[clojure.core$reduce invoke core.clj 6730]
[com.stuartsierra.component$update_system invokeStatic component.cljc 135]
[com.stuartsierra.component$update_system doInvoke component.cljc 129]
[clojure.lang.RestFn invoke RestFn.java 445]
[com.stuartsierra.component$start_system invokeStatic component.cljc 163]
[com.stuartsierra.component$start_system invoke component.cljc 155]
[onyx.system.OnyxPeerGroup$fn__64983 invoke system.clj 119]
[onyx.system$rethrow_component invokeStatic system.clj 67]
[onyx.system$rethrow_component invoke system.clj 65]
Solved clenaning aeron buffer /dev/shm…
not sure if anyone can answer this, but in the onyx-elastic search plugin it appears that upserts don’t use the upsert function from the underlying library, instead it switches on the doc id and does a put or a create instead: https://github.com/onyx-platform/onyx-elasticsearch/blob/0.9.x/src/onyx/plugin/elasticsearch.clj#L222
I’m not sure if I’m missing the reasoning behind that
I’m happy to fork and submit a PR but if there’s some reason upsert is avoided I’d skip it
@jgerman I'm not sure that anyone here can answer that. The ElasticSearch plugin was user-contributed quite a while ago, and no one on the core team has worked with ES before.
Happy to take a fix if it looks right to you.
heh, no problem, I wanted to check first, I wonder about changing the behavior of upsert since people may depend on it
but that’s easy enough to work around, thanks!
Anytime, thanks for pointing it out!
no problem, it looks like the plugin uses an older version of elastisch which doesn’t have the upsert, I’ll see if I can unwind all this
Ah, that'd explain it 🙂
yep lol