Kinetica   C#   API  Version 7.2.3.1
BulkInserterOptions Class Reference

Configuration options for the BulkInserter<T>. More...

Public Member Functions

 BulkInserterOptions ()
 Creates options with default values. More...
 
 BulkInserterOptions (int batchSize)
 Creates options with specified batch size. More...
 
BulkInserterOptions Clone ()
 Creates a copy of these options. More...
 

Properties

int BatchSize = 10_000 [get, set]
 Number of records per batch before triggering a flush. More...
 
int MaxInFlightBatches = 100 [get, set]
 Maximum number of batches that can be in-flight at once. More...
 
int NumStripes = Environment.ProcessorCount [get, set]
 Number of stripes per worker queue to reduce lock contention. More...
 
int MaxFlushWorkers = Math.Max(4, Environment.ProcessorCount * 2) [get, set]
 Maximum number of concurrent flush workers. More...
 
int MaxRetries = 3 [get, set]
 Maximum number of retry attempts for failed inserts. More...
 
int FlushIntervalSeconds = 0 [get, set]
 Interval in seconds between automatic flushes. More...
 
Dictionary< string, string > InsertOptions = new() [get, set]
 Options to pass to the insert_records API. More...
 
IBatchInsertionListenerBatchListener [get, set]
 Optional batch insertion listener for callbacks on batch completion. More...
 
Utils.? WorkerList WorkerList [get, set]
 Optional worker list override. More...
 
int MaxErrorQueueSize = 10_000 [get, set]
 Maximum number of errors to queue before discarding. More...
 
int CloseTimeoutMs = 60_000 [get, set]
 Timeout for close operations in milliseconds. More...
 

Detailed Description

Configuration options for the BulkInserter<T>.

Definition at line 9 of file BulkInserterOptions.cs.

Constructor & Destructor Documentation

◆ BulkInserterOptions() [1/2]

BulkInserterOptions.BulkInserterOptions ( )
inline

Creates options with default values.

Definition at line 80 of file BulkInserterOptions.cs.

◆ BulkInserterOptions() [2/2]

BulkInserterOptions.BulkInserterOptions ( int  batchSize)
inline

Creates options with specified batch size.

Definition at line 85 of file BulkInserterOptions.cs.

Member Function Documentation

◆ Clone()

BulkInserterOptions BulkInserterOptions.Clone ( )
inline

Creates a copy of these options.

Definition at line 93 of file BulkInserterOptions.cs.

Property Documentation

◆ BatchListener

IBatchInsertionListener? BulkInserterOptions.BatchListener
getset

Optional batch insertion listener for callbacks on batch completion.

Definition at line 58 of file BulkInserterOptions.cs.

◆ BatchSize

int BulkInserterOptions.BatchSize = 10_000
getset

Number of records per batch before triggering a flush.

Default: 10,000. Recommended range: 5,000 - 50,000.

Definition at line 15 of file BulkInserterOptions.cs.

◆ CloseTimeoutMs

int BulkInserterOptions.CloseTimeoutMs = 60_000
getset

Timeout for close operations in milliseconds.

Default: 60,000 (60 seconds).

Definition at line 75 of file BulkInserterOptions.cs.

◆ FlushIntervalSeconds

int BulkInserterOptions.FlushIntervalSeconds = 0
getset

Interval in seconds between automatic flushes.

Set to 0 to disable timed flushing. Default: 0 (disabled).

Definition at line 47 of file BulkInserterOptions.cs.

◆ InsertOptions

Dictionary<string, string> BulkInserterOptions.InsertOptions = new()
getset

Options to pass to the insert_records API.

Common options: UPDATE_ON_EXISTING_PK, IGNORE_EXISTING_PK, etc.

Definition at line 53 of file BulkInserterOptions.cs.

◆ MaxErrorQueueSize

int BulkInserterOptions.MaxErrorQueueSize = 10_000
getset

Maximum number of errors to queue before discarding.

Default: 10,000.

Definition at line 69 of file BulkInserterOptions.cs.

◆ MaxFlushWorkers

int BulkInserterOptions.MaxFlushWorkers = Math.Max(4, Environment.ProcessorCount * 2)
getset

Maximum number of concurrent flush workers.

Default: Environment.ProcessorCount * 2.

Definition at line 34 of file BulkInserterOptions.cs.

◆ MaxInFlightBatches

int BulkInserterOptions.MaxInFlightBatches = 100
getset

Maximum number of batches that can be in-flight at once.

Used for backpressure control. Default: 100.

Definition at line 22 of file BulkInserterOptions.cs.

◆ MaxRetries

int BulkInserterOptions.MaxRetries = 3
getset

Maximum number of retry attempts for failed inserts.

Default: 3.

Definition at line 40 of file BulkInserterOptions.cs.

◆ NumStripes

int BulkInserterOptions.NumStripes = Environment.ProcessorCount
getset

Number of stripes per worker queue to reduce lock contention.

Default: Environment.ProcessorCount (number of CPU cores).

Definition at line 28 of file BulkInserterOptions.cs.

◆ WorkerList

Utils.? WorkerList BulkInserterOptions.WorkerList
getset

Optional worker list override.

If null, workers are auto-discovered.

Definition at line 63 of file BulkInserterOptions.cs.


The documentation for this class was generated from the following file: