Main Content

parallel.cluster.Hadoop

R2026b

Hadoop cluster for mapreducer, mapreduce and tall arrays

Description

A parallel.cluster.Hadoop object provides access to a cluster for configuring mapreducer, mapreduce, and tall arrays.

Creation

Use the parallel.cluster.Hadoop function to create a Hadoop® cluster object.

Description

hadoopCluster = parallel.cluster.Hadoop creates a parallel.cluster.Hadoop object representing the Hadoop cluster.

You use the resulting object as input to the mapreduce and mapreducer functions, for specifying the Hadoop cluster as the parallel execution environment for tall arrays and mapreduce.

example

hadoopCluster = parallel.cluster.Hadoop(PropertyName=Value) specifies one or more property values using name-value arguments. For example, parallel.cluster.Hadoop(HadoopInstallFolder='/host/hadoop-install'); sets the Hadoop install folder.

Output Arguments

expand all

Hadoop cluster, returned as a parallel.cluster.Hadoop object.

Properties

expand all

Folders to add to MATLAB search path of workers, specified as a character vector, string or string array, or cell array of character vectors.

When you offload computations to workers, any files that the client needs for computations must also be available on workers. By default, the client attempts to detect and attach these files. To turn off automatic detection, set the AutoAttachFiles property to false. If the software cannot find all the files, or if sending files from client to worker is slow, use one of these options.

  • If the files are in a folder that is not accessible on the workers, set the AttachedFiles property. The cluster copies each file you specify from the client to the workers.

  • If the files are in a folder that is accessible on the workers, you can set the AdditionalPaths property instead. Use the AdditionalPaths property to add paths to the MATLAB search path for each worker and avoid copying files unnecessarily from the client to the workers.

Files and folders sent to workers during a mapreduce call, specified as a character vector, string or string array, or cell array of character vectors

When you offload computations to workers, any files that the client needs for computations must also be available on workers. By default, the client attempts to detect and attach these files. To turn off automatic detection, set the AutoAttachFiles property to false. If the software cannot find all the files, or if sending files from client to worker is slow, use one of these options.

  • If the files are in a folder that is not accessible on the workers, set the AttachedFiles property. The cluster copies each file you specify from the client to the workers.

  • If the files are in a folder that is accessible on the workers, you can set the AdditionalPaths property instead. Use the AdditionalPaths property to add paths to the MATLAB search path for each worker and avoid copying files unnecessarily from the client to the workers.

Specify whether to automatically detect and attach files on the client.

Data Types: logical

Path to MATLAB for workers, specified as a character vector. This points to the installation of MATLAB Parallel Server™ for the workers, whether local to each machine or on a network share.

Path to Hadoop application configuration file, specified as a character vector.

Path to Hadoop installation on the local machine, specified as a character vector. If this property is not set, the default is the value specified by the environment variable HADOOP_PREFIX, or if that is not set, then HADOOP_HOME.

Map of Hadoop name-value property pairs to be given to the Hadoop cluster.

HadoopProperties allows you to override configuration properties for Hadoop. See the list of properties in the Hadoop documentation.

License number to use with online licensing.

Specify whether the Hadoop cluster uses online licensing.

Data Types: logical

Path to Spark installation on worker machines, specified as a character vector. If this property is not set, the default is the value specified by the environment variable SPARK_PREFIX, or if that is not set, then SPARK_HOME.

The SparkInstallFolder is by default set to the SPARK_HOME environment variable. This is required for tall array evaluation on Hadoop (but not for mapreduce). For a correctly configured cluster, you only need to set the installation folder.

Map of Spark name-value property pairs to be given to the Spark enabled Hadoop cluster.

SparkProperties allows you to override configuration properties for Spark. See the list of properties in the Spark documentation.

Object Functions

mapreduceProgramming technique for analyzing data sets that do not fit in memory
mapreducerDefine parallel execution environment for mapreduce and tall arrays

Examples

collapse all

Create and use a parallel.cluster.Hadoop object to set a Hadoop cluster as the mapreduce parallel execution environment.

hadoopCluster = parallel.cluster.Hadoop(HadoopInstallFolder='/host/hadoop-install');
mr = mapreducer(hadoopCluster);

This example shows how to create and use a parallel.cluster.Hadoop object to set a Hadoop cluster as the tall array parallel execution environment.

hadoopCluster = parallel.cluster.Hadoop(...
    HadoopInstallFolder='/host/hadoop-install', ...
    SparkInstallFolder='/host/spark-install');
mr = mapreducer(hadoopCluster);

More About

expand all

Version History

Introduced in R2014b