Aerospike.Client NamespaceAerospike
Aerospike Client Library
Classes

  ClassDescription
Public classAdminPolicy
Policy attributes used for user administration commands.
Public classAerospikeClient
Instantiate an AerospikeClient object to access an Aerospike database cluster and perform database operations.

This client is thread-safe. One client instance should be used per cluster. Multiple threads should share this cluster instance.

Your application uses this class API to perform database operations such as writing and reading records, and selecting sets of records. Write operations include specialized functionality such as append/prepend and arithmetic addition.

Each record may have multiple bins, unless the Aerospike server nodes are configured as "single-bin". In "multi-bin" mode, partial records may be written or read by specifying the relevant subset of bins.

Public classAerospikeException
Aerospike exceptions that can be thrown from the client.
Public classAerospikeException CommandRejected
Exception thrown when asynchronous command was rejected because the max concurrent database commands have been exceeded.
Public classAerospikeException Connection
Exception thrown when client can't connect to the server.
Public classAerospikeException InvalidNode
Exception thrown when chosen node is not active.
Public classAerospikeException Parse
Exception thrown when client can't parse data returned from server.
Public classAerospikeException QueryTerminated
Exception thrown when query was terminated prematurely.
Public classAerospikeException ScanTerminated
Exception thrown when scan was terminated prematurely.
Public classAerospikeException Serialize
Exception thrown when Java serialization error occurs.
Public classAerospikeException Timeout
Exception thrown when database request expires before completing.
Public classAsyncClient
Asynchronous Aerospike client.

Your application uses this class to perform asynchronous database operations such as writing and reading records, and selecting sets of records. Write operations include specialized functionality such as append/prepend and arithmetic addition.

This client is thread-safe. One client instance should be used per cluster. Multiple threads should share this cluster instance.

Each record may have multiple bins, unless the Aerospike server nodes are configured as "single-bin". In "multi-bin" mode, partial records may be written or read by specifying the relevant subset of bins.

Public classAsyncClientPolicy
Asynchronous client policy configuration.
Public classAsyncNode
Asynchronous server node representation.
Public classBaseTask
Task used to poll for server task completion.
Public classBatchPolicy
Configuration variables for multi-record get and exist requests.
Public classBin
Column name/value pair.
Public classClientPolicy
Client initialization arguments.
Public classClusterStats
Cluster statistics.
Public classConnectionStats
Connection statistics.
Public classExecuteTask
Task used to poll for long running execute job completion.
Public classFilter
Query filter used to narrow down query results.
Public classFormatter
This class contains the default formatter used when serializing objects to bytes.
Public classHost
Host name/port of database server.
Public classIndexTask
Task used to poll for long running create index completion.
Public classInfo
Access server's info monitoring protocol.

The info protocol is a name/value pair based system, where an individual database server node is queried to determine its configuration and status. The list of supported names can be found at:

Onlinehttps://www.aerospike.com/docs/reference/info/index.html

Public classInfoPolicy
Policy attributes used for info commands.
Public classJoin
Client-side join definition. The left record must contain a bin with a list of keys. That list will be used to retreive other records in the given namespace and set.
Public classKey
Unique record identifier. Records can be identified using a specified namespace, an optional set name, and a user defined key which must be unique within a set. Records can also be identified by namespace/digest which is the combination used on the server.
Public classKeyRecord
Container object for key identifier and record data.
Public classListOperation
List bin operations. Create list operations used by client operate command. List operations support negative indexing. If the index is negative, the resolved index starts backwards from end of list.

Index/Range examples:

  • Index 0: First item in list.
  • Index 4: Fifth item in list.
  • Index -1: Last item in list.
  • Index -3: Third to last item in list.
  • Index 1 Count 2: Second and third items in list.
  • Index -3 Count 3: Last three items in list.
  • Index -5 Count 4: Range between fifth to last item to second to last item inclusive.

If an index is out of bounds, a parameter error will be returned. If a range is partially out of bounds, the valid part of the range will be returned.

Public classListPolicy
List policy directives when creating a list and writing list items.
Public classLog
Aerospike client logging facility. Logs can be filtered and message callbacks can be defined to control how log messages are written.
Public classLuaConfig
Lua static configuration variables. These variables apply to all AerospikeClient instances in a single process.
Public classMapOperation
Unique key map bin operations. Create map operations used by the client operate command. The default unique key map is unordered.

All maps maintain an index and a rank. The index is the item offset from the start of the map, for both unordered and ordered maps. The rank is the sorted index of the value component. Map supports negative indexing for index and rank.

Index examples:

  • Index 0: First item in map.
  • Index 4: Fifth item in map.
  • Index -1: Last item in map.
  • Index -3: Third to last item in map.
  • Index 1 Count 2: Second and third items in map.
  • Index -3 Count 3: Last three items in map.
  • Index -5 Count 4: Range between fifth to last item to second to last item inclusive.

Rank examples:

  • Rank 0: Item with lowest value rank in map.
  • Rank 4: Fifth lowest ranked item in map.
  • Rank -1: Item with highest ranked value in map.
  • Rank -3: Item with third highest ranked value in map.
  • Rank 1 Count 2: Second and third lowest ranked items in map.
  • Rank -3 Count 3: Top three ranked items in map.

