package
2.1.3+incompatible
Repository: https://github.com/arangodb/go-driver.git
Documentation: pkg.go.dev
# Functions
AreAgentsHealthy performs a health check on all given agents.
ConvertWriteCondition creates new conditions to the transaction using deprecated structure 'WriteCondition'.
IsAlreadyLocked returns true if the given error is or is caused by an AlreadyLockedError.
IsKeyNotFound returns true if the given error is (or is caused by) a KeyNotFoundError.
IsNotLocked returns true if the given error is or is caused by an NotLockedError.
IsSameEndpoint returns true when the 2 given endpoints refer to the same server.
NewAgency creates an Agency accessor for the given connection.
NewAgencyConnection creates an agency connection for agents at the given endpoints.
NewConditionIfEqual creates condition where value must equal to a value which is written in the agency.
NewConditionIfNotEqual creates condition where value must not equal to a value which is written in the agency.
NewConditionIsArray creates condition where value must be an array before it is written.
NewConditionOldEmpty creates condition where value must be empty before it is written.
NewKeyArrayErase returns a new key operation for removing elements from the array.
NewKeyArrayPush returns a new key operation for adding elements to the array.
NewKeyArrayReplace returns a new key operation for replacing element in the array.
NewKeyDelete returns a new key operation which must be removed from the agency.
NewKeyObserve returns a new key callback operation which must be written in the agency.
NewKeySet returns a new key operation which must be set in the agency
Deprecated: TTL param is removed since 3.12, use NewKeySetV2 instead.
NewKeySetV2 returns a new key operation which must be set in the agency.
NewLock creates a new lock on the given key.
NewTransaction creates new transaction.
WithAllowNoLeader is used to configure a context to make AreAgentsHealthy accept the situation where leader endpoint is different (during agency endpoint update).
WithAllowNoLeader is used to configure a context to make AreAgentsHealthy accept the situation where it finds 0 leaders.
# Variables
AlreadyLockedError indicates that the lock is already locked.
NotLockedError indicates that the lock is not locked when trying to unlock.
# Structs
KeyNotFoundError indicates that a key was not found.
Transaction stores information about operations which must be performed for particular keys with some conditions.
TransactionOptions defines options how transaction should behave.
Deprecated: use 'agency.KeyConditioner' instead
WriteCondition is a precondition before a write is accepted.
# Interfaces
Agency provides API implemented by the ArangoDB agency.
KeyChanger describes how operation should be performed on a key in the agency.
KeyConditioner describes conditions to check before it writes something to the agency.
Lock is an agency backed exclusive lock.
Logger abstracts a logger.