private void notifyOthersOfSpill() {
if(!context.getOptions().getOption(OOB_SPILL_TRIGGER_ENABLED)) {
return;
}
try {
Payload payload = new Payload(HashAggSpill.newBuilder().setMemoryUse(allocator.getAllocatedMemory()).build());
for(FragmentAssignment a : context.getAssignments()) {
OutOfBandMessage message = new OutOfBandMessage(
context.getFragmentHandle().getQueryId(),
context.getFragmentHandle().getMajorFragmentId(),
a.getMinorFragmentIdList(),
popConfig.getOperatorId(),
context.getFragmentHandle().getMinorFragmentId(),
payload);
context.getTunnelProvider().getExecTunnel(a.getAssignment()).sendOOBMessage(message);
}
oobSends++;
} catch(Exception ex) {
logger.warn("Failure while attempting to notify others of spilling.", ex);
}
}