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

SOLR-14940: Add ability to remove SolrCore.closeHooks. Keep reference… #1997

Closed
wants to merge 4 commits into from

Conversation

anverus
Copy link

@anverus anverus commented Oct 16, 2020

…s to CloseHooks in ReplicationHandler and remove them on ReplicationHandler.shutdown()

Description

Please provide a short description of the changes you're making with this pull request.

Solution

Please provide a short description of the approach taken to implement your solution.

Tests

Please describe the tests you've developed or run to confirm this patch implements the feature or solves the problem.

Checklist

Please review the following and check all that apply:

  • I have reviewed the guidelines for How to Contribute and my code conforms to the standards described there to the best of my ability.
  • I have created a Jira issue and added the issue ID to my pull request title.
  • I have given Solr maintainers access to contribute to my PR branch. (optional but recommended)
  • I have developed this patch against the master branch.
  • I have run ./gradlew check.
  • I have added tests for my changes.
  • I have added documentation for the Ref Guide (for Solr changes only).

…s to CloseHooks in ReplicationHandler and remove them on ReplicationHandler.shutdown()
…it and moved removeCloseHooks in ReplicationHandler.shutdown to run after execution of close hooks
Comment on lines +1415 to +1418
startShutdownHook.preClose(core);
startShutdownHook.postClose(core);
finishShutdownHook.preClose(core);
finishShutdownHook.postClose(core);
Copy link
Author

@anverus anverus Oct 16, 2020

Choose a reason for hiding this comment

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

Order of these calls copies order of execution of instructions in original shutdown method, while the correct order seems to be

    startShutdownHook.preClose(core);
    finishShutdownHook.preClose(core);
    startShutdownHook.postClose(core);
    finishShutdownHook.postClose(core);

madrob pushed a commit that referenced this pull request Oct 27, 2020
…Hooks

* Added ability to remove SolrCore.closeHooks
* Keep references to CloseHooks in ReplicationHandler and remove them on ReplicationHandler.shutdown()

closes #1997
@madrob madrob closed this in 6d00843 Oct 27, 2020
msfroh pushed a commit to msfroh/lucene-solr that referenced this pull request Nov 18, 2020
…Hooks

* Added ability to remove SolrCore.closeHooks
* Keep references to CloseHooks in ReplicationHandler and remove them on ReplicationHandler.shutdown()

closes apache#1997
epugh pushed a commit to epugh/lucene-solr-1 that referenced this pull request Jan 15, 2021
…Hooks

* Added ability to remove SolrCore.closeHooks
* Keep references to CloseHooks in ReplicationHandler and remove them on ReplicationHandler.shutdown()

closes apache#1997
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.

5 participants