azure-docs-sdk-java/docs-ref-services/datalakeanalytics.md

2.5 KiB

title description keywords author ms.author manager ms.date ms.topic ms.prod ms.technology ms.devlang ms.service
Azure Data Lake Analytics libraries for Java Reference documentation for the Java Data Lake Analytics libraries Azure, Java, SDK, API, big data, data lake rloutlaw routlaw douge 06/21/2017 article azure azure java data-lake-store

Azure Data Lake Analytics libraries for Java

Overview

Run big data analysis jobs that scale to massive data sets with Azure Data Lake Analytics.

To get started with Azure Data Lake Analytics, see Get started with Azure Data Lake Analytics using Java SDK.

Management API

Use the management API to manage Data Lake Analytics accounts, jobs, policies, and catalogs.

Add a dependency to your Maven pom.xml file to use the management API in your project.

<dependency>
    <groupId>com.microsoft.azure</groupId>
    <artifactId>azure-mgmt-datalake-analytics</artifactId>
    <version>1.0.0-beta1.3</version>
</dependency>

Example

Submit a new U-SQL job to Data Lake Analytics.

// authenticate with service principal credentials
ApplicationTokenCredentials creds = new ApplicationTokenCredentials(_clientId, _tenantId, _clientSecret, null);
DataLakeAnalyticsJobManagementClient adlaJobClient = new DataLakeAnalyticsJobManagementClientImpl(creds);

// set up job parameters
UUID jobId = java.util.UUID.randomUUID();
USqlJobProperties properties = new USqlJobProperties();
properties.setScript("@input =  EXTRACT Data string FROM \"/input1.csv\" USING Extractors.Csv(); OUTPUT @input TO @\"/output1.csv\" USING Outputters.Csv();");
JobInformation parameters = new JobInformation();
parameters.setName("testJob");
parameters.setJobId(jobId);
parameters.setType(JobType.USQL);
parameters.setProperties(properties);

// create the job
JobInformation jobInfo = adlaJobClient.getJobOperations().create(accountName, jobId, parameters).getBody();

[!div class="nextstepaction"] Explore the Management APIs

Samples

Azure Data Lake Analytics using Java SDK

View the complete list of Azure Data Lake Analytics samples.