Skip to content

mgmt, TypeSpec tspconfig for premium libs #47778

@weidongxu-microsoft

Description

@weidongxu-microsoft

The compilation likely would fail, as the generated code is not automatically compatible with handwritten code.

This task is a WIP to be either a guideline to solve the problem, or a basic for agent to fix it.

azure-rest-api-specs

We first need to make the Java Validation CI pass there.

tspconfig.yaml

Remove the generated segment from namespace and emitter-output-dir.

Make sure this is specified

    premium: true
    client-side-validations: true
    enable-sync-stack: false

One may optional need

    use-object-for-unknown: true

too.

back-compatible.tsp

Make sure flattenProperty contains Java in scope.

client.tsp

Check build error, add client rename to issues relates to casing, e.g. rename IPRule to IpRule.

Example

azure-sdk-for-java

Use https://dev.azure.com/azure-sdk/internal/_build?definitionId=7421 to generate the SDK. Fill the "Path to API specification file" (relative path to the tspconfig.yaml) and "API version" (generally use the latest stable).

After done, check the PR on azure-sdk-for-java.

First take a look on generated CHANGELOG.md, it should give readable summary.

For simple issues, one will need to go back to azure-rest-api-specs repo, to further modify "client.tsp"

TODO: some process to iterate from local modified "client.tsp" to code in SDK repo

Metadata

Metadata

Labels

MgmtThis issue is related to a management-plane library.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions