Skip to content

Incompatible API changes

For the complete documentation index see: llms.txt

All documentation pages available in markdown.

Version 8.9.0

v8.8.0 inserted TxnStateCommitFailed in the middle of the TxnState enum, which changed the numeric values of TxnStateCommitted and TxnStateAborted. v8.9.0 restores the original enum ordering (CLIENT-5260) and keeps TxnStateCommitFailed as the last value in the enum. Rebuild and redeploy any code that compares TxnState constants or persists their integer values.

Version 8.8.0

The batch SendKey behavior described here first shipped in v8.8.0, which was retracted. Use v8.9.0.

Old behavior

Before union semantics, the client resolved batch SendKey from a single policy on each batch code path. Setting SendKey on one batch write policy did not necessarily enable SendKey on the wire for every batch write, delete, or UDF operation.

New behavior

For batch writes, deletes, and UDFs, SendKey is enabled when any applicable policy sets it: the parent BatchPolicy passed to the command (or Client.DefaultBatchPolicy when you pass nil), the client defaults DefaultBatchWritePolicy, DefaultBatchDeletePolicy, and DefaultBatchUDFPolicy, the per-record policies on BatchWrite, BatchDelete, and BatchUDF, or dynamic configuration. Batch reads never send the user key.

To enable SendKey for all writes to a cluster, set defaults on the connected client (or use dynamic configuration):

client, err := aerospike.NewClient("127.0.0.1", 3000)
if err != nil {
log.Fatal(err)
}
client.DefaultWritePolicy.SendKey = true // Single-record writes.
client.DefaultBatchPolicy.SendKey = true // Parent batch policy when you pass nil to BatchOperate.
client.DefaultBatchWritePolicy.SendKey = true // Per-key batch writes.
client.DefaultBatchDeletePolicy.SendKey = true // Batch deletes.
client.DefaultBatchUDFPolicy.SendKey = true // Batch UDFs.

Version 2.0.0

Many long-standing semantic and syntactic changes

Returns ErrKeyNotFound error for when a key was not found instead of return no error and a nil Record

  • Get/Put/Touch/Operate and ExecuteUDF commands will return an ErrKeyNotFound error when the key does not exist in the database. The old behavior used to be not to return an error, but have an empty Record.Bins.

Other Changes

  • Renames Statement.Addfilter to Statement.SetFilter, change the name and type of Statement.Filters to Statement.Filter.
  • Remove ClientPolicy.RequestProleReplicas. The client will always request them.
  • Removes ScanPolicy.ServerSocketTimeout and QueryPolicy.ServerSocketTimeout in favor of the already existing Policy.SocketTimeout.
  • Renames Policy.Timeout to Policy.TotalTimeout to make the naming consistent with other clients.
  • Moves atomic package to internal.
  • Moves ParticleType package to internal.
  • Moves RequestNodeInfo and RequestNodeStats to methods on Node object, and adds InfoPolicy to the relevant API signatures.
  • Removes WaitUntilMigrationIsFinished from Scan/Query policies.
  • Changes NewConnection method signature, makes LoginCommand private.
  • Makes OperationType private.
  • Removes long deprecated method for pool management.
  • Removes unused ReadN method in Connection.
  • Embeds Policies as values and not pointers inside MultiPolicy, ScanPolicy and QueryPolicy.
  • Removes ToValueArray and ToValueSlice methods to discourage such suboptimal use. Changes QueryAggregate signature to remove the need for those methods.