Examples of ExecutionPhase


Examples of com.asakusafw.yaess.core.ExecutionPhase

    private static JsonObject analyzeJobflow(FlowScript flowScript) {
        assert flowScript != null;
        JsonArray phases = new JsonArray();
        for (Map.Entry<ExecutionPhase, Set<ExecutionScript>> entry : flowScript.getScripts().entrySet()) {
            ExecutionPhase phase = entry.getKey();
            if (entry.getValue().isEmpty() == false
                    || phase == ExecutionPhase.SETUP
                    || phase == ExecutionPhase.CLEANUP) {
                phases.add(new JsonPrimitive(phase.getSymbol()));
            }
        }
        JsonObject jobflow = new JsonObject();
        jobflow.addProperty("id", flowScript.getId());
        jobflow.add("blockers", toJsonArray(flowScript.getBlockerIds()));
View Full Code Here

Examples of com.asakusafw.yaess.core.ExecutionPhase

    private void verifyPhaseOrder(List<Record> results) {
        Map<String, List<Record>> partitions = flowPartition(results);
        for (Map.Entry<String, List<Record>> entry : partitions.entrySet()) {
            String flowId = entry.getKey();
            List<Record> records = entry.getValue();
            ExecutionPhase last = ExecutionPhase.SETUP;
            for (Record r : records) {
                ExecutionPhase phase = r.context.getPhase();
                assertThat(flowId, phase, greaterThanOrEqualTo(last));
                last = phase;
            }
        }
    }
View Full Code Here

Examples of org.graphlab.ExecutionPhase

        MessageIds.registerDecoder(MessageIds.EXECUTEPHASE, new GraphLabMessageDecoder() {
            @Override
            public GraphLabMessage decode(ChannelHandlerContext ctx, Channel channel, ChannelBuffer buf) {
                if (buf.readableBytes() < 12) return null;

                ExecutionPhase phase = new ExecutionPhase(buf.readInt());
                int fromVertex = buf.readInt();
                int toVertex = buf.readInt();
                return new ExecutePhaseMessage(phase, fromVertex, toVertex);
            }
        });
View Full Code Here

Examples of org.graphlab.ExecutionPhase

    public static void register() {
        MessageIds.registerDecoder(MessageIds.FINISHED_PHASE, new GraphLabMessageDecoder() {
            @Override
            public GraphLabMessage decode(ChannelHandlerContext ctx, Channel channel, ChannelBuffer buf) {
                if (buf.readableBytes() < 12) return null;
                ExecutionPhase phase = new ExecutionPhase(buf.readInt());
                int fromVertex = buf.readInt();
                int toVertex = buf.readInt();
                return new FinishedPhaseMessage(phase, fromVertex, toVertex);
            }
        });
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.