@Override public void open(ExecutionContext ctx) { long numVertices = RheemCollections.getSingle(ctx.getBroadcast("numVertices")); this.initialRank = 1f / numVertices; }
@Override public void open(ExecutionContext ctx) { long numVertices = RheemCollections.getSingle(ctx.getBroadcast("numVertices")); this.minRank = (1 - this.dampingFactor) / numVertices; }
/** * Retrieves the {@link LoopHeadOperator} {@link ExecutionTask} in this instance. This instance must be a * loop head. * * @return the {@link LoopHeadOperator} {@link ExecutionTask} * @see #isLoopHead() */ public ExecutionTask getLoopHeadTask() { assert this.isLoopHead(); return RheemCollections.getSingle(this.getAllTasks()); }
logger.warn( "More than two target operators request only the non-reusable channel {}.", RheemCollections.getSingle(channelDescriptors) );
private PlanTraversal.Callback getFlatAlternativeCallback(AtomicBoolean testOutcome) { return (operator, fromInputSlot, fromOutputSlot) -> { if (operator.isAlternative()) { final OperatorAlternative operatorAlternative = (OperatorAlternative) operator; for (OperatorAlternative.Alternative alternative : operatorAlternative.getAlternatives()) { final Collection<Operator> containedOperators = alternative.getContainedOperators(); if (containedOperators.size() == 1) { Operator containedOperator = RheemCollections.getSingle(containedOperators); if (containedOperator.isAlternative()) { this.logger.warn("Improper alternative {}: contains alternatives.", alternative); testOutcome.set(false); } } else { // We could check if there are singleton Subplans with an OperatorAlternative embedded, // but this would violate the singleton Subplan rule anyway. alternative.traverse(this.getFlatAlternativeCallback(testOutcome)); } } } }; }
break; followableOutput = RheemCollections.getSingle(loopHeadOperator.getLoopBodyOutputs());
repeatOperator.getType().unchecked(), DataSetType.createDefault(Integer.class), ints -> RheemCollections.getSingle(ints) >= numIterations, numIterations );