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
2 changes: 1 addition & 1 deletion core
Submodule core updated 954 files
6 changes: 6 additions & 0 deletions typespec-extension/changelog.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# Release History

## 0.44.0 (2026-04-08)

Compatible with compiler 1.11.0.

- Updated package dependencies to the latest versions.

## 0.43.3 (2026-04-02)

Compatible with compiler 1.10.0.
Expand Down
932 changes: 452 additions & 480 deletions typespec-extension/package-lock.json

Large diffs are not rendered by default.

66 changes: 33 additions & 33 deletions typespec-extension/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@azure-tools/typespec-java",
"version": "0.43.3",
"version": "0.44.0",
"description": "TypeSpec library for emitting Java client from the TypeSpec REST protocol binding",
"keywords": [
"TypeSpec"
Expand Down Expand Up @@ -48,19 +48,19 @@
],
"peerDependencies": {
"@azure-tools/openai-typespec": "^1.11.0",
"@azure-tools/typespec-autorest": ">=0.66.2 <1.0.0",
"@azure-tools/typespec-azure-core": ">=0.66.1 <1.0.0",
"@azure-tools/typespec-azure-resource-manager": ">=0.66.1 <1.0.0",
"@azure-tools/typespec-azure-rulesets": ">=0.66.0 <1.0.0",
"@azure-tools/typespec-client-generator-core": ">=0.66.4 <1.0.0",
"@azure-tools/typespec-autorest": ">=0.67.0 <1.0.0",
"@azure-tools/typespec-azure-core": ">=0.67.0 <1.0.0",
"@azure-tools/typespec-azure-resource-manager": ">=0.67.0 <1.0.0",
"@azure-tools/typespec-azure-rulesets": ">=0.67.0 <1.0.0",
"@azure-tools/typespec-client-generator-core": ">=0.67.0 <1.0.0",
"@azure-tools/typespec-liftr-base": ">=0.13.0 <1.0.0",
"@typespec/compiler": "^1.10.0",
"@typespec/http": "^1.10.0",
"@typespec/openapi": "^1.10.0",
"@typespec/openapi3": "^1.10.0",
"@typespec/rest": ">=0.80.0 <1.0.0",
"@typespec/versioning": ">=0.80.0 <1.0.0",
"@typespec/xml": ">=0.80.0 <1.0.0"
"@typespec/compiler": "^1.11.0",
"@typespec/http": "^1.11.0",
"@typespec/openapi": "^1.11.0",
"@typespec/openapi3": "^1.11.0",
"@typespec/rest": ">=0.81.0 <1.0.0",
"@typespec/versioning": ">=0.81.0 <1.0.0",
"@typespec/xml": ">=0.81.0 <1.0.0"
},
"dependencies": {
"@autorest/codemodel": "~4.20.1",
Expand All @@ -69,31 +69,31 @@
},
"devDependencies": {
"@azure-tools/openai-typespec": "1.11.0",
"@azure-tools/typespec-autorest": "0.66.2",
"@azure-tools/typespec-azure-core": "0.66.1",
"@azure-tools/typespec-azure-resource-manager": "0.66.1",
"@azure-tools/typespec-azure-rulesets": "0.66.0",
"@azure-tools/typespec-client-generator-core": "0.66.4",
"@azure-tools/typespec-autorest": "0.67.0",
"@azure-tools/typespec-azure-core": "0.67.0",
"@azure-tools/typespec-azure-resource-manager": "0.67.0",
"@azure-tools/typespec-azure-rulesets": "0.67.0",
"@azure-tools/typespec-client-generator-core": "0.67.0",
"@azure-tools/typespec-liftr-base": "0.13.0",
"@microsoft/api-extractor": "^7.58.0",
"@microsoft/api-extractor": "^7.58.1",
"@types/js-yaml": "~4.0.9",
"@types/lodash": "~4.17.24",
"@types/node": "~25.5.0",
"@types/node": "~25.5.2",
"@typescript-eslint/eslint-plugin": "~8.58.0",
"@typescript-eslint/parser": "~8.58.0",
"@typespec/compiler": "1.10.0",
"@typespec/events": "0.80.0",
"@typespec/http": "1.10.0",
"@typespec/openapi": "1.10.0",
"@typespec/openapi3": "1.10.0",
"@typespec/rest": "0.80.0",
"@typespec/sse": "0.80.0",
"@typespec/streams": "0.80.0",
"@typespec/compiler": "1.11.0",
"@typespec/events": "0.81.0",
"@typespec/http": "1.11.0",
"@typespec/openapi": "1.11.0",
"@typespec/openapi3": "1.11.0",
"@typespec/rest": "0.81.0",
"@typespec/sse": "0.81.0",
"@typespec/streams": "0.81.0",
"@typespec/tspd": "0.74.1",
"@typespec/versioning": "0.80.0",
"@typespec/xml": "0.80.0",
"@vitest/coverage-v8": "^4.1.2",
"@vitest/ui": "^4.1.2",
"@typespec/versioning": "0.81.0",
"@typespec/xml": "0.81.0",
"@vitest/coverage-v8": "^4.1.3",
"@vitest/ui": "^4.1.3",
"c8": "~11.0.0",
"eslint": "~10.1.0",
"eslint-plugin-deprecation": "~3.0.0",
Expand All @@ -103,7 +103,7 @@
"rimraf": "~6.1.3",
"typescript": "~5.9.2",
"typescript-eslint": "^8.58.0",
"vitest": "^4.1.2"
"vitest": "^4.1.3"
},
"overrides": {
"eslint": "~10.1.0",
Expand Down
5 changes: 1 addition & 4 deletions typespec-tests/Generate.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ Write-Host "Parallelization: $Parallelization"
$generateScript = {
$tspFile = $_

if (($tspFile -match "payload[\\/]pageable[\\/]main\.tsp") -and (-not ($tspFile -match "azure[\\/]payload[\\/]pageable[\\/]main\.tsp"))) {
if ((($tspFile -match "payload[\\/]pageable[\\/]main\.tsp") -and (-not ($tspFile -match "azure[\\/]payload[\\/]pageable[\\/]main\.tsp"))) -or ($tspFile -match "service[\\/]multiple-services[\\/]main\.tsp")) {
Write-Host "
SKIPPED
$tspFile
Expand Down Expand Up @@ -62,8 +62,6 @@ $generateScript = {
} elseif ($tspFile -match "azure[\\/]resource-manager[\\/].*[\\/]main\.tsp") {
# for mgmt, do not generate tests due to random mock values
$tspOptions += " --option ""@azure-tools/typespec-java.generate-tests=false"""
} elseif ($tspFile -match "azure[\\/]resource-manager[\\/]multi-service-older-versions[\\/]") {
$tspOptions += " --option ""@azure-tools/typespec-java.metadata-suffix=older-versions"""
} elseif ($tspFile -match "azure[\\/]resource-manager[\\/]multi-service-shared-models[\\/]") {
$tspOptions += " --option ""@azure-tools/typespec-java.metadata-suffix=shared-models"""
} elseif ($tspFile -match "tsp[\\/]versioning.tsp") {
Expand Down Expand Up @@ -200,7 +198,6 @@ try {
$specFiles = Get-ChildItem ./specs -Include "main.tsp","old.tsp" -File -Recurse
# ensure multi-service client specs are processed even though they do not match the default filter
$specFiles += Get-Item (Join-Path ./specs "azure/resource-manager/multi-service/client.tsp")
$specFiles += Get-Item (Join-Path ./specs "azure/resource-manager/multi-service-older-versions/client.tsp")
$specFiles += Get-Item (Join-Path ./specs "azure/resource-manager/multi-service-shared-models/client.tsp")

$job = $specFiles | ForEach-Object -Parallel $generateScript -ThrottleLimit $Parallelization -AsJob
Expand Down
38 changes: 19 additions & 19 deletions typespec-tests/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,31 +9,31 @@
"spector-serve": "tsp-spector serve ./node_modules/@typespec/http-specs/specs ./node_modules/@azure-tools/azure-http-specs/specs --coverageFile ./tsp-spector-coverage-java.json"
},
"dependencies": {
"@typespec/spec-api": "0.1.0-alpha.13",
"@typespec/spector": "0.1.0-alpha.24",
"@typespec/http-specs": "0.1.0-alpha.35",
"@azure-tools/azure-http-specs": "0.1.0-alpha.38",
"@azure-tools/typespec-java": "file:/../typespec-extension/azure-tools-typespec-java-0.43.3.tgz"
"@typespec/spec-api": "0.1.0-alpha.14",
"@typespec/spector": "0.1.0-alpha.25",
"@typespec/http-specs": "0.1.0-alpha.36",
"@azure-tools/azure-http-specs": "0.1.0-alpha.39",
"@azure-tools/typespec-java": "file:/../typespec-extension/azure-tools-typespec-java-0.44.0.tgz"
},
"devDependencies": {
"@typespec/prettier-plugin-typespec": "^1.10.0",
"@typespec/prettier-plugin-typespec": "^1.11.0",
"prettier-plugin-organize-imports": "^4.3.0",
"prettier": "^3.8.1"
},
"overrides": {
"@typespec/compiler": "1.10.0",
"@typespec/http": "1.10.0",
"@typespec/rest": "0.80.0",
"@typespec/versioning": "0.80.0",
"@typespec/openapi": "1.10.0",
"@typespec/xml": "0.80.0",
"@typespec/events": "0.80.0",
"@typespec/sse": "0.80.0",
"@typespec/streams": "0.80.0",
"@azure-tools/typespec-azure-core": "0.66.1",
"@azure-tools/typespec-client-generator-core": "0.66.4",
"@azure-tools/typespec-azure-resource-manager": "0.66.1",
"@azure-tools/typespec-autorest": "0.66.2",
"@typespec/compiler": "1.11.0",
"@typespec/http": "1.11.0",
"@typespec/rest": "0.81.0",
"@typespec/versioning": "0.81.0",
"@typespec/openapi": "1.11.0",
"@typespec/xml": "0.81.0",
"@typespec/events": "0.81.0",
"@typespec/sse": "0.81.0",
"@typespec/streams": "0.81.0",
"@azure-tools/typespec-azure-core": "0.67.0",
"@azure-tools/typespec-client-generator-core": "0.67.0",
"@azure-tools/typespec-azure-resource-manager": "0.67.0",
"@azure-tools/typespec-autorest": "0.67.0",
"@azure-tools/typespec-liftr-base": "0.13.0"
},
"private": true
Expand Down
109 changes: 109 additions & 0 deletions typespec-tests/src/main/java/client/naming/HeaderAsyncClient.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,109 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
// Code generated by Microsoft (R) TypeSpec Code Generator.

package client.naming;

import client.naming.implementation.HeadersImpl;
import com.azure.core.annotation.Generated;
import com.azure.core.annotation.ReturnType;
import com.azure.core.annotation.ServiceClient;
import com.azure.core.annotation.ServiceMethod;
import com.azure.core.exception.ClientAuthenticationException;
import com.azure.core.exception.HttpResponseException;
import com.azure.core.exception.ResourceModifiedException;
import com.azure.core.exception.ResourceNotFoundException;
import com.azure.core.http.rest.RequestOptions;
import com.azure.core.http.rest.Response;
import com.azure.core.util.FluxUtil;
import reactor.core.publisher.Mono;

/**
* Initializes a new instance of the asynchronous NamingClient type.
*/
@ServiceClient(builder = NamingClientBuilder.class, isAsync = true)
public final class HeaderAsyncClient {
@Generated
private final HeadersImpl serviceClient;

/**
* Initializes an instance of HeaderAsyncClient class.
*
* @param serviceClient the service client implementation.
*/
@Generated
HeaderAsyncClient(HeadersImpl serviceClient) {
this.serviceClient = serviceClient;
}

/**
* The request operation.
*
* @param clientName The clientName parameter.
* @param requestOptions The options to configure the HTTP request before HTTP client sends it.
* @throws HttpResponseException thrown if the request is rejected by server.
* @throws ClientAuthenticationException thrown if the request is rejected by server on status code 401.
* @throws ResourceNotFoundException thrown if the request is rejected by server on status code 404.
* @throws ResourceModifiedException thrown if the request is rejected by server on status code 409.
* @return the {@link Response} on successful completion of {@link Mono}.
*/
@Generated
@ServiceMethod(returns = ReturnType.SINGLE)
public Mono<Response<Void>> requestWithResponse(String clientName, RequestOptions requestOptions) {
return this.serviceClient.requestWithResponseAsync(clientName, requestOptions);
}

/**
* The response operation.
*
* @param requestOptions The options to configure the HTTP request before HTTP client sends it.
* @throws HttpResponseException thrown if the request is rejected by server.
* @throws ClientAuthenticationException thrown if the request is rejected by server on status code 401.
* @throws ResourceNotFoundException thrown if the request is rejected by server on status code 404.
* @throws ResourceModifiedException thrown if the request is rejected by server on status code 409.
* @return the {@link Response} on successful completion of {@link Mono}.
*/
@Generated
@ServiceMethod(returns = ReturnType.SINGLE)
public Mono<Response<Void>> responseWithResponse(RequestOptions requestOptions) {
return this.serviceClient.responseWithResponseAsync(requestOptions);
}

/**
* The request operation.
*
* @param clientName The clientName parameter.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws HttpResponseException thrown if the request is rejected by server.
* @throws ClientAuthenticationException thrown if the request is rejected by server on status code 401.
* @throws ResourceNotFoundException thrown if the request is rejected by server on status code 404.
* @throws ResourceModifiedException thrown if the request is rejected by server on status code 409.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return A {@link Mono} that completes when a successful response is received.
*/
@Generated
@ServiceMethod(returns = ReturnType.SINGLE)
public Mono<Void> request(String clientName) {
// Generated convenience method for requestWithResponse
RequestOptions requestOptions = new RequestOptions();
return requestWithResponse(clientName, requestOptions).flatMap(FluxUtil::toMono);
}

/**
* The response operation.
*
* @throws HttpResponseException thrown if the request is rejected by server.
* @throws ClientAuthenticationException thrown if the request is rejected by server on status code 401.
* @throws ResourceNotFoundException thrown if the request is rejected by server on status code 404.
* @throws ResourceModifiedException thrown if the request is rejected by server on status code 409.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return A {@link Mono} that completes when a successful response is received.
*/
@Generated
@ServiceMethod(returns = ReturnType.SINGLE)
public Mono<Void> response() {
// Generated convenience method for responseWithResponse
RequestOptions requestOptions = new RequestOptions();
return responseWithResponse(requestOptions).flatMap(FluxUtil::toMono);
}
}
Loading
Loading