Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Auto_flush in multiline codec doesn't work with Kafka input plugin #4771

Closed
ciprianpascu opened this issue Mar 7, 2016 · 10 comments
Closed

Comments

@ciprianpascu
Copy link

No description provided.

@ciprianpascu
Copy link
Author

Auto_flush doesn't happen, although set; configuration something like this:

input {
kafka {
topic_id => "test"
zk_connect => ...
consumer_threads => 1
codec => multiline {
auto_flush_interval => 3
pattern => "TRACE HIGH ACTIVE"
negate => true
what => previous
}
}
}

@ciprianpascu ciprianpascu changed the title Multiline codec doesn't work with Kafka input plugin Auto_flush in multiline codec doesn't work with Kafka input plugin Mar 7, 2016
@jordansissel
Copy link
Contributor

I wouldn't expect it to work well with kafka (based on my expectations of what multiline codec tries to solve). What are you trying to do?

@suyograo
Copy link
Contributor

suyograo commented Mar 8, 2016

multiline is not supported in kafka because messages can come out of order in different partitions. You could use the message key to group all parts of multiline data into one partition, but this is not something we've tested or hear about.

@suyograo suyograo closed this as completed Mar 8, 2016
@ciprianpascu
Copy link
Author

Ok, that's really good to know! I was testing only with one Kafka partition and it worked pretty well, except that the last message from a burst was not handled, because of auto_flush not working. But, if there are issues when using multiple partitions, I will have to find another solution. Thanks!

@suyograo
Copy link
Contributor

suyograo commented Mar 8, 2016

@ciprianpascu I don't know what your source of data is, but if it is files, you can use filebeat which has multiline functionality and can soon send to kafka directly (elastic/beats#942)

@suyograo
Copy link
Contributor

suyograo commented Mar 8, 2016

Also, any beats in general in the future can send to Kafka

@TinLe
Copy link

TinLe commented Mar 8, 2016

According to this, elastic/beats#943, beats can not yet send direct to Kafka.

Has that been implemented and released?

@suyograo
Copy link
Contributor

suyograo commented Mar 8, 2016

@TinLe its been implemented and merged to master in elastic/beats#942. Not yet released. I believe its targeted for the 5.0 release

@TinLe
Copy link

TinLe commented Mar 8, 2016

Nice! :)

@ciprianpascu
Copy link
Author

My source of data is some processes sending logs, but now it seems I won't need the multiline codec, so auto_flush not needed either :).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants