ravipesala commented on a change in pull request #3322: [WIP]Fixed NPE in 
Concurrent query
URL: https://github.com/apache/carbondata/pull/3322#discussion_r302135176
 
 

 ##########
 File path: 
core/src/main/java/org/apache/carbondata/core/datastore/block/SegmentPropertiesAndSchemaHolder.java
 ##########
 @@ -204,6 +204,9 @@ public void invalidate(AbsoluteTableIdentifier 
absoluteTableIdentifier) {
           .getTableUniqueName()
           
.equals(absoluteTableIdentifier.getCarbonTableIdentifier().getTableUniqueName()))
 {
         SegmentIdAndSegmentPropertiesIndexWrapper value = entry.getValue();
+        synchronized (deleteIndexToDeleteTimestampMapping) {
+          
deleteIndexToDeleteTimestampMapping.remove(value.segmentPropertiesIndex);
+        }
         // remove from the reverse mapping map
         
indexToSegmentPropertiesWrapperMapping.remove(value.getSegmentPropertiesIndex());
         segmentPropertiesWrappersToBeRemoved.add(segmentPropertiesWrapper);
 
 Review comment:
   Isn't requiredto move this also to synchronize?

----------------------------------------------------------------
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

Reply via email to