Skip to content

Commit

Permalink
Update default size threshold to 2048 bytes (#53)
Browse files Browse the repository at this point in the history
update default size threshold to 2048 bytes.

The idea is to prevent small payloads from being written as revisit records, as revisit records usually have a large playback cost. 2,048 bytes is seen as a better default for the time being.
  • Loading branch information
NGTmeaty committed Sep 28, 2024
1 parent 56091d4 commit 433a233
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions client.go
Original file line number Diff line number Diff line change
Expand Up @@ -98,9 +98,9 @@ func NewWARCWritingHTTPClient(HTTPClientSettings HTTPClientSettings) (httpClient
httpClient.dedupeOptions = HTTPClientSettings.DedupeOptions
httpClient.dedupeHashTable = new(sync.Map)

// Set default deduplication threshold to 1024 bytes
// Set default deduplication threshold to 2048 bytes
if httpClient.dedupeOptions.SizeThreshold == 0 {
httpClient.dedupeOptions.SizeThreshold = 1024
httpClient.dedupeOptions.SizeThreshold = 2048
}

// Configure HTTP status code skipping (usually 429)
Expand Down

0 comments on commit 433a233

Please sign in to comment.