docs/src/main/sphinx/admin/properties-client-protocol.md
The following sections provide a reference for all properties related to the client protocol.
(prop-protocol-spooling)=
The following properties are related to the .
protocol.spooling.enabledEnable the support for the client . The protocol is used if client drivers and applications request usage, otherwise the direct protocol is used automatically.
protocol.spooling.shared-secret-keyA required 256 bit, base64-encoded secret key used to secure spooled metadata exchanged with the client. Create a suitable value with the following command:
openssl rand -base64 32
protocol.spooling.retrieval-modeDetermines 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.enabledActivate support for using uncompressed JSON encoding for spooled segments.
protocol.spooling.encoding.json+zstd.enabledActivate support for using JSON encoding with Zstandard compression for spooled segments.
protocol.spooling.encoding.json+lz4.enabledActivate support for using JSON encoding with LZ4 compression for spooled segments.
protocol.spooling.encoding.compression.thresholdThreshold for enabling compression with larger segments.
protocol.spooling.initial-segment-size8MB1kB128MBspooling_initial_segment_sizeInitial size of the spooled segments.
protocol.spooling.max-segment-size16MB1kB128MBspooling_max_segment_sizeMaximum size for each spooled segment.
protocol.spooling.inlining.enabledAllow spooled protocol to inline initial rows to decrease time to return the first row.
protocol.spooling.inlining.max-rows100011000000spooling_inlining_max_rowsMaximum number of rows to inline per worker.
protocol.spooling.inlining.max-size128kB1kB1MBspooling_inlining_max_sizeMaximum size of rows to inline per worker.
(prop-spooling-file-system)=
The following properties are used to configure the object storage used with the .
fs.azure.enabledActivate for spooling segments.
fs.s3.enabledActivate for spooling segments.
fs.gcs.enabledActivate for spooling segments.
fs.locationThe 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 follow these patterns:
Examples:
s3://my-spooling-bucket/my-segments/abfss://[email protected]/my-segments/gs://my-spooling-bucket/my-segments/:::{note}
For Azure Storage, use the ABFS format with hierarchical namespace enabled.
The legacy WASB format (wasbs:// or wasb://) is also supported but deprecated.
:::
:::{caution} The specified object storage location must not be used for spooling for another Trino cluster or any object storage catalog. When using the same object storage for multiple services, you must use separate locations for each one. For example:
s3://my-spooling-bucket/my-segments/cluster1-spooling/s3://my-spooling-bucket/my-segments/cluster2-spooling/s3://my-spooling-bucket/my-segments/iceberg-catalog/
:::fs.segment.ttlMaximum available time for the client to retrieve spooled segment before it expires and is pruned.
fs.segment.direct.ttlMaximum available time for the client to retrieve spooled segment using the pre-signed URI.
fs.segment.encryptionEncrypt segments with ephemeral keys using Server-Side Encryption with Customer key (SSE-C).
fs.segment.explicit-ackActivate pruning of segments on client acknowledgment of a successful read of each segment.
fs.segment.pruning.enabledActivate periodic pruning of expired segments.
fs.segment.pruning.intervalInterval to prune expired segments.
fs.segment.pruning.batch-sizeNumber of expired segments to prune as a single batch operation.
(prop-protocol-shared)=
The following properties are related to the and the , formerly named the V1 protocol.
protocol.v1.prepared-statement-compression.length-thresholdPrepared statements that are submitted to Trino for processing, and are longer than the value of this property, are compressed for transport via the HTTP header to improve handling, and to avoid failures due to hitting HTTP header size limits.
protocol.v1.prepared-statement-compression.min-gainPrepared statement compression is not applied if the size gain is less than the configured value. Smaller statements do not benefit from compression, and are left uncompressed.