Skip to content
Merged
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
Expand Up @@ -31,7 +31,7 @@
"@typespec/streams": "0.76.0",
"@azure-tools/typespec-azure-core": "0.62.0",
"@azure-tools/typespec-client-generator-core": "0.62.0",
"@azure-tools/typespec-azure-resource-manager": "0.62.0",
"@azure-tools/typespec-azure-resource-manager": "0.62.1",
"@azure-tools/typespec-autorest": "0.62.0"
},
"private": true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ private static Builder withVNextReplacementBuilder(String azureClass, String azu
public static final ClassType ACCESS_TOKEN = withClientCoreReplacement("com.azure.core.credential.AccessToken",
"io.clientcore.core.credentials.oauth.AccessToken");
public static final ClassType AZURE_KEY_CREDENTIAL
= new Builder(false).packageName("com.azure.core.credential").name("AccessToken").build();
= new Builder(false).packageName("com.azure.core.credential").name("AzureKeyCredential").build();
public static final ClassType KEY_CREDENTIAL = withClientCoreReplacement("com.azure.core.credential.KeyCredential",
"io.clientcore.core.credentials.KeyCredential");
public static final ClassType TOKEN_CREDENTIAL = withClientCoreAndVNextReplacement(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -231,8 +231,8 @@ private String convert(String expression, boolean isToClient) {
+ "(el -> %2$s).collect(java.util.stream.Collectors.toList())", expression, mapping);
} else if (this instanceof MapType) {
String mapping = isToClient
? wireTypeArguments[i].convertToClientType("el")
: wireTypeArguments[i].convertFromClientType("el");
? wireTypeArguments[i].convertToClientType("el.getValue()")
: wireTypeArguments[i].convertFromClientType("el.getValue()");
// Key is always String in Swagger 2
expression = String.format(
"%1$s.entrySet().stream().collect(java.util.stream.Collectors.toMap(Map.Entry::getKey, el -> %2$s))",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,8 @@ public static String getPomProjectDescription(String serviceName) {
}

public static String getByteCloneExpression(String propertyName) {
return JavaSettings.getInstance().isAzureV1() ? "CoreUtils.clone(" + propertyName + ")" : propertyName; // TODO:
// generic
// not
// having
// CoreUtils
// TODO: generic not having CoreUtils
return JavaSettings.getInstance().isAzureV1() ? "CoreUtils.clone(" + propertyName + ")" : propertyName;
}

public static void createHttpPipelineMethod(JavaSettings settings, String defaultCredentialScopes,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,8 @@ public final class ModelTemplateHeaderHelper {
// HttpHeaderNames for both maps. Then add the few extra azure-core headers here.
// If HttpHeaderNames are missed from azure-core, they will be handled as unknown headers, which has effectively
// no difference from this optimization other than code bloat.
headerToKnownHttpHeaderName.put("Azure-AsyncOperation", "AZURE_ASYNC_OPERATION");
headerToKnownHttpHeaderName.put("Azure-AsyncOperation", "AZURE_ASYNCOPERATION");
headerToKnownHttpHeaderName.put("Operation-Location", "OPERATION_LOCATION");
headerToKnownHttpHeaderName.put("retry-after-ms", "RETRY_AFTER_MS");
headerToKnownHttpHeaderName.put("x-ms-client-id", "X_MS_CLIENT_ID");
headerToKnownHttpHeaderName.put("x-ms-client-request-id", "X_MS_CLIENT_REQUEST_ID");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
"@typespec/streams": "0.76.0",
"@azure-tools/typespec-azure-core": "0.62.0",
"@azure-tools/typespec-client-generator-core": "0.62.0",
"@azure-tools/typespec-azure-resource-manager": "0.62.0",
"@azure-tools/typespec-azure-resource-manager": "0.62.1",
"@azure-tools/typespec-autorest": "0.62.0"
},
"private": true
Expand Down
491 changes: 259 additions & 232 deletions packages/http-client-java/package-lock.json

Large diffs are not rendered by default.

18 changes: 9 additions & 9 deletions packages/http-client-java/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
"peerDependencies": {
"@azure-tools/typespec-autorest": ">=0.62.0 <1.0.0",
"@azure-tools/typespec-azure-core": ">=0.62.0 <1.0.0",
"@azure-tools/typespec-azure-resource-manager": ">=0.62.0 <1.0.0",
"@azure-tools/typespec-azure-resource-manager": ">=0.62.1 <1.0.0",
"@azure-tools/typespec-client-generator-core": ">=0.62.0 <1.0.0",
"@typespec/compiler": "^1.6.0",
"@typespec/events": ">=0.76.0 <1.0.0",
Expand All @@ -71,13 +71,13 @@
"devDependencies": {
"@azure-tools/typespec-autorest": "0.62.0",
"@azure-tools/typespec-azure-core": "0.62.0",
"@azure-tools/typespec-azure-resource-manager": "0.62.0",
"@azure-tools/typespec-azure-resource-manager": "0.62.1",
"@azure-tools/typespec-azure-rulesets": "0.62.0",
"@azure-tools/typespec-client-generator-core": "0.62.0",
"@microsoft/api-extractor": "^7.55.0",
"@microsoft/api-extractor-model": "^7.32.0",
"@microsoft/api-extractor": "^7.55.1",
"@microsoft/api-extractor-model": "^7.32.1",
"@types/js-yaml": "~4.0.9",
"@types/lodash": "~4.17.20",
"@types/lodash": "~4.17.21",
"@types/node": "~24.10.1",
"@typespec/compiler": "1.6.0",
"@typespec/events": "0.76.0",
Expand All @@ -89,11 +89,11 @@
"@typespec/streams": "0.76.0",
"@typespec/versioning": "0.76.0",
"@typespec/xml": "0.76.0",
"@vitest/coverage-v8": "^4.0.8",
"@vitest/ui": "^4.0.8",
"@vitest/coverage-v8": "^4.0.14",
"@vitest/ui": "^4.0.14",
"c8": "~10.1.3",
"rimraf": "~6.1.0",
"rimraf": "~6.1.2",
"typescript": "~5.9.3",
"vitest": "^4.0.8"
"vitest": "^4.0.14"
}
}
Loading