private static OperatorProfile findOperatorProfileWithId(MinorFragmentProfile minorFragmentProfile, final int id) { return FluentIterable.from(minorFragmentProfile.getOperatorProfileList()).firstMatch(new Predicate<OperatorProfile>() { @Override public boolean apply(OperatorProfile input) { return input.getOperatorId() == id; } }).get(); } private static long findMetric(OperatorProfile operatorProfile, final int id) {
for (final MinorFragmentProfile minor : minors) { final List<OperatorProfile> ops = new ArrayList<>(minor.getOperatorProfileList()); Collections.sort(ops, Comparators.operatorId); for (final OperatorProfile op : ops) {
private long getRowsProcessed(MinorFragmentProfile profile) { long maxRecords = 0; for (OperatorProfile operatorProfile : profile.getOperatorProfileList()) { long records = 0; for (StreamProfile inputProfile :operatorProfile.getInputProfileList()) { if (inputProfile.hasRecords()) { records += inputProfile.getRecords(); } } maxRecords = Math.max(maxRecords, records); } return maxRecords; }
if (minorFragmentProfile.getOperatorProfileList() == null) { continue; for (OperatorProfile operatorProfile : minorFragmentProfile.getOperatorProfileList()) { totalTimeInMillis += toMillis(operatorProfile.getProcessNanos() + operatorProfile.getWaitNanos() + operatorProfile.getSetupNanos()); final CoreOperatorType operatorType = CoreOperatorType.valueOf(operatorProfile.getOperatorType());
final ArrayList<OperatorProfile> ops = new ArrayList<>(minor.getOperatorProfileList()); List<OperatorProfile> operators = minor.getOperatorProfileList(); long totalNanos = 0; for (OperatorProfile op : operators) {
for(com.dremio.exec.proto.UserBitShared.OperatorProfile operatorProfile : message.getOperatorProfileList()) output.writeObject(4, operatorProfile, com.dremio.exec.proto.SchemaUserBitShared.OperatorProfile.WRITE, true);
QueryProfile profile = grabber.getProfile(); Optional<OperatorProfile> scanProfile = FluentIterable.from(profile.getFragmentProfile(0).getMinorFragmentProfile(0).getOperatorProfileList()) .firstMatch(new Predicate<OperatorProfile>() { @Override