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

Autodocs 3.9 #8200

Merged
merged 2 commits into from
Dec 4, 2024
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
29 changes: 29 additions & 0 deletions app/_src/gateway/plugin-development/pdk/kong.client.tls.md
Original file line number Diff line number Diff line change
Expand Up @@ -193,3 +193,32 @@ Overrides the client's verification result generated by the log serializer.
``` lua
kong.client.tls.set_client_verify("FAILED:unknown CA")
```

{% if_version lte:3.9.x %}

## kong.client.tls.disable_http2_alpn()

Prevents the TLS handshake from negotiating HTTP/2 ALPN.
if successful, the TLS handshake will not negotiate HTTP/2 ALPN to turn to HTTP1.1.


**Phases**

* client_hello

**Returns**

1. `true|nil`: Returns `true` if successful, `nil` if it fails.

1. `nil|err`: Returns `nil` if successful, or an error message if it fails.


**Usage**

``` lua
local res, err = kong.client.tls.disable_http2_alpn()
if not res then
-- do something with err
end
```
{% endif_version %}
2 changes: 1 addition & 1 deletion app/_src/gateway/plugin-development/pdk/kong.log.md
Original file line number Diff line number Diff line change
Expand Up @@ -384,7 +384,7 @@ assert(kong.log.serialize().my_new_value == nil)

-- Dots in the key are interpreted as table accesses
kong.log.set_serialize_value("my.new.value", 4)
assert(kong.log.serialize().my.new_value == 4)
assert(kong.log.serialize().my.new.value == 4)
```


Expand Down
29 changes: 29 additions & 0 deletions app/_src/gateway/plugin-development/pdk/kong.service.request.md
Original file line number Diff line number Diff line change
Expand Up @@ -214,6 +214,35 @@ kong.service.request.set_query({
```


{% if_version gte:3.9.x %}

## kong.service.request.clear_query_arg(name)

Removes all occurrences of the specified query string argument
from the request to the Service. The order of query string
arguments is retained.


**Phases**

* `rewrite`, `access`

**Parameters**

* **name** (`string`):

**Returns**

* Nothing; throws an error on invalid inputs.


**Usage**

``` lua
kong.service.request.clear_query_arg("foo")
```

{% endif_version %}

## kong.service.request.set_header(header, value)

Expand Down
35 changes: 35 additions & 0 deletions app/_src/gateway/reference/cli.md
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,19 @@ The available commands are:
seconds).
default: 60

{% if_version gte:3.9.x %}
profiling memory-analyzer <start|status>
Trigger memory analyzer and generate
memory profiling data.

--timeout (optional number) Timeout for memory analyzer in seconds.
Default is 120 seconds.

--pid (optional number) Specific worker process ID to analyze.
If not provided, the current worker
process will be used.
{% endif_version %}

log_level get Get the logging level.
{% if_version gte:3.8.x %}
status Get the status of the Kong node.
Expand Down Expand Up @@ -176,6 +189,28 @@ EXIT CODES
```
{% endif_version %}

{% if_version gte:3.9.x %}
---


### kong drain

```
Usage: kong drain [OPTIONS]

Make status listeners(`/status/ready`) return 503 Service Unavailable.

Example usage:
kong drain

Options:
-c,--conf (optional string) configuration file
-p,--prefix (optional string) override prefix directory

```

{% endif_version %}

---


Expand Down