Main Content

setCheckpointDir

R2026b

Class: matlab.compiler.mlspark.SparkContext
Namespace: matlab.compiler.mlspark

(To be removed) Set the directory under which RDDs are to be checkpointed

matlab.compiler.mlspark.SparkContext.setCheckpointDir will be removed in a future release. There is no replacement functionality. For more information, see Version History.

Syntax

setCheckpointDir(sc,dirName)

Description

setCheckpointDir(sc,dirName) set the directory dirName under which RDDs are to be checkpointed.

Input Arguments

expand all

The SparkContext to use, specified as a SparkContext object.

Directory where the RDDs are to be checkpointed, specified as a character vector enclosed in ''.

Data Types: char | string

Examples

expand all

Set the directory under which RDDs are to be checkpointed.

%% Connect to Spark
sparkProp = containers.Map({'spark.executor.cores'}, {'1'});
conf = matlab.compiler.mlspark.SparkConf('AppName','myApp', ...
                        'Master','local[1]','SparkProperties',sparkProp);
sc = matlab.compiler.mlspark.SparkContext(conf);

%% setCheckpointDir
sc.setCheckpointDir('myDir')

Version History

Introduced in R2016b

collapse all