tamediadigital / librdkafka-d

11 stars 2 forks source link

`produce` does not have timestamp #7

Open 9il opened 7 years ago

9il commented 7 years ago

D wrapper as CPP wrapper successor uses rd_kafka_produce instead of new variadic interface that have timestamp support.

yannick commented 7 years ago

and is it a problem to use producev?

9il commented 7 years ago

No problem

9il commented 7 years ago

It is just porting artifact.

9il commented 7 years ago

The prototype will look like:

ErrorCode produce(Topic topic, int partition, void[] payload,
        const(void)[] key = null, 
        long timestamp = Clock.currTime(UTC()).toUnixTime!long,
        int msgflags = MsgOpt.copy, void* msg_opaque = null)

with default parameter: long timestamp = Clock.currTime(UTC()).toUnixTime!long.

yannick commented 7 years ago

yep please port

yannick commented 7 years ago

@9il is this in now?

9il commented 7 years ago

No, I commented this change because it does not work. Will update examples first, and then try again.