GitHub user jfim opened a pull request:
https://github.com/apache/helix/pull/75
Ignore instances with no instance configuration
Ignore instances with no instance configuration when fetching the list
of instances that have a specific tag.
The deletion order in ZKHelixAdmin#dropInstance deletes the instance
configuration before deleting the instance itself. If this is
interrupted midway, the instance configuration is deleted but the
instance is present in the list of instances.
When fetching the list of instances with a given tag, this means that
if an instance has its configuration missing, the instance
configuration will be null and the loop will exit with NPE. This patch
adds a null check to avoid aborting the loop.
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/jfim/helix npe-in-getinstanceswithtag
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/helix/pull/75.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #75
----
commit f3ff7c0882e622d258593d0a798fd08b7d1962ba
Author: Jean-Francois Im <[email protected]>
Date: 2017-03-08T22:21:45Z
Ignore instances with no instance configuration
Ignore instances with no instance configuration when fetching the list
of instances that have a specific tag.
The deletion order in ZKHelixAdmin#dropInstance deletes the instance
configuration before deleting the instance itself. If this is
interrupted midway, the instance configuration is deleted but the
instance is present in the list of instances.
When fetching the list of instances with a given tag, this means that
if an instance has its configuration missing, the instance
configuration will be null and the loop will exit with NPE. This patch
adds a null check to avoid aborting the loop.
----
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---