Github user arina-ielchiieva commented on a diff in the pull request:
https://github.com/apache/drill/pull/1105#discussion_r169048352
--- Diff:
exec/java-exec/src/main/java/org/apache/drill/exec/physical/impl/partitionsender/PartitionSenderRootExec.java
---
@@ -348,9 +348,12 @@ public void close() throws Exception {
logger.debug("Partition sender stopping.");
super.close();
ok = false;
- if (partitioner != null) {
- updateAggregateStats();
- partitioner.clear();
+
+ synchronized (this) {
--- End diff --
1. Should partitioner be volatile?
2. Should we check if partitioner is not null before synchronization as
well (DCL)?
---