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

Fix intermittent crash on exit when port already in use - develop #7931

Merged
merged 2 commits into from
Sep 16, 2019

Conversation

heifner
Copy link
Contributor

@heifner heifner commented Sep 16, 2019

Change Description

  • When exception is thrown because of port already in use in net_plugin::plugin_startup, the plugin_shutdown was not called which can lead to issues with destruction of the net_plugin_impl.
  • Ensure plugin_shutdown is called even when plugin_startup doesn't complete in net_plugin and producer_plugin.
  • Changed the fc_elog to elog of port in use so it will always be logged regardless of net_plugin_impl logging settings.
  • Resolves nodeos crashing on occupied listener port of net_plugin #7909

Consensus Changes

  • Consensus Changes

API Changes

  • API Changes

Documentation Additions

  • Documentation Additions

…cause plugin_shutdown not called. Moved the creation of keepalive timer to after acceptor bind which can easily fail if port already in use. Changed fc_elog to elog for port already in use so that it is always logged regardless of net_plugin_impl logger setting. Also move the setup of logger to start of plugin_startup since logging is used within the method.
…artup to ensure proper shutdown on exception
@arhag arhag merged commit 0e81c33 into develop Sep 16, 2019
@arhag arhag deleted the fix-crash-port-dev branch September 16, 2019 21:18
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants