Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Deferring dataset creation in prepareRun will require adding a new method to BatchSinkContextBatchContext

Code Block
@Beta
public interface BatchContext extends DatasetContext, TransformContext {

// new method
void createDataset(String datasetName, String typeName, DatasetProperties properties);
 
// existing methods
long getLogicalStartTime();

/**
 * Returns runtime arguments of the Batch Job.
 *
 * @return runtime arguments of the Batch Job.
 */
Map<String, String> getRuntimeArguments();

/**
 * Updates an entry in the runtime arguments.
 *
 * @param key key to update
 * @param value value to update to
 * @param overwrite if {@code true} and if the key exists in the runtime arguments, it will get overwritten to
 *                  the given value; if {@code false}, the existing value of the key won't get updated.
 */
void setRuntimeArgument(String key, String value, boolean overwrite);

/**
 * Returns the hadoop job.
 * @deprecated this method will be removed.
 */
@Deprecated
<T> T getHadoopJob();
...
}

...