Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ReleasePR azure-resourcemanager-datafactory] [Hub Generated] Publish private branch 'datafactory/zheyuanzhang/lakehouse_swagger' #28237

Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
# Release History

## 1.0.0-beta.14 (Unreleased)
## 1.0.0-beta.1 (2022-04-12)

- Azure Resource Manager DataFactory client library for Java. This package contains Microsoft Azure SDK for DataFactory Management SDK. The Azure Data Factory V2 management API provides a RESTful set of web services that interact with Azure Data Factory V2 services. Package tag package-2018-06. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt).

### Features Added

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ Various documentation is available to help you get started
<dependency>
<groupId>com.azure.resourcemanager</groupId>
<artifactId>azure-resourcemanager-datafactory</artifactId>
<version>1.0.0-beta.13</version>
<version>1.0.0-beta.14</version>
</dependency>
```
[//]: # ({x-version-update-end})
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,13 @@
import com.azure.core.http.HttpPipelineBuilder;
import com.azure.core.http.HttpPipelinePosition;
import com.azure.core.http.policy.AddDatePolicy;
import com.azure.core.http.policy.AddHeadersFromContextPolicy;
import com.azure.core.http.policy.HttpLogOptions;
import com.azure.core.http.policy.HttpLoggingPolicy;
import com.azure.core.http.policy.HttpPipelinePolicy;
import com.azure.core.http.policy.HttpPolicyProviders;
import com.azure.core.http.policy.RequestIdPolicy;
import com.azure.core.http.policy.RetryOptions;
import com.azure.core.http.policy.RetryPolicy;
import com.azure.core.http.policy.UserAgentPolicy;
import com.azure.core.management.http.policy.ArmChallengeAuthenticationPolicy;
Expand Down Expand Up @@ -142,6 +144,19 @@ public static DataFactoryManager authenticate(TokenCredential credential, AzureP
return configure().authenticate(credential, profile);
}

/**
* Creates an instance of DataFactory service API entry point.
*
* @param httpPipeline the {@link HttpPipeline} configured with Azure authentication credential.
* @param profile the Azure profile for client.
* @return the DataFactory service API instance.
*/
public static DataFactoryManager authenticate(HttpPipeline httpPipeline, AzureProfile profile) {
Objects.requireNonNull(httpPipeline, "'httpPipeline' cannot be null.");
Objects.requireNonNull(profile, "'profile' cannot be null.");
return new DataFactoryManager(httpPipeline, profile, null);
}

/**
* Gets a Configurable instance that can be used to create DataFactoryManager with optional configuration.
*
Expand All @@ -160,6 +175,7 @@ public static final class Configurable {
private final List<HttpPipelinePolicy> policies = new ArrayList<>();
private final List<String> scopes = new ArrayList<>();
private RetryPolicy retryPolicy;
private RetryOptions retryOptions;
private Duration defaultPollInterval;

private Configurable() {
Expand Down Expand Up @@ -220,6 +236,19 @@ public Configurable withRetryPolicy(RetryPolicy retryPolicy) {
return this;
}

/**
* Sets the retry options for the HTTP pipeline retry policy.
*
* <p>This setting has no effect, if retry policy is set via {@link #withRetryPolicy(RetryPolicy)}.
*
* @param retryOptions the retry options for the HTTP pipeline retry policy.
* @return the configurable object itself.
*/
public Configurable withRetryOptions(RetryOptions retryOptions) {
this.retryOptions = Objects.requireNonNull(retryOptions, "'retryOptions' cannot be null.");
return this;
}

/**
* Sets the default poll interval, used when service does not provide "Retry-After" header.
*
Expand Down Expand Up @@ -253,7 +282,7 @@ public DataFactoryManager authenticate(TokenCredential credential, AzureProfile
.append("-")
.append("com.azure.resourcemanager.datafactory")
.append("/")
.append("1.0.0-beta.13");
.append("1.0.0-beta.1");
if (!Configuration.getGlobalConfiguration().get("AZURE_TELEMETRY_DISABLED", false)) {
userAgentBuilder
.append(" (")
Expand All @@ -271,10 +300,15 @@ public DataFactoryManager authenticate(TokenCredential credential, AzureProfile
scopes.add(profile.getEnvironment().getManagementEndpoint() + "/.default");
}
if (retryPolicy == null) {
retryPolicy = new RetryPolicy("Retry-After", ChronoUnit.SECONDS);
if (retryOptions != null) {
retryPolicy = new RetryPolicy(retryOptions);
} else {
retryPolicy = new RetryPolicy("Retry-After", ChronoUnit.SECONDS);
}
}
List<HttpPipelinePolicy> policies = new ArrayList<>();
policies.add(new UserAgentPolicy(userAgentBuilder.toString()));
policies.add(new AddHeadersFromContextPolicy());
policies.add(new RequestIdPolicy());
policies
.addAll(
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,124 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
// Code generated by Microsoft (R) AutoRest Code Generator.

package com.azure.resourcemanager.datafactory.fluent.models;

import com.azure.core.annotation.Fluent;
import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.datafactory.models.SecretBase;
import com.fasterxml.jackson.annotation.JsonProperty;

/** AppFigures linked service type properties. */
@Fluent
public final class AppFiguresLinkedServiceTypeProperties {
/*
* The username of the Appfigures source.
*/
@JsonProperty(value = "userName", required = true)
private Object username;

/*
* The password of the AppFigures source.
*/
@JsonProperty(value = "password", required = true)
private SecretBase password;

/*
* The client key for the AppFigures source.
*/
@JsonProperty(value = "clientKey", required = true)
private SecretBase clientKey;

/**
* Get the username property: The username of the Appfigures source.
*
* @return the username value.
*/
public Object username() {
return this.username;
}

/**
* Set the username property: The username of the Appfigures source.
*
* @param username the username value to set.
* @return the AppFiguresLinkedServiceTypeProperties object itself.
*/
public AppFiguresLinkedServiceTypeProperties withUsername(Object username) {
this.username = username;
return this;
}

/**
* Get the password property: The password of the AppFigures source.
*
* @return the password value.
*/
public SecretBase password() {
return this.password;
}

/**
* Set the password property: The password of the AppFigures source.
*
* @param password the password value to set.
* @return the AppFiguresLinkedServiceTypeProperties object itself.
*/
public AppFiguresLinkedServiceTypeProperties withPassword(SecretBase password) {
this.password = password;
return this;
}

/**
* Get the clientKey property: The client key for the AppFigures source.
*
* @return the clientKey value.
*/
public SecretBase clientKey() {
return this.clientKey;
}

/**
* Set the clientKey property: The client key for the AppFigures source.
*
* @param clientKey the clientKey value to set.
* @return the AppFiguresLinkedServiceTypeProperties object itself.
*/
public AppFiguresLinkedServiceTypeProperties withClientKey(SecretBase clientKey) {
this.clientKey = clientKey;
return this;
}

/**
* Validates the instance.
*
* @throws IllegalArgumentException thrown if the instance is not valid.
*/
public void validate() {
if (username() == null) {
throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
"Missing required property username in model AppFiguresLinkedServiceTypeProperties"));
}
if (password() == null) {
throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
"Missing required property password in model AppFiguresLinkedServiceTypeProperties"));
} else {
password().validate();
}
if (clientKey() == null) {
throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
"Missing required property clientKey in model AppFiguresLinkedServiceTypeProperties"));
} else {
clientKey().validate();
}
}

private static final ClientLogger LOGGER = new ClientLogger(AppFiguresLinkedServiceTypeProperties.class);
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,88 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
// Code generated by Microsoft (R) AutoRest Code Generator.

package com.azure.resourcemanager.datafactory.fluent.models;

import com.azure.core.annotation.Fluent;
import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.datafactory.models.SecretBase;
import com.fasterxml.jackson.annotation.JsonProperty;

/** Asana linked service type properties. */
@Fluent
public final class AsanaLinkedServiceTypeProperties {
/*
* The api token for the Asana source.
*/
@JsonProperty(value = "apiToken", required = true)
private SecretBase apiToken;

/*
* The encrypted credential used for authentication. Credentials are
* encrypted using the integration runtime credential manager. Type: string
* (or Expression with resultType string).
*/
@JsonProperty(value = "encryptedCredential")
private Object encryptedCredential;

/**
* Get the apiToken property: The api token for the Asana source.
*
* @return the apiToken value.
*/
public SecretBase apiToken() {
return this.apiToken;
}

/**
* Set the apiToken property: The api token for the Asana source.
*
* @param apiToken the apiToken value to set.
* @return the AsanaLinkedServiceTypeProperties object itself.
*/
public AsanaLinkedServiceTypeProperties withApiToken(SecretBase apiToken) {
this.apiToken = apiToken;
return this;
}

/**
* Get the encryptedCredential property: The encrypted credential used for authentication. Credentials are encrypted
* using the integration runtime credential manager. Type: string (or Expression with resultType string).
*
* @return the encryptedCredential value.
*/
public Object encryptedCredential() {
return this.encryptedCredential;
}

/**
* Set the encryptedCredential property: The encrypted credential used for authentication. Credentials are encrypted
* using the integration runtime credential manager. Type: string (or Expression with resultType string).
*
* @param encryptedCredential the encryptedCredential value to set.
* @return the AsanaLinkedServiceTypeProperties object itself.
*/
public AsanaLinkedServiceTypeProperties withEncryptedCredential(Object encryptedCredential) {
this.encryptedCredential = encryptedCredential;
return this;
}

/**
* Validates the instance.
*
* @throws IllegalArgumentException thrown if the instance is not valid.
*/
public void validate() {
if (apiToken() == null) {
throw LOGGER
.logExceptionAsError(
new IllegalArgumentException(
"Missing required property apiToken in model AsanaLinkedServiceTypeProperties"));
} else {
apiToken().validate();
}
}

private static final ClientLogger LOGGER = new ClientLogger(AsanaLinkedServiceTypeProperties.class);
}
Loading