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

heka_tcp output plugin terminates if server is not listening anymore #65

Closed
bbinet opened this issue Jan 12, 2017 · 4 comments
Closed
Assignees

Comments

@bbinet
Copy link
Contributor

bbinet commented Jan 12, 2017

Today I noticed that if I temporarily stop my heka_tcp input plugin, then the heka_tcp ouput plugin that were sending data to that stopped plugin will terminate quickly with the following error in logs:

1484245022748499356 [error] output.heka_tcp terminated: process_message() instruction_limit exceeded

Note that my heka_tcp input/output plugin are configured with ssl support.

@trink trink self-assigned this Jan 12, 2017
@trink
Copy link
Contributor

trink commented Jan 12, 2017

I had one hang (possibly in socket.write(), process_message never returned) under very similar conditions. I was working with Ops and we were able to reproduce it without SSL but got no further. I am assuming this failure is related and expect to find something that stepped on memory (as there is nothing that would exhaust the instruction limit in that plugin).

@trink trink added this to the Sprint Jan23-Feb06 milestone Jan 12, 2017
@bbinet
Copy link
Contributor Author

bbinet commented Jan 13, 2017

In fact it actually enters an endless loop because client:sendreturns error "Broken pipe", so the plugin tries a new send_message(msg, i):
https://github.com/mozilla-services/lua_sandbox_extensions/blob/master/socket/sandboxes/heka/output/heka_tcp.lua#L70

Patch to come.

bbinet added a commit to bbinet/lua_sandbox_extensions that referenced this issue Jan 13, 2017
@bbinet
Copy link
Contributor Author

bbinet commented Jan 13, 2017

This is addressed in pull request #66

@trink
Copy link
Contributor

trink commented Jan 13, 2017

Good catch, I just looked at our prod config and the instruction_limit was set to zero so that explains our hang as it was just infinitely looping.

bbinet added a commit to bbinet/lua_sandbox_extensions that referenced this issue Jan 13, 2017
bbinet added a commit to bbinet/lua_sandbox_extensions that referenced this issue Jan 13, 2017
@trink trink closed this as completed in #68 Jan 13, 2017
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

2 participants