|
|
@@ -111,10 +111,17 @@ end
|
|
|
|
|
|
|
|
|
function kafka_poll(rk::Ptr{Cvoid}, timeout::Integer)
|
|
|
+
|
|
|
+ #println("DOING KAFKA_POLL")
|
|
|
+ #=
|
|
|
return ccall((:rd_kafka_poll, librdkafka), Cint,
|
|
|
(Ptr{Cvoid}, Cint),
|
|
|
rk, timeout)
|
|
|
-
|
|
|
+ =#
|
|
|
+ return @threadcall((:rd_kafka_poll, librdkafka), Cint,
|
|
|
+ (Ptr{Cvoid}, Cint),
|
|
|
+ rk, timeout)
|
|
|
+
|
|
|
end
|
|
|
|
|
|
|
|
|
@@ -247,8 +254,14 @@ end
|
|
|
|
|
|
|
|
|
function kafka_consumer_poll(rk::Ptr{Cvoid}, timeout::Integer)
|
|
|
+ #println("KAFKA_CONSUMER_POLL @threadcall")
|
|
|
+ #=
|
|
|
msg_ptr = ccall((:rd_kafka_consumer_poll, librdkafka), Ptr{CKafkaMessage},
|
|
|
(Ptr{Cvoid}, Cint), rk, timeout)
|
|
|
+ =#
|
|
|
+ msg_ptr = @threadcall((:rd_kafka_consumer_poll, librdkafka), Ptr{CKafkaMessage},
|
|
|
+ (Ptr{Cvoid}, Cint), rk, timeout)
|
|
|
+
|
|
|
if msg_ptr != Ptr{CKafkaMessage}(0)
|
|
|
return msg_ptr
|
|
|
else
|