Skip to content

Commit ff6daa2

Browse files
author
SDKAuto
committed
CodeGen from PR 3565 in test-repo-billy/azure-rest-api-specs
Merge a9bb0872a08f6ed791ffe51d2e81a92b93d5825c into 53ed59041775b47e32970efc8eea6dc7c3b5de05
1 parent 098ec58 commit ff6daa2

File tree

1,374 files changed

+6089
-42439
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,374 files changed

+6089
-42439
lines changed

sdk/datafactory/azure-resourcemanager-datafactory/CHANGELOG.md

+3-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
# Release History
22

3-
## 1.0.0-beta.31 (Unreleased)
3+
## 1.0.0-beta.1 (2024-12-04)
4+
5+
- 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).
46

57
### Features Added
68

sdk/datafactory/azure-resourcemanager-datafactory/README.md

+22-16
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ Various documentation is available to help you get started
3232
<dependency>
3333
<groupId>com.azure.resourcemanager</groupId>
3434
<artifactId>azure-resourcemanager-datafactory</artifactId>
35-
<version>1.0.0-beta.30</version>
35+
<version>1.0.0-beta.31</version>
3636
</dependency>
3737
```
3838
[//]: # ({x-version-update-end})
@@ -72,30 +72,33 @@ See [API design][design] for general introduction on design and key concepts on
7272

7373
```java
7474
// storage account
75-
StorageAccount storageAccount = storageManager.storageAccounts().define(STORAGE_ACCOUNT)
75+
StorageAccount storageAccount = storageManager.storageAccounts()
76+
.define(STORAGE_ACCOUNT)
7677
.withRegion(REGION)
7778
.withExistingResourceGroup(resourceGroup)
7879
.create();
7980
final String storageAccountKey = storageAccount.getKeys().iterator().next().value();
80-
final String connectionString = getStorageConnectionString(STORAGE_ACCOUNT, storageAccountKey, storageManager.environment());
81+
final String connectionString
82+
= getStorageConnectionString(STORAGE_ACCOUNT, storageAccountKey, storageManager.environment());
8183

8284
// container
8385
final String containerName = "adf";
84-
storageManager.blobContainers().defineContainer(containerName)
86+
storageManager.blobContainers()
87+
.defineContainer(containerName)
8588
.withExistingStorageAccount(resourceGroup, STORAGE_ACCOUNT)
8689
.withPublicAccess(PublicAccess.NONE)
8790
.create();
8891

8992
// blob as input
90-
BlobClient blobClient = new BlobClientBuilder()
91-
.connectionString(connectionString)
93+
BlobClient blobClient = new BlobClientBuilder().connectionString(connectionString)
9294
.containerName(containerName)
9395
.blobName("input/data.txt")
9496
.buildClient();
9597
blobClient.upload(BinaryData.fromString("data"));
9698

9799
// data factory
98-
Factory dataFactory = manager.factories().define(DATA_FACTORY)
100+
Factory dataFactory = manager.factories()
101+
.define(DATA_FACTORY)
99102
.withRegion(REGION)
100103
.withExistingResourceGroup(resourceGroup)
101104
.create();
@@ -106,15 +109,16 @@ connectionStringProperty.put("type", "SecureString");
106109
connectionStringProperty.put("value", connectionString);
107110

108111
final String linkedServiceName = "LinkedService";
109-
manager.linkedServices().define(linkedServiceName)
112+
manager.linkedServices()
113+
.define(linkedServiceName)
110114
.withExistingFactory(resourceGroup, DATA_FACTORY)
111-
.withProperties(new AzureStorageLinkedService()
112-
.withConnectionString(connectionStringProperty))
115+
.withProperties(new AzureStorageLinkedService().withConnectionString(connectionStringProperty))
113116
.create();
114117

