Skip to content
This repository has been archived by the owner on Apr 2, 2024. It is now read-only.

Heka TcpOutput plugin restarting results in an exception #1958

Open
psawmora opened this issue Jun 29, 2016 · 0 comments
Open

Heka TcpOutput plugin restarting results in an exception #1958

psawmora opened this issue Jun 29, 2016 · 0 comments

Comments

@psawmora
Copy link

I'm trying to add restartability to the TcpOutput plugin and ran into a kind of blocker. I have buffering enabled too. (Using Heka 0.10.0)
I did a basic test implementation by returning a PluginExitError per 100 messages and tried the same by writing to the output runner StopChan. I've set it to restart infinitely.
In both cases, the plugin restarts at first but seems to fail on subsequent restarts with an unmarshalling error from the queue_buffer.go

_

error: StreamOutput stopped: can't get record: can't unmarshal record: proto: wrong wireType = 0 for field Uuid

_

`
The wire type changes time to time.
It seems like the restart somehow corrupts buffer entries or the checkpoint file.

Following is the change I did to the tcp_output.go - Inside the ProcessMessage method

if t.processMessageCount % 200 == 0 && t.processMessageCount != 0 { return NewPluginExitError("Exiting the Plugin: %s", err) }

@psawmora psawmora changed the title Heka TcpOutput plugin with buffer Heka TcpOutput plugin restarting throws an exception Jun 30, 2016
@psawmora psawmora changed the title Heka TcpOutput plugin restarting throws an exception Heka TcpOutput plugin restarting results in an exception Jun 30, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant