GithubHelp home page GithubHelp logo

Comments (4)

Uthar avatar Uthar commented on July 24, 2024

I can put in (sleep 5) around the assign and seek calls, and then it works, but it feels hacky. Is there a way to explicitly sync?

from cl-rdkafka.

Uthar avatar Uthar commented on July 24, 2024

Also, why does (sleep 5) work, but (sleep 4), (sleep 3) does not?

from cl-rdkafka.

Uthar avatar Uthar commented on July 24, 2024

Seems related to this: https://github.com/edenhill/librdkafka/wiki/Manually-setting-the-consumer-start-offset

Currently this API doesn't allow to set the offset in seek, right?

For me, this works:

--- src/high-level/consumer.lisp
+++ src/high-level/consumer.lisp
@@ -400,7 +400,7 @@
   (with-slots (rd-kafka-consumer) consumer
     (with-toppar-list
         toppar-list
-        (alloc-toppar-list partitions :topic #'car :partition #'cdr)
+        (alloc-toppar-list partitions :topic #'first :partition #'second :offset #'third)
       (let ((err (cl-rdkafka/ll:rd-kafka-assign rd-kafka-consumer toppar-list)))
         (unless (eq err 'cl-rdkafka/ll:rd-kafka-resp-err-no-error)
           (error (make-rdkafka-error err)))))))

Diff finished.  Wed Oct 26 13:31:12 2022

from cl-rdkafka.

SahilKang avatar SahilKang commented on July 24, 2024

Thanks for pointing this out, I've released v1.2.0 which adds offset support to the kf:assign and kf:assignment methods

from cl-rdkafka.

Related Issues (11)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.