115118
// input dataset
116119
final String inputDatasetName = "InputDataset";
117-
manager.datasets().define(inputDatasetName)
120+
manager.datasets()
121+
.define(inputDatasetName)
118122
.withExistingFactory(resourceGroup, DATA_FACTORY)
119123
.withProperties(new AzureBlobDataset()
120124
.withLinkedServiceName(new LinkedServiceReference().withReferenceName(linkedServiceName))
@@ -125,7 +129,8 @@ manager.datasets().define(inputDatasetName)
125129

126130
// output dataset
127131
final String outputDatasetName = "OutputDataset";
128-
manager.datasets().define(outputDatasetName)
132+
manager.datasets()
133+
.define(outputDatasetName)
129134
.withExistingFactory(resourceGroup, DATA_FACTORY)
130135
.withProperties(new AzureBlobDataset()
131136
.withLinkedServiceName(new LinkedServiceReference().withReferenceName(linkedServiceName))
@@ -135,14 +140,15 @@ manager.datasets().define(outputDatasetName)
135140
.create();
136141

137142
// pipeline
138-
PipelineResource pipeline = manager.pipelines().define("CopyBlobPipeline")
143+
PipelineResource pipeline = manager.pipelines()
144+
.define("CopyBlobPipeline")
139145
.withExistingFactory(resourceGroup, DATA_FACTORY)
140-
.withActivities(Collections.singletonList(new CopyActivity()
141-
.withName("CopyBlob")
146+
.withActivities(Collections.singletonList(new CopyActivity().withName("CopyBlob")
142147
.withSource(new BlobSource())
143148
.withSink(new BlobSink())
144149
.withInputs(Collections.singletonList(new DatasetReference().withReferenceName(inputDatasetName)))
145-
.withOutputs(Collections.singletonList(new DatasetReference().withReferenceName(outputDatasetName)))))
150+
.withOutputs(
151+
Collections.singletonList(new DatasetReference().withReferenceName(outputDatasetName)))))
146152
.create();
147153

148154
// run pipeline

sdk/datafactory/azure-resourcemanager-datafactory/SAMPLE.md

-85
Original file line numberDiff line numberDiff line change
@@ -52,13 +52,11 @@
5252

5353
## Factories
5454

55-
- [ConfigureFactoryRepo](#factories_configurefactoryrepo)
5655
- [CreateOrUpdate](#factories_createorupdate)
5756
- [Delete](#factories_delete)
5857
- [GetByResourceGroup](#factories_getbyresourcegroup)
5958
- [GetDataPlaneAccess](#factories_getdataplaneaccess)
6059
- [GetGitHubAccessToken](#factories_getgithubaccesstoken)
61-
- [List](#factories_list)
6260
- [ListByResourceGroup](#factories_listbyresourcegroup)
6361
- [Update](#factories_update)
6462

@@ -121,10 +119,6 @@
121119
- [Get](#managedvirtualnetworks_get)
122120
- [ListByFactory](#managedvirtualnetworks_listbyfactory)
123121

124-
## Operations
125-
126-
- [List](#operations_list)
127-
128122
## PipelineRuns
129123

130124
- [Cancel](#pipelineruns_cancel)
@@ -1161,41 +1155,6 @@ public final class ExposureControlQueryFeatureValuesByFactorySamples {
11611155
}
11621156
```
11631157

1164-
### Factories_ConfigureFactoryRepo
1165-
1166-
```java
1167-
import com.azure.resourcemanager.datafactory.models.FactoryRepoUpdate;
1168-
import com.azure.resourcemanager.datafactory.models.FactoryVstsConfiguration;
1169-
1170-
/**
1171-
* Samples for Factories ConfigureFactoryRepo.
1172-
*/
1173-
public final class FactoriesConfigureFactoryRepoSamples {
1174-
/*
1175-
* x-ms-original-file: specification/datafactory/resource-manager/Microsoft.DataFactory/stable/2018-06-01/examples/
1176-
* Factories_ConfigureFactoryRepo.json
1177-
*/
1178-
/**
1179-
* Sample code: Factories_ConfigureFactoryRepo.
1180-
*
1181-
* @param manager Entry point to DataFactoryManager.
1182-
*/
1183-
public static void factoriesConfigureFactoryRepo(com.azure.resourcemanager.datafactory.DataFactoryManager manager) {
1184-
manager.factories()
1185-
.configureFactoryRepoWithResponse("East US", new FactoryRepoUpdate().withFactoryResourceId(
1186-
"/subscriptions/12345678-1234-1234-1234-12345678abc/resourceGroups/exampleResourceGroup/providers/Microsoft.DataFactory/factories/exampleFactoryName")
1187-
.withRepoConfiguration(new FactoryVstsConfiguration().withAccountName("ADF")
1188-
.withRepositoryName("repo")
1189-
.withCollaborationBranch("master")
1190-
.withRootFolder("/")
1191-
.withLastCommitId("")
1192-
.withProjectName("project")
1193-
.withTenantId("")),
1194-
com.azure.core.util.Context.NONE);
1195-
}
1196-
}
1197-
```
1198-
11991158
### Factories_CreateOrUpdate
12001159

12011160
```java
@@ -1330,28 +1289,6 @@ public final class FactoriesGetGitHubAccessTokenSamples {
13301289
}
13311290
```
13321291

1333-
### Factories_List
1334-
1335-
```java
1336-
/**
1337-
* Samples for Factories List.
1338-
*/
1339-
public final class FactoriesListSamples {
1340-
/*
1341-
* x-ms-original-file:
1342-
* specification/datafactory/resource-manager/Microsoft.DataFactory/stable/2018-06-01/examples/Factories_List.json
1343-
*/
1344-
/**
1345-
* Sample code: Factories_List.
1346-
*
1347-
* @param manager Entry point to DataFactoryManager.
1348-
*/
1349-
public static void factoriesList(com.azure.resourcemanager.datafactory.DataFactoryManager manager) {
1350-
manager.factories().list(com.azure.core.util.Context.NONE);
1351-
}
1352-
}
1353-
```
1354-
13551292
### Factories_ListByResourceGroup
13561293

13571294
```java
@@ -2469,28 +2406,6 @@ public final class ManagedVirtualNetworksListByFactorySamples {
24692406
}
24702407
```
24712408

2472-
### Operations_List
2473-
2474-
```java
2475-
/**
2476-
* Samples for Operations List.
2477-
*/
2478-
public final class OperationsListSamples {
2479-
/*
2480-
* x-ms-original-file:
2481-
* specification/datafactory/resource-manager/Microsoft.DataFactory/stable/2018-06-01/examples/Operations_List.json
2482-
*/
2483-
/**
2484-
* Sample code: Operations_List.
2485-
*
2486-
* @param manager Entry point to DataFactoryManager.
2487-
*/
2488-
public static void operationsList(com.azure.resourcemanager.datafactory.DataFactoryManager manager) {
2489-
manager.operations().list(com.azure.core.util.Context.NONE);
2490-
}
2491-
}
2492-
```
2493-
24942409
### PipelineRuns_Cancel
24952410

24962411
```java

sdk/datafactory/azure-resourcemanager-datafactory/pom.xml

+6-5
Original file line numberDiff line numberDiff line change
@@ -46,13 +46,9 @@
4646
<jacoco.min.linecoverage>0</jacoco.min.linecoverage>
4747
<jacoco.min.branchcoverage>0</jacoco.min.branchcoverage>
4848
<revapi.skip>true</revapi.skip>
49+
<spotless.skip>false</spotless.skip>
4950
</properties>
5051
<dependencies>
51-
<dependency>
52-
<groupId>com.azure</groupId>
53-
<artifactId>azure-json</artifactId>
54-
<version>1.3.0</version> <!-- {x-version-update;com.azure:azure-json;dependency} -->
55-
</dependency>
5652
<dependency>
5753
<groupId>com.azure</groupId>
5854
<artifactId>azure-core</artifactId>
@@ -63,6 +59,11 @@
6359
<artifactId>azure-core-management</artifactId>
6460
<version>1.15.6</version> <!-- {x-version-update;com.azure:azure-core-management;dependency} -->
6561
</dependency>
62+
<dependency>
63+
<groupId>com.azure</groupId>
64+
<artifactId>azure-json</artifactId>
65+
<version>1.3.0</version> <!-- {x-version-update;com.azure:azure-json;dependency} -->
66+
</dependency>
6667
<dependency>
6768
<groupId>com.azure</groupId>
6869
<artifactId>azure-core-test</artifactId>

sdk/datafactory/azure-resourcemanager-datafactory/src/main/java/com/azure/resourcemanager/datafactory/DataFactoryManager.java

+13-29
Original file line numberDiff line numberDiff line change
@@ -11,15 +11,15 @@
1111
import com.azure.core.http.HttpPipelinePosition;
1212
import com.azure.core.http.policy.AddDatePolicy;
1313
import com.azure.core.http.policy.AddHeadersFromContextPolicy;
14-
import com.azure.core.http.policy.HttpLoggingPolicy;
14+
import com.azure.core.http.policy.BearerTokenAuthenticationPolicy;
1515
import com.azure.core.http.policy.HttpLogOptions;
16+
import com.azure.core.http.policy.HttpLoggingPolicy;
1617
import com.azure.core.http.policy.HttpPipelinePolicy;
1718
import com.azure.core.http.policy.HttpPolicyProviders;
1819
import com.azure.core.http.policy.RequestIdPolicy;
1920
import com.azure.core.http.policy.RetryOptions;
2021
import com.azure.core.http.policy.RetryPolicy;
2122
import com.azure.core.http.policy.UserAgentPolicy;
22-
import com.azure.core.management.http.policy.ArmChallengeAuthenticationPolicy;
2323
import com.azure.core.management.profile.AzureProfile;
2424
import com.azure.core.util.Configuration;
2525
import com.azure.core.util.logging.ClientLogger;
@@ -40,11 +40,10 @@
4040
import com.azure.resourcemanager.datafactory.implementation.LinkedServicesImpl;
4141
import com.azure.resourcemanager.datafactory.implementation.ManagedPrivateEndpointsImpl;
4242
import com.azure.resourcemanager.datafactory.implementation.ManagedVirtualNetworksImpl;
43-
import com.azure.resourcemanager.datafactory.implementation.OperationsImpl;
4443
import com.azure.resourcemanager.datafactory.implementation.PipelineRunsImpl;
4544
import com.azure.resourcemanager.datafactory.implementation.PipelinesImpl;
46-
import com.azure.resourcemanager.datafactory.implementation.PrivateEndpointConnectionOperationsImpl;
4745
import com.azure.resourcemanager.datafactory.implementation.PrivateEndPointConnectionsImpl;
46+
import com.azure.resourcemanager.datafactory.implementation.PrivateEndpointConnectionOperationsImpl;
4847
import com.azure.resourcemanager.datafactory.implementation.PrivateLinkResourcesImpl;
4948
import com.azure.resourcemanager.datafactory.implementation.TriggerRunsImpl;
5049
import com.azure.resourcemanager.datafactory.implementation.TriggersImpl;
@@ -63,11 +62,10 @@
6362
import com.azure.resourcemanager.datafactory.models.LinkedServices;
6463
import com.azure.resourcemanager.datafactory.models.ManagedPrivateEndpoints;
6564
import com.azure.resourcemanager.datafactory.models.ManagedVirtualNetworks;
66-
import com.azure.resourcemanager.datafactory.models.Operations;
6765
import com.azure.resourcemanager.datafactory.models.PipelineRuns;
6866
import com.azure.resourcemanager.datafactory.models.Pipelines;
69-
import com.azure.resourcemanager.datafactory.models.PrivateEndpointConnectionOperations;
7067
import com.azure.resourcemanager.datafactory.models.PrivateEndPointConnections;
68+
import com.azure.resourcemanager.datafactory.models.PrivateEndpointConnectionOperations;
7169
import com.azure.resourcemanager.datafactory.models.PrivateLinkResources;
7270
import com.azure.resourcemanager.datafactory.models.TriggerRuns;
7371
import com.azure.resourcemanager.datafactory.models.Triggers;
@@ -84,12 +82,10 @@
8482
* V2 services.
8583
*/
8684
public final class DataFactoryManager {
87-
private Operations operations;
85+
private ExposureControls exposureControls;
8886

8987
private Factories factories;
9088

91-
private ExposureControls exposureControls;
92-
9389
private IntegrationRuntimes integrationRuntimes;
9490

9591
private IntegrationRuntimeObjectMetadatas integrationRuntimeObjectMetadatas;
@@ -294,7 +290,7 @@ public DataFactoryManager authenticate(TokenCredential credential, AzureProfile
294290
.append("-")
295291
.append("com.azure.resourcemanager.datafactory")
296292
.append("/")
297-
.append("1.0.0-beta.30");
293+
.append("1.0.0-beta.1");
298294
if (!Configuration.getGlobalConfiguration().get("AZURE_TELEMETRY_DISABLED", false)) {
299295
userAgentBuilder.append(" (")
300296
.append(Configuration.getGlobalConfiguration().get("java.version"))
@@ -327,7 +323,7 @@ public DataFactoryManager authenticate(TokenCredential credential, AzureProfile
327323
HttpPolicyProviders.addBeforeRetryPolicies(policies);
328324
policies.add(retryPolicy);
329325
policies.add(new AddDatePolicy());
330-
policies.add(new ArmChallengeAuthenticationPolicy(credential, scopes.toArray(new String[0])));
326+
policies.add(new BearerTokenAuthenticationPolicy(credential, scopes.toArray(new String[0])));
331327
policies.addAll(this.policies.stream()
332328
.filter(p -> p.getPipelinePosition() == HttpPipelinePosition.PER_RETRY)
333329
.collect(Collectors.toList()));
@@ -341,15 +337,15 @@ public DataFactoryManager authenticate(TokenCredential credential, AzureProfile
341337
}
342338

343339
/**
344-
* Gets the resource collection API of Operations.
340+
* Gets the resource collection API of ExposureControls.
345341
*
346-
* @return Resource collection API of Operations.
342+
* @return Resource collection API of ExposureControls.
347343
*/
348-
public Operations operations() {
349-
if (this.operations == null) {
350-
this.operations = new OperationsImpl(clientObject.getOperations(), this);
344+
public ExposureControls exposureControls() {
345+
if (this.exposureControls == null) {
346+
this.exposureControls = new ExposureControlsImpl(clientObject.getExposureControls(), this);
351347
}
352-
return operations;
348+
return exposureControls;
353349
}
354350

355351
/**
@@ -364,18 +360,6 @@ public Factories factories() {
364360
return factories;
365361
}
366362

367-
/**
368-
* Gets the resource collection API of ExposureControls.
369-
*
370-
* @return Resource collection API of ExposureControls.
371-
*/
372-
public ExposureControls exposureControls() {
373-
if (this.exposureControls == null) {
374-
this.exposureControls = new ExposureControlsImpl(clientObject.getExposureControls(), this);
375-
}
376-
return exposureControls;
377-
}
378-
379363
/**
380364
* Gets the resource collection API of IntegrationRuntimes. It manages IntegrationRuntimeResource.
381365
*

0 commit comments

Comments
 (0)