Gateway Route Configs - Create Or Update
기본 Spring Cloud Gateway 경로 구성을 만들거나 기존 Spring Cloud Gateway 경로 구성을 업데이트합니다.
PUT https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AppPlatform/Spring/{serviceName}/gateways/{gatewayName}/routeConfigs/{routeConfigName}?api-version=2023-12-01
URI 매개 변수
| Name | In(다음 안에) | 필수 | 형식 | Description |
|---|---|---|---|---|
|
gateway
|
path | True |
string pattern: ^[a-z][a-z0-9]*$ |
Spring Cloud Gateway의 이름입니다. |
|
resource
|
path | True |
string |
리소스를 포함하는 리소스 그룹의 이름입니다. Azure Resource Manager API 또는 포털에서 이 값을 가져올 수 있습니다. |
|
route
|
path | True |
string |
Spring Cloud Gateway 경로 구성의 이름입니다. |
|
service
|
path | True |
string pattern: ^[a-z][a-z0-9-]*[a-z0-9]$ |
서비스 리소스의 이름입니다. |
|
subscription
|
path | True |
string |
Microsoft Azure 구독을 고유하게 식별하는 구독 ID를 가져옵니다. 구독 ID는 모든 서비스 호출에 대한 URI의 일부를 형성합니다. |
|
api-version
|
query | True |
string minLength: 1 |
이 작업에 사용할 API 버전입니다. |
요청 본문
| Name | 형식 | Description |
|---|---|---|
| properties |
Spring Cloud Gateway의 API 경로 구성 |
응답
| Name | 형식 | Description |
|---|---|---|
| 200 OK |
성공. 응답은 업데이트된 Spring Cloud Gateway 경로 구성을 설명합니다. |
|
| 201 Created |
만든. 응답은 새로 만든 Spring Cloud Gateway 경로 구성을 설명하고 작업 결과를 쿼리하는 Azure-AsyncOperation 헤더를 포함합니다. |
|
| Other Status Codes |
작업이 실패한 이유를 설명하는 오류 응답입니다. |
보안
azure_auth
Azure Active Directory OAuth2 흐름
형식:
oauth2
Flow:
implicit
권한 부여 URL:
https://login.microsoftonline.com/common/oauth2/authorize
범위
| Name | Description |
|---|---|
| user_impersonation | 사용자 계정 가장 |
예제
GatewayRouteConfigs_CreateOrUpdate
샘플 요청
PUT https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.AppPlatform/Spring/myservice/gateways/default/routeConfigs/myRouteConfig?api-version=2023-12-01
{
"properties": {
"appResourceId": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.AppPlatform/Spring/myservice/apps/myApp",
"openApi": {
"uri": "https://raw.githubusercontent.com/OAI/OpenAPI-Specification/main/examples/v3.0/petstore.json"
},
"protocol": "HTTPS",
"routes": [
{
"title": "myApp route config",
"ssoEnabled": true,
"predicates": [
"Path=/api5/customer/**"
],
"filters": [
"StripPrefix=2",
"RateLimit=1,1s"
]
}
]
}
}
샘플 응답
{
"properties": {
"provisioningState": "Succeeded",
"appResourceId": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.AppPlatform/Spring/myservice/apps/myApp",
"protocol": "HTTPS",
"openApi": {
"uri": "https://raw.githubusercontent.com/OAI/OpenAPI-Specification/main/examples/v3.0/petstore.json"
},
"routes": [
{
"title": "myApp route config",
"ssoEnabled": true,
"predicates": [
"Path=/api5/customer/**"
],
"filters": [
"StripPrefix=2",
"RateLimit=1,1s"
]
}
]
},
"systemData": {
"createdBy": "sample-user",
"createdByType": "User",
"createdAt": "2021-08-11T03:16:03.944Z",
"lastModifiedBy": "sample-user",
"lastModifiedByType": "User",
"lastModifiedAt": "2021-08-11T03:17:03.944Z"
},
"type": "Microsoft.AppPlatform/Spring/gateways/routeConfigs",
"id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.AppPlatform/Spring/myservice/gateways/default/routeConfigs/myRouteConfig",
"name": "myRouteConfig"
}
{
"properties": {
"appResourceId": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.AppPlatform/Spring/myservice/apps/myApp",
"protocol": "HTTPS",
"openApi": {
"uri": "https://raw.githubusercontent.com/OAI/OpenAPI-Specification/main/examples/v3.0/petstore.json"
},
"routes": [
{
"title": "myApp route config",
"ssoEnabled": true,
"predicates": [
"Path=/api5/customer/**"
],
"filters": [
"StripPrefix=2",
"RateLimit=1,1s"
]
}
]
},
"systemData": {
"createdBy": "sample-user",
"createdByType": "User",
"createdAt": "2021-08-11T03:16:03.944Z",
"lastModifiedBy": "sample-user",
"lastModifiedByType": "User",
"lastModifiedAt": "2021-08-11T03:17:03.944Z"
},
"type": "Microsoft.AppPlatform/Spring/gateways/routeConfigs",
"id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.AppPlatform/Spring/myservice/gateways/default/routeConfigs/myRouteConfig",
"name": "myRouteConfig"
}
정의
| Name | Description |
|---|---|
|
Cloud |
서비스의 오류 응답입니다. |
|
Cloud |
서비스의 오류 응답입니다. |
|
created |
리소스를 만든 ID의 형식입니다. |
|
Gateway |
Spring Cloud Gateway의 API 경로 구성 |
|
Gateway |
Spring Cloud Gateway의 상태입니다. |
|
Gateway |
Spring Cloud Gateway 경로 구성의 OpenAPI 속성입니다. |
|
Gateway |
Spring Cloud Gateway의 API 경로 구성 |
|
Gateway |
라우트된 Azure Spring Apps 애플리케이션의 프로토콜입니다. |
|
Gateway |
Spring Cloud Gateway 경로 구성 리소스 |
|
last |
리소스를 마지막으로 수정한 ID의 형식입니다. |
|
System |
리소스의 생성 및 마지막 수정과 관련된 메타데이터입니다. |
CloudError
서비스의 오류 응답입니다.
| Name | 형식 | Description |
|---|---|---|
| error |
서비스의 오류 응답입니다. |
CloudErrorBody
서비스의 오류 응답입니다.
| Name | 형식 | Description |
|---|---|---|
| code |
string |
오류의 식별자입니다. 코드는 고정적이며 프로그래밍 방식으로 사용할 수 있습니다. |
| details |
오류에 대한 추가 세부 정보 목록입니다. |
|
| message |
string |
사용자 인터페이스에 표시하기에 적합한 오류를 설명하는 메시지입니다. |
| target |
string |
특정 오류의 대상입니다. 예를 들어 오류가 발생한 속성의 이름입니다. |
createdByType
리소스를 만든 ID의 형식입니다.
| 값 | Description |
|---|---|
| User | |
| Application | |
| ManagedIdentity | |
| Key |
GatewayApiRoute
Spring Cloud Gateway의 API 경로 구성
| Name | 형식 | Description |
|---|---|---|
| description |
string |
설명은 생성된 OpenAPI 설명서의 메서드에 적용됩니다. |
| filters |
string[] |
대상 엔드포인트 또는 수신된 응답으로 보내기 전에 요청을 수정합니다. |
| order |
integer (int32) |
경로 처리 순서입니다. |
| predicates |
string[] |
각 요청에 대한 경로를 평가하기 위한 여러 조건입니다. 각 조건자는 요청 헤더 및 매개 변수 값에 대해 평가될 수 있습니다. 경로와 연결된 모든 조건자는 경로가 요청에 일치하도록 true로 평가되어야 합니다. |
| ssoEnabled |
boolean |
sso 유효성 검사를 사용하도록 설정합니다. |
| tags |
string[] |
분류 태그는 생성된 OpenAPI 설명서의 메서드에 적용됩니다. |
| title |
string |
생성된 OpenAPI 설명서의 메서드에 제목이 적용됩니다. |
| tokenRelay |
boolean |
현재 인증된 사용자의 ID 토큰을 애플리케이션 서비스에 전달합니다. 기본값은 'false'입니다. |
| uri |
string |
전체 URI는 |
GatewayProvisioningState
Spring Cloud Gateway의 상태입니다.
| 값 | Description |
|---|---|
| Creating | |
| Updating | |
| Succeeded | |
| Failed | |
| Deleting |
GatewayRouteConfigOpenApiProperties
Spring Cloud Gateway 경로 구성의 OpenAPI 속성입니다.
| Name | 형식 | Description |
|---|---|---|
| uri |
string |
OpenAPI 사양의 URI입니다. |
GatewayRouteConfigProperties
Spring Cloud Gateway의 API 경로 구성
| Name | 형식 | Default value | Description |
|---|---|---|---|
| appResourceId |
string |
경로가 |
|
| filters |
string[] |
대상 엔드포인트로 보내기 전에 요청을 수정하거나 앱 수준에서 수신된 응답을 수정합니다. |
|
| openApi |
Spring Cloud Gateway 경로 구성의 OpenAPI 속성입니다. |
||
| predicates |
string[] |
앱 수준에서 각 요청에 대한 경로를 평가하기 위한 여러 조건입니다. 각 조건자는 요청 헤더 및 매개 변수 값에 대해 평가될 수 있습니다. 경로와 연결된 모든 조건자는 경로가 요청에 일치하도록 true로 평가되어야 합니다. |
|
| protocol | HTTP |
라우트된 Azure Spring Apps 애플리케이션의 프로토콜입니다. |
|
| provisioningState |
Spring Cloud Gateway 경로 구성의 상태입니다. |
||
| routes |
API 경로 배열의 각 경로에는 |
||
| ssoEnabled |
boolean |
앱 수준에서 단일 Sign-On 사용하도록 설정합니다. |
GatewayRouteConfigProtocol
라우트된 Azure Spring Apps 애플리케이션의 프로토콜입니다.
| 값 | Description |
|---|---|
| HTTP | |
| HTTPS |
GatewayRouteConfigResource
Spring Cloud Gateway 경로 구성 리소스
| Name | 형식 | Description |
|---|---|---|
| id |
string |
리소스에 대한 정규화된 리소스 ID입니다. |
| name |
string |
리소스의 이름입니다. |
| properties |
Spring Cloud Gateway의 API 경로 구성 |
|
| systemData |
리소스의 생성 및 마지막 수정과 관련된 메타데이터입니다. |
|
| type |
string |
리소스의 형식입니다. |
lastModifiedByType
리소스를 마지막으로 수정한 ID의 형식입니다.
| 값 | Description |
|---|---|
| User | |
| Application | |
| ManagedIdentity | |
| Key |
SystemData
리소스의 생성 및 마지막 수정과 관련된 메타데이터입니다.
| Name | 형식 | Description |
|---|---|---|
| createdAt |
string (date-time) |
리소스 만들기의 타임스탬프(UTC)입니다. |
| createdBy |
string |
리소스를 만든 ID입니다. |
| createdByType |
리소스를 만든 ID의 형식입니다. |
|
| lastModifiedAt |
string (date-time) |
리소스 수정의 타임스탬프(UTC)입니다. |
| lastModifiedBy |
string |
리소스를 마지막으로 수정한 ID입니다. |
| lastModifiedByType |
리소스를 마지막으로 수정한 ID의 형식입니다. |