You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: site/content/how-to/monitoring/troubleshooting.md
+3-3Lines changed: 3 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -52,14 +52,14 @@ If you receive the following error:
52
52
</html>
53
53
```
54
54
55
-
or see the following error message in the NGINX logs:
55
+
Or view the following error message in the NGINX logs:
56
56
57
57
```text
58
58
2024/05/30 21:48:22 [error] 138#138: *43 client intended to send too large body: 112 bytes, client: 127.0.0.1, server: cafe.example.com, request: "POST /coffee HTTP/1.1", host: "cafe.example.com:8080"
59
59
```
60
60
61
-
the request body exceeds the [client_max_body_size](https://nginx.org/en/docs/http/ngx_http_core_module.html#client_max_body_size).
61
+
The request body exceeds the [client_max_body_size](https://nginx.org/en/docs/http/ngx_http_core_module.html#client_max_body_size).
62
62
63
63
#### Resolution
64
64
65
-
You can configure the `client_max_body_size` using the `ClientSettingsPolicy` API. See this [guide]({{< relref "how-to/traffic-management/client-settings.md" >}}) for instructions.
65
+
You can configure the `client_max_body_size` using the `ClientSettingsPolicy` API. Read the [Client Settings Policy]({{< relref "how-to/traffic-management/client-settings.md" >}}) documentation for more information.
Copy file name to clipboardExpand all lines: site/content/how-to/traffic-management/client-settings.md
+9-9Lines changed: 9 additions & 9 deletions
Original file line number
Diff line number
Diff line change
@@ -62,7 +62,7 @@ This guide will show you how to use the `ClientSettingsPolicy` API to configure
62
62
63
63
- Test the configuration:
64
64
65
-
We can send traffic to the coffee and tea applications using the external IP address and port for NGINX Gateway Fabric.
65
+
You can send traffic to the coffee and tea applications using the external IP address and port for NGINX Gateway Fabric.
66
66
67
67
{{< note >}}If you have a DNS record allocated for `cafe.example.com`, you can send the request directly to that hostname, without needing to resolve.{{< /note >}}
68
68
@@ -96,7 +96,7 @@ This guide will show you how to use the `ClientSettingsPolicy` API to configure
96
96
97
97
### Set a default client max body size for the Gateway
98
98
99
-
To set a default client max body size for the Gateway we created in the setup, create the following `ClientSettingsPolicy`:
99
+
To set a default client max body size for the Gateway created during setup, add the following `ClientSettingsPolicy`:
100
100
101
101
```yaml
102
102
kubectl apply -f - <<EOF
@@ -117,7 +117,7 @@ EOF
117
117
This `ClientSettingsPolicy` targets the Gateway we created in the setup by specifying it in the `targetRef` field. It limits the max client body size to 50 bytes.
118
118
Since this policy is applied to the Gateway, it will affect all HTTPRoutes and GRPCRoutes attached to the Gateway. All requests to the coffee and tea applications must have a request body of less than or equal to 50 bytes.
119
119
120
-
Let's verify that the `ClientSettingsPolicy` is Accepted:
120
+
Verify that the `ClientSettingsPolicy` is Accepted:
Next, let's test that the policy is configured by sending a POST request to the coffee and tea applications exceeding the client's max body size of 50 bytes.
147
+
Next, test that the policy is configured by sending a POST request to the coffee and tea applications exceeding the client's max body size of 50 bytes.
148
148
149
149
150
150
```shell
@@ -163,13 +163,13 @@ You should receive the following error:
163
163
</html>
164
164
```
165
165
166
-
Now, let's try again with a payload that's less than the 50 byte limit:
166
+
Try again with a payload that's less than the 50 byte limit:
167
167
168
168
```shell
169
169
curl --resolve cafe.example.com:$GW_PORT:$GW_IP http://cafe.example.com:$GW_PORT/coffee -X POST --data "this payload is under fifty bytes"
170
170
```
171
171
172
-
This time, we should receive a response from coffee:
172
+
This time, you should receive a response from coffee:
173
173
174
174
```text
175
175
Server address: 10.244.0.6:8080
@@ -201,7 +201,7 @@ EOF
201
201
This `ClientSettingsPolicy` targets the tea HTTPRoute we created in the setup by specifying it in the `targetRef` field. It sets the max client body size to 75 bytes.
202
202
Since this policy is applied to the tea HTTPRoute, it will only affect the tea HTTPRoute, and the `ClientSettingsPolicy` we created in the previous step will affect all other routes attached to the Gateway. This means that the coffee app still has a client max body size of 50 bytes, and the tea app has a max body size of 75.
203
203
204
-
Let's verify that the `ClientSettingsPolicy` is Accepted:
204
+
Verify that the `ClientSettingsPolicy` is Accepted:
Notice that the Ancestor Ref in the status is the tea HTTPRoute instead of the Gateway.
232
232
233
-
Next, let's test that the policy is configured by sending a POST request to the tea application with a request body size greater than 50 bytes.
233
+
Next, test that the policy is configured by sending a POST request to the tea application with a request body size greater than 50 bytes.
234
234
235
235
```shell
236
236
curl --resolve cafe.example.com:$GW_PORT:$GW_IP http://cafe.example.com:$GW_PORT/tea -X POST --data "this payload is greater than fifty bytes but less than seventy five"
0 commit comments