Public classMapPolicy
Map policy directives when creating a map and writing map items.
Public classNode
Server node representation. This class manages server node connections and health status.
Public classNodeStats
Node statistics.
Public classOperation
Database operation definition. The class is used in client's operate() method.
Public classPolicy
Transaction policy attributes used in all database commands.
Public classPredExp
Predicate expression filter. Predicate expression filters are applied on the query results on the server. Predicate expression filters may occur on any bin in the record.

This is an experimental API and subject to change.

Public classPrivilege
User privilege.
Public classQueryPolicy
Container object for policy attributes used in query operations.
Public classRandomShift
Generate pseudo random numbers using xorshift128+ algorithm. This class is not thread-safe and should be instantiated once per thread.
Public classRecord
Container object for records. Records are equivalent to rows.
Public classRecordSet
This class manages record retrieval from queries. Multiple threads will retrieve records from the server nodes and put these records on the queue. The single user thread consumes these records from the queue.
Public classRegexFlag
Regex bit flags.
Public classRegisterTask
Task used to poll for UDF registration completion.
Public classResultCode
Database operation error codes.
Public classResultSet
This class manages result retrieval from queries. Multiple threads will retrieve results from the server nodes and put these results on the queue. The single user thread consumes these results from the queue.
Public classRole
Role definition.
Public classScanPolicy
Container object for optional parameters used in scan operations.
Public classStatement
Query statement parameters.
Public classUser
User and assigned roles.
Public classValue
Polymorphic value classes used to efficiently serialize objects into the wire protocol.
Public classWritePolicy
Container object for policy attributes used in write operations. This object is passed into methods where database writes can occur.
Interfaces

  InterfaceDescription
Public interfaceBatchListListener
Asynchronous result notifications for batch get commands with variable bins per key. The result is sent in a single list.
Public interfaceBatchSequenceListener
Asynchronous result notifications for batch get commands with variable bins per key. The results are sent one batch record at a time.
Public interfaceDeleteListener
Asynchronous result notifications for delete commands.
Public interfaceExistsArrayListener
Asynchronous result notifications for batch exists commands. The result is sent in a single array.
Public interfaceExistsListener
Asynchronous result notifications for exists commands.
Public interfaceExistsSequenceListener
Asynchronous result notifications for batch exists commands. The results are sent one record at a time.
Public interfaceInfoListener
Asynchronous info command result notification.
Public interfaceRecordArrayListener
Asynchronous result notifications for batch get commands. The result is sent in a single array.
Public interfaceRecordListener
Asynchronous result notifications for get or operate commands.
Public interfaceRecordSequenceListener
Asynchronous result notifications for batch get and scan commands. The results are sent one record at a time.
Public interfaceWriteListener
Asynchronous result notifications for put, append, prepend, add, delete and touch commands.
Delegates

  DelegateDescription
Public delegateLog Callback
The log is written to the Windows Event Log by default. The caller can override this and set a private method which will be called for each log entry.
Public delegateScanCallback
This method will be called for each record returned from a scan. The user may throw a exception if the scan should be aborted. If any exception is thrown, parallel scan threads to other nodes will also be terminated and the exception will be propagated back through the initiating scan call.

Multiple threads will likely be calling scanCallback in parallel. Therefore, your scanCallback implementation should be thread safe.

Enumerations

  EnumerationDescription
Public enumerationAuthMode
Authentication mode when user/password is defined.
Public enumerationCommitLevel
Desired consistency guarantee when committing a transaction on the server.
Public enumerationGenerationPolicy
How to handle record writes based on record generation.
Public enumerationIndexCollectionType
Secondary index collection type.
Public enumerationIndexType
Underlying data type of secondary index.
Public enumerationLanguage
User defined function languages.
Public enumerationListOrder
List storage order.
Public enumerationListReturnType
List return type. Type of data to return when selecting or removing items from the list.
Public enumerationListSortFlags
List sort flags
Public enumerationListWriteFlags
List write bit flags.
Public enumerationLog Level
Log escalation level.
Public enumerationMapOrder
Map storage order.
Public enumerationMapReturnType
Map return type. Type of data to return when selecting or removing items from the map.
Public enumerationMapWriteFlags
Map write bit flags. Requires server versions >= 4.3.
Public enumerationMapWriteMode
Unique key map write type. This enum should only be used for server versions < 4.3. are recommended for server versions >= 4.3.
Public enumerationMaxCommandAction
How to handle cases when the asynchronous maximum number of concurrent database commands have been exceeded.
Public enumerationOperation Type
Public enumerationPriority
Priority of operations on database server.
Public enumerationPrivilegeCode
Permission codes define the type of permission granted for a user's role.
Public enumerationReadModeAP
Read policy for AP (availability) namespaces.

How duplicates should be consulted in a read operation. Only makes a difference during migrations and only applicable in AP mode.

Public enumerationReadModeSC
Read policy for SC (strong consistency) namespaces.

Determines SC read consistency options.

Public enumerationRecordExistsAction
How to handle writes when the record already exists.
Public enumerationReplica
Defines algorithm used to determine the target node for a command. The replica algorithm only affects single record commands. Batch, scan and query are not affected by replica algorithm.