Skip to content

Commit 36664c4

Browse files
author
SDKAuto
committed
CodeGen from PR 33888 in Azure/azure-rest-api-specs
Merge 5959b29d90c516bd52f1d1094aad4a769709449b into 6ea706e86e0f35817367e394146d337154536350
1 parent 41e7411 commit 36664c4

18 files changed

+14
-411
lines changed

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

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
# Release History
22

3-
## 1.0.0-beta.3 (Unreleased)
3+
## 1.0.0-beta.1 (2025-04-15)
4+
5+
- Azure Resource Manager MigrationDiscoverySap client library for Java. This package contains Microsoft Azure SDK for MigrationDiscoverySap Management SDK. Migration Discovery SAP Client. Package tag package-preview-2023-10. 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/migrationdiscoverysap/azure-resourcemanager-migrationdiscoverysap/README.md

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -52,15 +52,15 @@ Azure subscription ID can be configured via `AZURE_SUBSCRIPTION_ID` environment
5252
Assuming the use of the `DefaultAzureCredential` credential class, the client can be authenticated using the following code:
5353

5454
```java
55-
AzureProfile profile = new AzureProfile(AzureEnvironment.AZURE);
55+
AzureProfile profile = new AzureProfile(AzureCloud.AZURE_PUBLIC_CLOUD);
5656
TokenCredential credential = new DefaultAzureCredentialBuilder()
5757
.authorityHost(profile.getEnvironment().getActiveDirectoryEndpoint())
5858
.build();
5959
MigrationDiscoverySapManager manager = MigrationDiscoverySapManager
6060
.authenticate(credential, profile);
6161
```
6262

63-
The sample code assumes global Azure. Please change `AzureEnvironment.AZURE` variable if otherwise.
63+
The sample code assumes global Azure. Please change the `AzureCloud.AZURE_PUBLIC_CLOUD` variable if otherwise.
6464

6565
See [Authentication][authenticate] for more options.
6666

@@ -100,5 +100,3 @@ This project has adopted the [Microsoft Open Source Code of Conduct][coc]. For m
100100
[cg]: https://github.com/Azure/azure-sdk-for-java/blob/main/CONTRIBUTING.md
101101
[coc]: https://opensource.microsoft.com/codeofconduct/
102102
[coc_faq]: https://opensource.microsoft.com/codeofconduct/faq/
103-
104-

sdk/migrationdiscoverysap/azure-resourcemanager-migrationdiscoverysap/src/main/java/com/azure/resourcemanager/migrationdiscoverysap/MigrationDiscoverySapManager.java

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
import com.azure.core.http.policy.UserAgentPolicy;
2323
import com.azure.core.management.profile.AzureProfile;
2424
import com.azure.core.util.Configuration;
25+
import com.azure.core.util.CoreUtils;
2526
import com.azure.core.util.logging.ClientLogger;
2627
import com.azure.resourcemanager.migrationdiscoverysap.fluent.MigrationDiscoverySapMgmtClient;
2728
import com.azure.resourcemanager.migrationdiscoverysap.implementation.MigrationDiscoverySapMgmtClientBuilder;
@@ -37,6 +38,7 @@
3738
import java.time.temporal.ChronoUnit;
3839
import java.util.ArrayList;
3940
import java.util.List;
41+
import java.util.Map;
4042
import java.util.Objects;
4143
import java.util.stream.Collectors;
4244

@@ -106,6 +108,9 @@ public static Configurable configure() {
106108
*/
107109
public static final class Configurable {
108110
private static final ClientLogger LOGGER = new ClientLogger(Configurable.class);
111+
private static final String SDK_VERSION = "version";
112+
private static final Map<String, String> PROPERTIES
113+
= CoreUtils.getProperties("azure-resourcemanager-migrationdiscoverysap.properties");
109114

110115
private HttpClient httpClient;
111116
private HttpLogOptions httpLogOptions;
@@ -213,12 +218,14 @@ public MigrationDiscoverySapManager authenticate(TokenCredential credential, Azu
213218
Objects.requireNonNull(credential, "'credential' cannot be null.");
214219
Objects.requireNonNull(profile, "'profile' cannot be null.");
215220

221+
String clientVersion = PROPERTIES.getOrDefault(SDK_VERSION, "UnknownVersion");
222+
216223
StringBuilder userAgentBuilder = new StringBuilder();
217224
userAgentBuilder.append("azsdk-java")
218225
.append("-")
219226
.append("com.azure.resourcemanager.migrationdiscoverysap")
220227
.append("/")
221-
.append("1.0.0-beta.2");
228+
.append(clientVersion);
222229
if (!Configuration.getGlobalConfiguration().get("AZURE_TELEMETRY_DISABLED", false)) {
223230
userAgentBuilder.append(" (")
224231
.append(Configuration.getGlobalConfiguration().get("java.version"))
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
version=${project.version}

sdk/migrationdiscoverysap/azure-resourcemanager-migrationdiscoverysap/src/test/java/com/azure/resourcemanager/migrationdiscoverysap/generated/ConfigurationDataTests.java

Lines changed: 0 additions & 23 deletions
This file was deleted.

sdk/migrationdiscoverysap/azure-resourcemanager-migrationdiscoverysap/src/test/java/com/azure/resourcemanager/migrationdiscoverysap/generated/ExcelPerformanceDataTests.java

Lines changed: 0 additions & 23 deletions
This file was deleted.

sdk/migrationdiscoverysap/azure-resourcemanager-migrationdiscoverysap/src/test/java/com/azure/resourcemanager/migrationdiscoverysap/generated/ExtendedLocationTests.java

Lines changed: 0 additions & 27 deletions
This file was deleted.

sdk/migrationdiscoverysap/azure-resourcemanager-migrationdiscoverysap/src/test/java/com/azure/resourcemanager/migrationdiscoverysap/generated/NativePerformanceDataTests.java

Lines changed: 0 additions & 22 deletions
This file was deleted.

sdk/migrationdiscoverysap/azure-resourcemanager-migrationdiscoverysap/src/test/java/com/azure/resourcemanager/migrationdiscoverysap/generated/OperationDisplayTests.java

Lines changed: 0 additions & 23 deletions
This file was deleted.

sdk/migrationdiscoverysap/azure-resourcemanager-migrationdiscoverysap/src/test/java/com/azure/resourcemanager/migrationdiscoverysap/generated/OperationInnerTests.java

Lines changed: 0 additions & 24 deletions
This file was deleted.

0 commit comments

Comments
 (0)