@Override public void onSuccess() throws DataSetException { if (dataset instanceof DatasetOutputCommitter) { ((DatasetOutputCommitter) dataset).onSuccess(); } }
@Override public void onSuccess() throws DataSetException { if (dataset instanceof DatasetOutputCommitter) { ((DatasetOutputCommitter) dataset).onSuccess(); } }
/** * Calls onSuccess on the DatasetOutputCommitters. If any throws an exception, the exception is propagated * immediately. #abortJob will then be called, which is responsible for calling onFinish on each of them. */ private void commitOutputs(Map<String, DatasetOutputCommitter> datasetOutputCommiters) { for (Map.Entry<String, DatasetOutputCommitter> datasetOutputCommitter : datasetOutputCommiters.entrySet()) { try { datasetOutputCommitter.getValue().onSuccess(); } catch (Exception e) { LOG.error(String.format("Error from onSuccess method of output dataset %s.", datasetOutputCommitter.getKey()), e); throw e; } } }
/** * Calls onSuccess on the DatasetOutputCommitters. If any throws an exception, the exception is propagated * immediately. #abortJob will then be called, which is responsible for calling onFinish on each of them. */ private void commitOutputs(Map<String, DatasetOutputCommitter> datasetOutputCommiters) { for (Map.Entry<String, DatasetOutputCommitter> datasetOutputCommitter : datasetOutputCommiters.entrySet()) { try { datasetOutputCommitter.getValue().onSuccess(); } catch (Exception e) { LOG.error(String.format("Error from onSuccess method of output dataset %s.", datasetOutputCommitter.getKey()), e); throw e; } } }