Skip to content

Commit 023f192

Browse files
committed
docs: Soften the claim that compressing a small body makes it larger
1 parent 758cdfe commit 023f192

2 files changed

Lines changed: 4 additions & 3 deletions

File tree

docs/02_concepts/13_http_compression.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ The client compresses request bodies using the compressor configured via the `co
1212

1313
## Minimum body size
1414

15-
Bodies smaller than 1024 bytes are sent as they are, with no `Content-Encoding` header. Such a body already fits in a single network packet, so compressing it saves no round trips, while the framing overhead of the compression format often makes it larger than the original. The JavaScript client uses the same threshold.
15+
Bodies smaller than 1024 bytes are sent as they are, with no `Content-Encoding` header. Such a body already fits in a single network packet, so compressing it saves no round trips and only costs CPU time. At the very small end, the framing overhead of the compression format can even make the body larger than the original.
1616

1717
## Configuration
1818

src/apify_client/_consts.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@
3939
"""Smallest request body, in bytes, that is worth compressing.
4040
4141
A body below this size already fits in a single network packet, so compressing it saves no round
42-
trips while still costing CPU time. Worse, the framing overhead of the compression format often
43-
makes such a body larger than the original. The JavaScript client uses the same threshold.
42+
trips while still costing CPU time. At the very small end, the framing overhead of the compression
43+
format can even make the body larger than the original. The JavaScript client uses the same
44+
threshold.
4445
"""

0 commit comments

Comments
 (0)