Client protocol properties#
The following sections provide a reference for all properties related to the client protocol.
Spooling protocol properties#
The following properties are related to the Spooling protocol.
protocol.spooling.enabled
#
Type: boolean
Default value:
true
Enable the support for the client Spooling protocol. The protocol is used if client drivers and applications request usage, otherwise the direct protocol is used automatically.
protocol.spooling.retrieval-mode
#
Type: string
Default value:
STORAGE
Determines how the client retrieves the segment. Following are possible values:
STORAGE
- client accesses the storage directly with the pre-signed URI. Uses one client HTTP request per data segment.COORDINATOR_STORAGE_REDIRECT
- client first accesses the coordinator, which redirects the client to the storage with the pre-signed URI. Uses two client HTTP requests per data segment.COORDINATOR_PROXY
- client accesses the coordinator and gets data segment through it. Uses one client HTTP request per data segment, but requires a coordinator HTTP request to the storage.WORKER_PROXY
- client accesses the coordinator, which redirects to an available worker node. It fetches the data from the storage and provides it to the client. Uses two client HTTP requests, and requires a worker request to the storage.
protocol.spooling.encoding.json.enabled
#
Type: boolean
Default value:
true
Activate support for using uncompressed JSON encoding for spooled segments.
protocol.spooling.encoding.json+zstd.enabled
#
Type: boolean
Default value:
true
Activate support for using JSON encoding with Zstandard compression for spooled segments.
protocol.spooling.encoding.json+lz4.enabled
#
Type: boolean
Default value:
true
Activate support for using JSON encoding with LZ4 compression for spooled segments.
protocol.spooling.encoding.compression.threshold
#
Type: data size
Default value:
8KB
Minimum value:
1KB
Maximum value:
4MB
Threshold for enabling compression with larger segments.
protocol.spooling.initial-segment-size
#
Type: data size
Default value: 8MB
Initial size of the spooled segments.
protocol.spooling.maximum-segment-size
#
Type: data size
Default value: 16MB
Maximum size for each spooled segment.
protocol.spooling.inlining.enabled
#
Type: boolean
Default value:
true
Allow spooled protocol to inline initial rows to decrease time to return the first row.
protocol.spooling.inlining.max-rows
#
Type: integer
Default value: 1000
Maximum number of rows to inline per worker.
protocol.spooling.inlining.max-size
#
Type: data size
Default value: 128kB
Maximum size of rows to inline per worker.
Spooling file system properties#
The following properties are used to configure the object storage used with the Spooling protocol.
fs.azure.enabled
#
Type: boolean
Default value:
false
Activate Azure Storage file system support for spooling segments.
fs.s3.enabled
#
Type: boolean
Default value:
false
Activate S3 file system support for spooling segments.
fs.gcs.enabled
#
Type: boolean
Default value:
false
Activate Google Cloud Storage file system support for spooling segments.
fs.location
#
Type: string
The object storage location to use for spooling segments. Must be accessible by
the coordinator and all workers. With the protocol.spooling.retrieval-mode
retrieval modes STORAGE
and COORDINATOR_STORAGE_REDIRECT
the location must
also be accessible by all clients. Valid location values vary by object storage
type, and typically follow a pattern of scheme://bucketName/path/
.
Examples:
s3://my-spooling-bucket/my-segments/
Caution
When using the same object storage for spooling from multiple Trino clusters, you must use separate locations for each cluster. For example:
s3://my-spooling-bucket/my-segments/cluster1
s3://my-spooling-bucket/my-segments/cluster2
fs.segment.ttl
#
Type: duration
Default value:
12h
Maximum available time for the client to retrieve spooled segment before it expires and is pruned.
fs.segment.direct.ttl
#
Type: duration
Default value:
1h
Maximum available time for the client to retrieve spooled segment using the pre-signed URI.
fs.segment.encryption
#
Type: boolean
Default value:
true
Encrypt segments with ephemeral keys using Server-Side Encryption with Customer key (SSE-C).
fs.segment.explicit-ack
#
Type: boolean
Default value:
true
Activate pruning of segments on client acknowledgment of a successful read of each segment.
fs.segment.pruning.enabled
#
Type: boolean
Default value:
true
Activate periodic pruning of expired segments.
fs.segment.pruning.interval
#
Type: duration
Default value:
5m
Interval to prune expired segments.
fs.segment.pruning.batch-size
#
Type: integer
Default value:
250
Number of expired segments to prune as a single batch operation.