Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

use-endpoint-instead-of-localhost #425

Merged
Merged
Show file tree
Hide file tree
Changes from 2 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
6 changes: 6 additions & 0 deletions .changeset/proud-garlics-shake.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
"@azure-tools/cadl-ranch-specs": patch
"@azure-tools/cadl-ranch": patch
---

use-endpoint-instead-of-localhost
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,13 @@ using Azure.ClientGenerator.Core;
6. have two clients with a hierarchy relation.
""")
@server(
"http://localhost:3000/client/structure/{client}",
"{endpoint}/client/structure/{client}",
"",
{
@doc("Need to be set as 'http://localhost:3000' in client.")
endpoint: url,

@doc("Need to be set as 'default', 'multi-client', 'renamed-operation', 'two-operation-group' in client.")
client: ClientType,
}
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,12 @@ using TypeSpec.Http;
})
@service
@server(
"http://localhost:3000/resiliency/service-driven/client:v2/service:{serviceDeploymentVersion}/api-version:{apiVersion}",
"{endpoint}/resiliency/service-driven/client:v2/service:{serviceDeploymentVersion}/api-version:{apiVersion}",
"Testserver endpoint",
{
@doc("Need to be set as 'http://localhost:3000' in client.")
endpoint: url,
qiaozha marked this conversation as resolved.
Show resolved Hide resolved

@doc("Pass in either 'v1' or 'v2'. This represents a version of the service deployment in history. 'v1' is for the deployment when the service had only one api version. 'v2' is for the deployment when the service had api-versions 'v1' and 'v2'.")
serviceDeploymentVersion: string,

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,12 @@ using TypeSpec.Versioning;
})
@service
@server(
"http://localhost:3000/resiliency/service-driven/client:v1/service:{serviceDeploymentVersion}/api-version:{apiVersion}",
"{endpoint}/resiliency/service-driven/client:v1/service:{serviceDeploymentVersion}/api-version:{apiVersion}",
"Testserver endpoint",
{
@doc("Need to be set as 'http://localhost:3000' in client.")
endpoint: url,

@doc("Pass in either 'v1' or 'v2'. This represents a version of the service deployment in history. 'v1' is for the deployment when the service had only one api version. 'v2' is for the deployment when the service had api-versions 'v1' and 'v2'.")
serviceDeploymentVersion: string,

Expand Down