Java Code Examples for org.apache.tez.dag.api.OutputDescriptor#setUserPayload()
The following examples show how to use
org.apache.tez.dag.api.OutputDescriptor#setUserPayload() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: TestDAGRecovery2.java From incubator-tez with Apache License 2.0 | 5 votes |
@Test(timeout=120000) public void testFailingCommitter() throws Exception { DAG dag = SimpleVTestDAG.createDAG("FailingCommitterDAG", null); OutputDescriptor od = new OutputDescriptor(MultiAttemptDAG.NoOpOutput.class.getName()); od.setUserPayload(new MultiAttemptDAG.FailingOutputCommitter.FailingOutputCommitterConfig(true) .toUserPayload()); dag.getVertex("v3").addOutput("FailingOutput", od, MultiAttemptDAG.FailingOutputCommitter.class); runDAGAndVerify(dag, State.FAILED); }
Example 2
Source File: TestDAGRecovery2.java From tez with Apache License 2.0 | 5 votes |
@Test(timeout=120000) public void testFailingCommitter() throws Exception { DAG dag = SimpleVTestDAG.createDAG("FailingCommitterDAG", null); OutputDescriptor od = OutputDescriptor.create(MultiAttemptDAG.NoOpOutput.class.getName()); od.setUserPayload(UserPayload.create(ByteBuffer.wrap( new MultiAttemptDAG.FailingOutputCommitter.FailingOutputCommitterConfig(true) .toUserPayload()))); OutputCommitterDescriptor ocd = OutputCommitterDescriptor.create( MultiAttemptDAG.FailingOutputCommitter.class.getName()); dag.getVertex("v3").addDataSink("FailingOutput", DataSinkDescriptor.create(od, ocd, null)); runDAGAndVerify(dag, State.FAILED); }
Example 3
Source File: TestOutput.java From tez with Apache License 2.0 | 5 votes |
public static OutputDescriptor getOutputDesc(UserPayload payload) { OutputDescriptor desc = OutputDescriptor.create(TestOutput.class.getName()); if (payload != null) { desc.setUserPayload(payload); } return desc; }