Skip to content

Commit

Permalink
fix(auto-doc) change targets healthy/unhealthy endpoints http method …
Browse files Browse the repository at this point in the history
…`POST` to `PUT` (#9262)
  • Loading branch information
raoxiaoyan authored Aug 26, 2022
1 parent ea7cc57 commit b85b2ec
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions autodoc/admin-api/data/admin-api.lua
Original file line number Diff line number Diff line change
Expand Up @@ -1844,7 +1844,7 @@ return {
}
},
["/upstreams/:upstreams/targets/:targets/healthy"] = {
POST = {
PUT = {
title = [[Set target as healthy]],
description = [[
Set the current health status of a target in the load balancer to "healthy"
Expand All @@ -1863,7 +1863,7 @@ return {
Note: This API is not available when Kong is running in Hybrid mode.
]],
endpoint = [[
<div class="endpoint post indent">/upstreams/{upstream name or id}/targets/{target or id}/healthy</div>
<div class="endpoint put indent">/upstreams/{upstream name or id}/targets/{target or id}/healthy</div>
{:.indent}
Attributes | Description
Expand All @@ -1879,7 +1879,7 @@ return {
}
},
["/upstreams/:upstreams/targets/:targets/unhealthy"] = {
POST = {
PUT = {
title = [[Set target as unhealthy]],
description = [[
Set the current health status of a target in the load balancer to "unhealthy"
Expand All @@ -1903,7 +1903,7 @@ return {
Note: This API is not available when Kong is running in Hybrid mode.
]],
endpoint = [[
<div class="endpoint post indent">/upstreams/{upstream name or id}/targets/{target or id}/unhealthy</div>
<div class="endpoint put indent">/upstreams/{upstream name or id}/targets/{target or id}/unhealthy</div>
{:.indent}
Attributes | Description
Expand All @@ -1919,7 +1919,7 @@ return {
}
},
["/upstreams/:upstreams/targets/:targets/:address/healthy"] = {
POST = {
PUT = {
title = [[Set target address as healthy]],
description = [[
Set the current health status of an individual address resolved by a target
Expand All @@ -1937,7 +1937,7 @@ return {
Note: This API is not available when Kong is running in Hybrid mode.
]],
endpoint = [[
<div class="endpoint post indent">/upstreams/{upstream name or id}/targets/{target or id}/{address}/healthy</div>
<div class="endpoint put indent">/upstreams/{upstream name or id}/targets/{target or id}/{address}/healthy</div>
{:.indent}
Attributes | Description
Expand All @@ -1954,7 +1954,7 @@ return {
}
},
["/upstreams/:upstreams/targets/:targets/:address/unhealthy"] = {
POST = {
PUT = {
title = [[Set target address as unhealthy]],
description = [[
Set the current health status of an individual address resolved by a target
Expand All @@ -1977,7 +1977,7 @@ return {
Note: This API is not available when Kong is running in Hybrid mode.
]],
endpoint = [[
<div class="endpoint post indent">/upstreams/{upstream name or id}/targets/{target or id}/unhealthy</div>
<div class="endpoint put indent">/upstreams/{upstream name or id}/targets/{target or id}/unhealthy</div>
{:.indent}
Attributes | Description
Expand Down Expand Up @@ -2381,10 +2381,10 @@ return {
["DELETE"] = false,
-- exceptions for the healthcheck endpoints:
["/upstreams/:upstreams/targets/:targets/healthy"] = {
["POST"] = true,
["PUT"] = true,
},
["/upstreams/:upstreams/targets/:targets/unhealthy"] = {
["POST"] = true,
["PUT"] = true,
},
},

Expand Down

0 comments on commit b85b2ec

Please sign in to comment.