Skip to main content

IcebergReaderConfig

Struct IcebergReaderConfig 

Source
pub struct IcebergReaderConfig {
Show 15 fields pub mode: IcebergIngestMode, pub transaction_mode: IcebergTransactionMode, pub timestamp_column: Option<String>, pub snapshot_filter: Option<String>, pub snapshot_id: Option<i64>, pub datetime: Option<String>, pub metadata_location: Option<String>, pub table_name: Option<String>, pub catalog_type: Option<IcebergCatalogType>, pub num_parsers: u32, pub max_retries: Option<u32>, pub glue_catalog_config: GlueCatalogConfig, pub rest_catalog_config: RestCatalogConfig, pub s3tables_catalog_config: S3TablesCatalogConfig, pub fileio_config: HashMap<String, String>,
}
Expand description

Iceberg input connector configuration.

Fields§

§mode: IcebergIngestMode

Table read mode.

§transaction_mode: IcebergTransactionMode

Transaction mode.

Determines how the connector breaks up its input into Feldera transactions. See IcebergTransactionMode. Defaults to IcebergTransactionMode::None.

§timestamp_column: Option<String>

Table column that serves as an event timestamp.

When this option is specified, and mode is one of snapshot or snapshot_and_follow, table rows are ingested in the timestamp order, respecting the LATENESS property of the column: each ingested row has a timestamp no more than LATENESS time units earlier than the most recent timestamp of any previously ingested row. The ingestion is performed by partitioning the table into timestamp ranges of width LATENESS. Each range is processed sequentially, in increasing timestamp order.

§Example

Consider a table with timestamp column of type TIMESTAMP and lateness attribute INTERVAL 1 DAY. Assuming that the oldest timestamp in the table is 2024-01-01T00:00:00``, the connector will fetch all records with timestamps from 2024-01-01, then all records for 2024-01-02, 2024-01-03`, etc., until all records in the table have been ingested.

§Requirements

  • The timestamp column must be of a supported type: integer, DATE, or TIMESTAMP.
  • The timestamp column must be declared with non-zero LATENESS.
  • For efficient ingest, the table must be optimized for timestamp-based queries using partitioning, Z-ordering, or liquid clustering.
§snapshot_filter: Option<String>

Optional row filter.

This option is only valid when mode is set to snapshot or snapshot_and_follow.

When specified, only rows that satisfy the filter condition are included in the snapshot. The condition must be a valid SQL Boolean expression that can be used in the where clause of the select * from snapshot where ... query.

This option can be used to specify the range of event times to include in the snapshot, e.g.: ts BETWEEN '2005-01-01 00:00:00' AND '2010-12-31 23:59:59'.

§snapshot_id: Option<i64>

Optional snapshot id.

When this option is set, the connector finds the specified snapshot of the table. In snapshot and snapshot_and_follow modes, it loads this snapshot. In follow and snapshot_and_follow modes, it follows table updates after this snapshot.

Note: at most one of snapshot_id and datetime options can be specified. When neither of the two options is specified, the latest committed version of the table is used.

§datetime: Option<String>

Optional timestamp for the snapshot in the ISO-8601/RFC-3339 format, e.g., “2024-12-09T16:09:53+00:00”.

When this option is set, the connector finds and opens the snapshot of the table as of the specified point in time (based on the server time recorded in the transaction log, not the event time encoded in the data). In snapshot and snapshot_and_follow modes, it retrieves this snapshot. In follow and snapshot_and_follow modes, it follows transaction log records after this snapshot.

Note: at most one of snapshot_id and datetime options can be specified. When neither of the two options is specified, the latest committed version of the table is used.

§metadata_location: Option<String>

Location of the table metadata JSON file.

This propery is used to access an Iceberg table without a catalog. It is mutually exclusive with the catalog_type property.

§table_name: Option<String>

Specifies the Iceberg table name in the “namespace.table” format.

This option is applicable when an Iceberg catalog is configured using the catalog_type property.

§catalog_type: Option<IcebergCatalogType>

Specifies the catalog type used to access the Iceberg table.

Supported options include “rest”, “glue”, and “s3tables”. This property is mutually exclusive with metadata_location.

§num_parsers: u32

The number of parallel parsing tasks the connector uses to process data read from the table. Increasing this value can enhance performance by allowing more concurrent processing. Recommended range: 1-10. The default is 4.

§max_retries: Option<u32>

Maximum number of retries for reading the table snapshot.

When reading the snapshot fails partway through, for example because an object-store read times out or is throttled, the connector retries the entire read with exponential backoff. This is in addition to the lower-level retries performed by the object-store client.

Defaults to unlimited retries. Set to 0 to disable retries.

§glue_catalog_config: GlueCatalogConfig§rest_catalog_config: RestCatalogConfig§s3tables_catalog_config: S3TablesCatalogConfig§fileio_config: HashMap<String, String>

Storage options for configuring backend object store.

See the list of available options in PyIceberg documentation.

Implementations§

Source§

impl IcebergReaderConfig

Source

pub fn validate_catalog_config(&self) -> Result<(), String>

Source

pub fn validate_glue_catalog_config(&self) -> Result<(), String>

Reject Glue catalog config properties when ‘catalog_type’ isn’t set to ‘glue’.

Source

pub fn validate_rest_catalog_config(&self) -> Result<(), String>

Reject Rest catalog config when ‘catalog_type’ isn’t set to ‘rest’.

Source

pub fn validate_s3tables_catalog_config(&self) -> Result<(), String>

Reject S3 Tables catalog config when ‘catalog_type’ isn’t set to ‘s3tables’.

Source

pub fn validate_table_name(&self) -> Result<(), String>

Table name must be configured iff ‘catalog_type’ is set.

Source

pub fn validate_metadata_location(&self) -> Result<(), String>

‘metadata_location’ must be configured iff ‘catalog_type’ is set.

Source§

impl IcebergReaderConfig

Source

pub fn max_retries(&self) -> u32

Maximum number of high-level operation retries. Defaults to unlimited.

Source

pub fn snapshot(&self) -> bool

true if the configuration requires taking an initial snapshot of the table.

Source

pub fn follow(&self) -> bool

true if the configuration requires following the transaction log of the table (possibly after taking an initial snapshot).s

Trait Implementations§

Source§

impl Clone for IcebergReaderConfig

Source§

fn clone(&self) -> IcebergReaderConfig

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for IcebergReaderConfig

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'de> Deserialize<'de> for IcebergReaderConfig

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl Eq for IcebergReaderConfig

Source§

impl PartialEq for IcebergReaderConfig

Source§

fn eq(&self, other: &IcebergReaderConfig) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl Serialize for IcebergReaderConfig

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl StructuralPartialEq for IcebergReaderConfig

Source§

impl<'__s> ToSchema<'__s> for IcebergReaderConfig

Source§

fn schema() -> (&'__s str, RefOr<Schema>)

Return a tuple of name and schema or reference to a schema that can be referenced by the name or inlined directly to responses, request bodies or parameters.
Source§

fn aliases() -> Vec<(&'__s str, Schema)>

Optional set of alias schemas for the ToSchema::schema. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,

Source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

Source§

fn equivalent(&self, key: &K) -> bool

Checks if this value is equivalent to the given key. Read more
Source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

Source§

fn equivalent(&self, key: &K) -> bool

Compare self to key and return true if they are equal.
Source§

impl<T> ErasedDestructor for T
where T: 'static,

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> Serialize for T
where T: Serialize + ?Sized,

Source§

fn erased_serialize(&self, serializer: &mut dyn Serializer) -> Result<Ok, Error>

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more