Skip to main content
Version: 2.3.12

Aerospike

Aerospike sink connector

Support Those Engines​

Spark
Flink
Seatunnel Zeta

License Compatibility Notice​

This connector depends on Aerospike Client Library which is licensed under AGPL 3.0.
When using this connector, you need to comply with AGPL 3.0 license terms.

Key Features​

Description​

Sink connector for Aerospike database.

Supported DataSource Info​

DatasourceSupported VersionsMaven
Aerospike4.4.17+Download

Data Type Mapping​

SeaTunnel Data TypeAerospike Data TypeStorage Format
STRINGSTRINGDirect string storage
INTINTEGER32-bit integer
BIGINTLONG64-bit integer
DOUBLEDOUBLE64-bit floating point
BOOLEANBOOLEANStored as true/false values
ARRAYBYTEARRAYOnly support byte array type
LISTLISTSupport generic list types
DATELONGConverted to epoch milliseconds
TIMESTAMPLONGConverted to epoch milliseconds

Note:

  • When using ARRAY type, SeaTunnel's array elements must be byte type
  • LIST type supports any element types that can be serialized
  • DATE/TIMESTAMP conversion uses system default time zone

Options​

NameTypeRequiredDefaultDescription
hoststringYes-Aerospike server hostname or IP address
portintNo3000Aerospike server port
namespacestringYes-Namespace in Aerospike
setstringYes-Set name in Aerospike
usernamestringNo-Username for authentication
passwordstringNo-Password for authentication
keystringYes-Field name to use as Aerospike primary key
bin_namestringNo-Bin name for storing data
data_formatstringNostringData storage format: map/string/kv
write_timeoutintNo200Write operation timeout in milliseconds
schema.fieldmapNo{}Field type mappings (e.g. {"name":"STRING","age":"INTEGER"})

data_format Options​

  • map: Store data as JSON map
  • string: Store data as JSON string
  • kv: Store each field as separate bin

Task Example​

Simple Example​

env {
parallelism = 2
job.mode = "BATCH"
}

source {
FakeSource {
row.num = 10
schema = {
fields {
id = "int"
name = "string"
age = "int"
address = "string"
}
}
}
}

sink {
Aerospike {
host = "localhost"
port = 3000
namespace = "test_namespace"
set = "user_data"
key = "id"
data_format = "map"
write_timeout = 300
schema.field = {
id = "INTEGER"
name = "STRING"
age = "INTEGER"
address = "STRING"
}
}
}

Changelog​

Change Log
ChangeCommitVersion
[Chore] fix typos filed -> field (#9757)https://github.com/apache/seatunnel/commit/e3e1c67d292.3.12
[Feature][Connector-V2] Add aerospike sink connector (#8821)https://github.com/apache/seatunnel/commit/68ebf15cf62.3.11