shanthoosh commented on a change in pull request #1010: SAMZA-2176: Ignore the
keys with serialized null values from the coordinator stream.
URL: https://github.com/apache/samza/pull/1010#discussion_r279089400
##########
File path:
samza-core/src/main/java/org/apache/samza/container/LocalityManager.java
##########
@@ -63,9 +64,11 @@ public LocalityManager(MetadataStore metadataStore) {
metadataStore.all().forEach((containerId, valueBytes) -> {
if (valueBytes != null) {
String locationId = valueSerde.fromBytes(valueBytes);
- Map<String, String> values = new HashMap<>();
- values.put(SetContainerHostMapping.HOST_KEY, locationId);
- allMappings.put(containerId, values);
+ if (StringUtils.isNotBlank(locationId)) {
Review comment:
I thought of doing this change before sending this patch out for review.
Since this is a critical bug-fix, I didn't want to couple it with a
refactor/cleanup. If it's acceptable then I will do it in a follow-up
[JIRA](https://issues.apache.org/jira/browse/SAMZA-2177).
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services