-
-
Notifications
You must be signed in to change notification settings - Fork 54
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
Support raw InfluxDB line protocol as an input format #40
Comments
Oh wow, that's a good idea. 😃 |
I've just tried that, while running kafka-influxdb in -vvv mode. The highwater_offset seems to get updated and by reading the logs I guess messages get consumed (see this gist). But I don't see the data in InfluxDB, and no error logs get generated by the later. |
So, yeah it looks like it's reading messages from Kafka (offset is increasing in your output).
class Encoder(object):
@staticmethod
def encode(msg):
"""
Don't change the message at all
:param msg:
"""
return [msg] (i.e. add brackets around msg because the return value should actually be a list of messages.) |
OK, thanks a lot, I got it to work :)
I also had to change the retention_policy to "autogen" (new name for the default retention_policy, instead of "default"). It would be nice to advertise the fact that raw InfluxDB line protocol is supported as a feature on the README :) |
About No.1: You're right. That should raise an error. |
If replacing collectd with telegraf, we can directly have data in InfluxDB line protocol format.
See: telegraf output formats
It could be quite nice to have an encoder for this use-case, or even kafka-influxdb to have a "transparent mode", with the mashalling disabled.
The text was updated successfully, but these errors were encountered: