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

plugin: Ensure RPC passthrough calls are terminated when plugin dies #3639

Merged
merged 1 commit into from
Apr 14, 2020

Conversation

cdecker
Copy link
Member

@cdecker cdecker commented Apr 9, 2020

We now track all pending RPC passthrough calls, and terminate them with an
error if the plugin dies.

Changelog-Fixed: JSON-RPC: Pending RPC method calls are now terminated if the handling plugin exits prematurely.

Closes #3496

@cdecker cdecker requested a review from niftynei April 9, 2020 15:39
@darosior
Copy link
Collaborator

darosior commented Apr 9, 2020

ut ACK 256f065

lightningd/plugin.c Outdated Show resolved Hide resolved
Copy link
Contributor

@rustyrussell rustyrussell left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Trivial things only; thanks for doing this, it's a real improvement.

common/jsonrpc_errors.h Outdated Show resolved Hide resolved
We now track all pending RPC passthrough calls, and terminate them with an
error if the plugin dies.

Changelog-Fixed: JSON-RPC: Pending RPC method calls are now terminated if the handling plugin exits prematurely.
@cdecker
Copy link
Member Author

cdecker commented Apr 13, 2020

Addressed all comments, renamed the error name and number to PLUGIN_TERMINATED and -4 so it is a bit nicer now.

Copy link
Contributor

@rustyrussell rustyrussell left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ack 4f7bd67

@rustyrussell rustyrussell merged commit 197a144 into ElementsProject:master Apr 14, 2020
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

Successfully merging this pull request may close these issues.

Hooks abandon their payloads when plugins stopped
4 participants