@@ -53,6 +53,7 @@ use super::node::{InternalKnownNode, KnownNode};
5353use super :: partitioner:: PartitionerName ;
5454use super :: query_result:: MaybeFirstRowError ;
5555use super :: query_result:: RowsError ;
56+ use super :: timestamp_generator:: TimestampGenerator ;
5657use super :: topology:: UntranslatedPeer ;
5758use super :: { NodeRef , SelfIdentity } ;
5859use crate :: frame:: response:: result;
@@ -270,6 +271,10 @@ pub struct SessionConfig {
270271 /// Generally, this options is best left as default (false).
271272 pub disallow_shard_aware_port : bool ,
272273
274+ // Timestamp generator used for generating timestamps on the client-side
275+ // If None, server-side timestamps are used.
276+ pub timestamp_generator : Option < Arc < dyn TimestampGenerator > > ,
277+
273278 /// If empty, fetch all keyspaces
274279 pub keyspaces_to_fetch : Vec < String > ,
275280
@@ -382,6 +387,7 @@ impl SessionConfig {
382387 connect_timeout : Duration :: from_secs ( 5 ) ,
383388 connection_pool_size : Default :: default ( ) ,
384389 disallow_shard_aware_port : false ,
390+ timestamp_generator : None ,
385391 keyspaces_to_fetch : Vec :: new ( ) ,
386392 fetch_schema_metadata : true ,
387393 keepalive_interval : Some ( Duration :: from_secs ( 30 ) ) ,
0 commit comments