# README
iproto
Import
import "github.com/tarantool/go-iproto"
Overview
Package iproto
contains IPROTO constants.
The code generated from Tarantool code. Code generation is only supported for an actual commit/release. We do not have a goal to support all versions of Tarantool with a code generator.
Example
package main
import (
"fmt"
"github.com/tarantool/go-iproto"
)
func main() {
fmt.Printf("%s=%d\n", iproto.ER_READONLY, iproto.ER_READONLY)
fmt.Printf("%s=%d\n", iproto.IPROTO_FEATURE_WATCHERS, iproto.IPROTO_FEATURE_WATCHERS)
fmt.Printf("%s=%d\n", iproto.IPROTO_FLAG_COMMIT, iproto.IPROTO_FLAG_COMMIT)
fmt.Printf("%s=%d\n", iproto.IPROTO_SYNC, iproto.IPROTO_SYNC)
fmt.Printf("%s=%d\n", iproto.IPROTO_SELECT, iproto.IPROTO_SELECT)
}
Development
You need to install git
and go1.13+
first. After that, you need to install
additional dependencies into $GOBIN
:
make deps
You can generate the code with commands:
TT_TAG=master make
TT_TAG=3.0.0 make
TT_TAG=master TT_REPO=https://github.com/my/tarantool.git make
You need to specify a target branch/tag with the environment variable TT_TAG
and you could to specify a repository with the TT_REPO
.
Makefile has additional targets that can be useful:
make format
TT_TAG=master make generate
make test
A good starting point is generate.go.
# Constants
"%s access to %s '%s' is denied for user '%s'".
"Field %s contains %s on conflict action, but %s in index parts".
"Operation is not permitted if timer is already running".
"Operation is not permitted when there is an active transaction ".
"Failed to lock WAL directory %s and hot_standby mode is off".
"Can't modify sequence '%s': %s".
"Can't modify space '%s': %s".
"Too many authentication attempts".
"Authentication required".
"Backup is already in progress".
"Invalid return value of space:before_replace trigger: expected tuple or nil".
"Some replica set members were not specified in box.cfg.replication".
"Replica %s chose a different bootstrap leader %s".
"Trying to bootstrap a local read-only instance as master".
"Couldn't find an instance to register this replica on.".
"Can't check who replica %s chose its bootstrap leader".
"Failed to initialize collation: %s.".
"Attempt to modify a tuple field which is part of primary index in space '%s'".
"WAL has a rollback in progress".
"Incorrect value for option '%s': %s".
"Snapshot is already in progress".
"Check constraint failed '%s': %s".
"%s are prohibited in a ck constraint definition".
"Cluster name mismatch: name '%s' provided in config confilcts with the instance one '%s'".
"Can not commit transaction in a nested statement".
"Foreign key constraint '%s' failed: %s".
"Compression error: %s".
"Connection to self".
"%s constraint '%s' already exists in space '%s'".
"Failed to create check constraint '%s': %s".
"Failed to create constraint '%s' in space '%s': %s".
"Failed to create field default function '%s': %s".
"Failed to create foreign key constraint '%s': %s".
"Failed to create foreign key '%s' in space '%s': %s".
"Failed to create function '%s': %s".
"Failed to create role '%s': %s".
"Failed to create sequence '%s': %s".
"Failed to create space '%s': %s".
"Failed to create user '%s': %s".
"User not found or supplied credentials are invalid".
"A multi-statement transaction can not use multiple storage engines".
"The transaction the cursor belongs to has ended".
"Decompression error: %s".
"Error calling field default function '%s': %s".
"Type of the default value does not match tuple field %s type: expected %s, got %s".
"%s is deprecated".
"Can't drop collation '%s': %s".
"Failed to drop foreign key constraint '%s': %s".
"Can't drop function %u: %s".
"Can't drop primary key in space '%s' while secondary keys exist".
"Can't drop sequence '%s': %s".
"Can't drop space '%s': %s".
"Failed to drop user or role '%s': %s".
"Elections were turned off".
"Tuple field count %u does not match space field count %u".
"Invalid key part count in an exact match (expected %u, got %u)".
"Check constraint '%s' failed for field '%s'".
"Foreign key constraint '%s' failed for field '%s': %s".
"Tuple field %s required by space format is missing".
"Tuple field %s type does not match one required by operation: expected %s, got %s".
"Can not commit transaction: deferred foreign keys violations are not resolved".
"Foreign key '%s' integrity check failed: %s".
"Field %s has type '%s' in space format, but type '%s' in index definition".
"Key format doesn't match one defined in functional index '%s' of space '%s': %s".
"Failed to build a key for functional index '%s' of space '%s': %s".
"Wrong functional index definition: %s".
"Function '%s' returned value of invalid type: expected %s got %s".
"Wrong number of arguments is passed to %s(): expected %s, got %d".
"Function '%s' already exists".
"Unsupported language '%s' specified for function '%s'".
"Transaction is active at return from function".
"Incorrect grant arguments: %s".
"Setting password for guest user has no effect".
"Hex literal %s%s length %d exceeds the supported limit (%d)".
"Invalid identifier '%s' (expected printable symbols only or it is too long)".
"Illegal mix of collations".
"Illegal parameters, %s".
"box.ctl.promote() is already running".
"Inconsistent types: expected %s got %s".
"%s are prohibited in an index definition".
"Index '%s' already exists".
"Index '%s' already exists in space '%s'".
"Indexed field count limit reached: %d indexed fields".
"Field %s has type '%s' in one index, but type '%s' in another".
"Unsupported index type supplied for index '%s' in space '%s'".
"Error injection '%s'".
"Duplicate replica name %s, already occupied by %s".
"Instance name mismatch: name '%s' provided in config confilcts with the instance one '%s'".
"Instance UUID mismatch: expected %s, got %s".
"Integer literal %s%s exceeds the supported range [-9223372036854775808, 18446744073709551615]".
"Interfering elections started".
"Instance with replica id %u was promoted first".
"Invalid '%s' data: %s".
"Invalid '%s' request: %s".
"Invalid decimal: '%s'".
"Invalid INDEX file %s: %s".
"Invalid MsgPack - %s".
"Invalid LSN order for instance %u: previous LSN = %llu, new lsn = %llu".
"Invalid RUN file: %s".
"Invalid UUID: %s".
"Invalid VYLOG file: %s".
"Failed to read xlog: %lld".
"Invalid xlog name: expected %lld got %lld".
"Invalid xlog order: %lld and %lld".
"Invalid xlog type: expected %s, got %s".
"Iterator position is invalid".
"Unknown iterator type '%s'".
"Invalid key part count (expected [0..%u], got %u)".
"Key part is too long: %u of %u bytes".
"Supplied key type of part %u does not match index part type: expected %s".
"Can't drop the primary key in a system space, space '%s'".
"Failed to dynamically load function '%s': %s".
"Failed to dynamically load module '%.*s': %s".
"Instance bootstrap hasn't finished yet".
"The local instance id %u is read-only".
"Failed to allocate %u bytes in %s for %s".
"Failed to allocate %u bytes for tuple: tuple is too large.
"Missing mandatory field '%s' in request".
"Can't find snapshot".
"Snapshot has no system spaces".
"Can't create or modify index '%s' in space '%s': %s".
"Get() doesn't support partial keys and non-unique indexes".
"Field %s is used as multikey in one index and as single key in another".
"Can not perform %s in a multi-statement transaction".
"Nil UUID is reserved and can't be used in replication".
"Connection is not established".
"Not enough peers connected to start elections: %d out of minimal required %d".
"Collation '%s' does not exist".
"Constraint '%s' does not exist in space '%s'".
"Space engine '%s' does not exist".
"Unknown event %s".
"Field '%s' was not found in the tuple".
"Field '%s' was not found in space '%s' format".
"Field %d was not found in the tuple".
"Function '%s' does not exist".
"Replication group '%s' does not exist".
"No index #%u is defined in space '%s'".
"No index '%s' is defined in space '%s'".
"Module '%s' does not exist".
"Procedure '%.*s' is not defined".
"Role '%s' is not found".
"Can not rollback to savepoint: the savepoint does not exist".
"Sequence '%s' does not exist".
"Session %llu does not exist".
"Session setting %s doesn't exist".
"Space '%s' does not exist".
"Trigger '%s' doesn't exist".
"User '%s' is not found".
"No active transaction".
"Can't modify data on a replication slave.
"The instance is not a leader.
"Primary index of space '%s' can not contain nullable parts".
"Password must differ from last %d passwords".
"The term is outdated: old - %llu, new - %llu".
"%s index does not support selects via a partial key (expected %u parts, got %u).
"Password expired".
"User '%s' already has %s access on %s%s".
"User '%s' does not have %s access on %s '%s'".
"%s".
"%s".
"msgpack.encode: can not encode Lua type '%s'".
"%s".
"Couldn't wait for quorum %d: %s".
"The read view is aborted".
"Can't modify data on a read-only instance".
"Can't set option '%s' dynamically".
"Can't initialize replica id with a reserved value %u".
"Replica count limit reached: %u".
"Replica '%s' is not anonymous and cannot register.".
"Replicaset name mismatch: name '%s' provided in config confilcts with the instance one '%s'".
"Can't reset replica set UUID: it is already assigned".
"Replica set UUID mismatch: expected %s, got %s".
"Role '%s' already exists".
"User '%s' already has role '%s'".
"Granting role '%s' to role '%s' would create a loop".
"User '%s' does not have role '%s'".
"Rollback called in a nested statement".
"Rowid is overflowed: too many entries in ephemeral space".
"RTree: %s must be an array with %u (point) or %u (rectangle/box) numeric coordinates".
"Can not set a savepoint in an empty transaction".
"Your schema version is %u.%u.%u while Tarantool %s requires a more recent schema version.
"Schema upgrade is already in progress".
"Sequence '%s' already exists".
"Sequence '%s' is not started".
"Sequence '%s' has overflowed".
"Session is closed".
"Session setting %s expected a value of type %s".
"Space '%s' already exists".
"Space field '%s' is duplicate".
"Split-Brain discovered: %s".
"ANALYZE statement argument %s is not a base table".
"Parameter %s was not found in the statement".
"SQL bind parameter limit reached: %d".
"Bind value type %s for parameter %s is not supported".
"Bind value for parameter %s is out of range for type %s".
"Can't add AUTOINCREMENT: space %s can't feature more than one AUTOINCREMENT field".
"Can’t resolve field '%s'".
"Unequal number of entries in row expression: left side has %u, but right side - %u".
"Failed to create space '%s': space column count %d exceeds the limit (%d)".
"Failed to execute SQL statement: %s".
"SQL expects exactly one argument returned from %s, got %d".
"At line %d at or near position %d: keyword '%.*s' is reserved.
"Pragma '%s' does not exist".
"%s".
"At line %d at or near position %d: %s".
"%s %d exceeds the limit (%d)".
"Failed to prepare SQL statement: %s".
"Failed to expand '*' in SELECT statement without FROM clause".
"Scanning is not allowed for %s".
"Failed to parse SQL statement: parser stack limit reached".
"Failed to execute an empty SQL statement".
"Syntax error at line %d near '%.*s'".
"Syntax error at line %d at or near position %d: %s".
"Type mismatch: can not convert %s to %s".
"At line %d at or near position %d: unrecognized token '%.*s'".
"%s".
"Can not execute a nested statement: nesting limit reached".
"CONFIRM message arrived for an unknown master id %d, expected %d".
"The synchronous transaction queue belongs to other instance with id %u".
"The synchronous transaction queue doesn't belong to any instance".
"Quorum collection for a synchronous transaction is timed out".
"A rollback for a synchronous transaction is received".
"%s".
"Timeout exceeded".
"Can't subscribe non-anonymous replica %s until join is done".
"Transaction has been aborted by conflict".
"Transaction has been aborted by timeout".
"Transaction has been aborted by a fiber yield".
"Trigger '%s' already exists".
"Can't truncate a system space, space '%s'".
"Check constraint '%s' failed for a tuple".
"Tuple field count limit reached: see box.schema.FIELD_MAX".
"Tuple format limit reached: %u".
"Duplicate key exists in unique index \"%s\" in space \"%s\" with old tuple - %s and new tuple - %s".
"Can't create tuple: metadata size %u is too big".
"Tuple/Key must be MsgPack array".
"Tuple doesn't exist in index '%s' in space '%s'".
"Transaction was rolled back".
"Unable to process %s request in stream".
"Unable to process %s request out of stream".
"Found uncommitted sync transactions from other instance with id %u".
"Please call box.cfg{} first".
"Unknown error".
"Unknown authentication method '%s'".
"Replica %s is not registered with replica set %s".
"Unknown request type %u".
"Unknown RTREE index distance type %s".
"Unknown object type '%s'".
"Unknown UPDATE operation #%d: %s".
"%s does not support %s".
"Index '%s' (%s) of space '%s' (%s) does not support %s".
"Unsupported %s privilege '%s'".
"Argument type in operation '%c' on field %s does not match field type: expected %s".
"Decimal overflow when performing operation '%c' on field %s".
"Field %s UPDATE error: %s".
"Integer overflow when performing '%c' operation on field %s".
"SPLICE error on field %s: %s".
"Space %s has a unique secondary index and does not support UPSERT".
"User '%s' already exists".
"A limit on the total number of users has been reached: %u".
"View '%s' is read-only".
"Space declared as a view must have SQL statement".
"Failed to allocate %u bytes for tuple: tuple is too large.
"Timed out waiting for Vinyl memory quota".
"Failed to write to disk".
"Password doesn't meet security requirements: %s".
"Wrong collation options: %s".
"Wrong _schema version: expected 'major.minor[.patch]'".
"Wrong function options: %s".
"Wrong index options: %s".
"Wrong index part %u: %s".
"Wrong record in _index space: got {%s}, expected {%s}".
"Prepared statement with id %u does not exist".
"Wrong schema version, current: %d, in request: %llu".
"Session '%s' is not supported".
"Wrong space format field %u: %s".
"Wrong space options: %s".
"Wrong space upgrade options: %s".
"%s".
Position of last selected tuple to start iteration after it.
Last selected tuple to start iteration after it.
AUTH request.
Name of the authentication method that is currently used on the server (value of box.cfg.auth_type).
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
Begin transaction.
No description provided by the author
No description provided by the author
CALL request - returns arbitrary MessagePack.
CALL request - wraps result into [tuple, tuple, ...] format.
The following three requests are reserved for vinyl types.
Commit transaction.
Response keys.
DELETE request.
No description provided by the author
No description provided by the author
EVAL request.
No description provided by the author
No description provided by the author
Key name and data sent to a remote watcher.
Execute an SQL statement.
Also request keys.
Tuple format in call and eval request arguments support: Tuples in IPROTO_TUPLE request field are encoded as MP_TUPLE and tuple formats are received in IPROTO_TUPLE_FORMATS field.
Tuple format in call and eval request responses support: Tuples in IPROTO_DATA response field are encoded as MP_TUPLE and tuple formats are sent in IPROTO_TUPLE_FORMATS field.
Tuple format in DML request responses support: Tuples in IPROTO_DATA response field are encoded as MP_TUPLE and tuple format is sent in IPROTO_TUPLE_FORMATS field.
MP_ERROR MsgPack extension support.
Pagination support: IPROTO_AFTER_POSITION, IPROTO_AFTER_TUPLE, IPROTO_FETCH_POSITION request fields and IPROTO_POSITION response field.
Using space [index] names instead of identifiers support: IPROTO_SPACE_NAME and IPROTO_INDEX_NAME fields in IPROTO_SELECT, IPROTO_UPDATE and IPROTO_DELETE request body; IPROTO_SPACE_NAME field in IPROTO_INSERT, IPROTO_REPLACE, IPROTO_UPDATE and IPROTO_UPSERT request body.
Streams support: IPROTO_STREAM_ID header key.
Transactions in the protocol: IPROTO_BEGIN, IPROTO_COMMIT, IPROTO_ROLLBACK commands.
IPROTO_WATCH_ONCE request support.
Remote watchers support: IPROTO_WATCH, IPROTO_UNWATCH, IPROTO_EVENT commands.
Protocol features.
Leave a gap between integer values and other keys Flag indicating the need to send position of last selected tuple in response.
Anonymous replication FETCH SNAPSHOT.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
Set for the last xrow in a transaction.
Set for the last row of a synchronous tx.
Set for the last row of a tx residing in limbo.
No description provided by the author
No description provided by the author
No description provided by the author
Protocol features request.
No description provided by the author
No description provided by the author
No description provided by the author
Index name used instead of identifier (IPROTO_INDEX_ID) in IPROTO_SELECT, IPROTO_UPDATE, and IPROTO_DELETE requests.
INSERT request.
No description provided by the author
Replication keys (body).
Flag indicating whether the transaction is synchronous.
No description provided by the author
Replication JOIN command.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
IPROTO_METADATA: [ { IPROTO_FIELD_NAME: name }, { ..
New tuple (i.e.
No operation.
No description provided by the author
Acknowledgement that request or command is successful.
Old tuple (i.e.
UPSERT but not UPDATE ops, because of legacy.
No description provided by the author
PING request.
Position of last selected tuple in response.
Prepare SQL statement.
No description provided by the author
A confirmation message for synchronous transactions.
DEMOTE request.
No description provided by the author
No description provided by the author
PROMOTE request.
A rollback message for synchronous transactions.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
REGISTER request to leave anonymous replication.
REPLACE request.
Leave a gap between SQL keys and additional request keys.
Replication keys (header).
No description provided by the author
No description provided by the author
No description provided by the author
Rollback transaction.
No description provided by the author
SELECT request.
No description provided by the author
Leave a gap for other keys in the header.
Space name used instead of identifier (IPROTO_SPACE_ID) in DML requests.
No description provided by the author
IPROTO_SQL_INFO: { SQL_INFO_ROW_COUNT: number }.
Leave a gap between response keys and SQL keys.
No description provided by the author
No description provided by the author
Replication SUBSCRIBE command.
No description provided by the author
Term.
Operation timeout.
No description provided by the author
No description provided by the author
No description provided by the author
Mapping of format identifier to format clause consisting of field names and field types.
No description provided by the author
Isolation level, is used only by IPROTO_BEGIN request.
Error codes = (IPROTO_TYPE_ERROR | ER_XXX from errcode.h).
The maximum typecode used for box.stat().
Used for overriding the unknown request handler.
No description provided by the author
UPDATE request.
UPSERT request.
No description provided by the author
No description provided by the author
A vclock synchronisation request identifier.
Protocol version.
Vote request command for master election.
DEPRECATED: use IPROTO_VOTE instead.
The following three request types are used by the remote watcher protocol (box.watch over network), which operates as follows:
1.
Synchronous request to fetch the data that is currently attached to a notification key without subscribing to changes.
all tuples.
all bits are not set.
all bits from x are set in key.
at least one x's bit is set.
key == x ASC order.
key >= x.
key > x.
key <= x.
key < x.
tuples in distance ascending order from specified point.
key overlaps x.
key == x DESC order.
No description provided by the author
No description provided by the author
Vinyl page info stored in .index file.
Vinyl run info stored in .index file.
Vinyl row index stored in .run file.
# Type aliases
IPROTO ballot key constants, generated from tarantool/src/box/iproto_constants.h.
IPROTO error code constants, generated from tarantool/src/box/errcode.h.
IPROTO feature constants, generated from tarantool/src/box/iproto_features.h.
IPROTO flag constants, generated from tarantool/src/box/iproto_constants.h.
IPROTO iterators constants, generated from tarantool/src/box/iterator_type.h.
IPROTO key constants, generated from tarantool/src/box/iproto_constants.h.
IPROTO metadata key constants, generated from tarantool/src/box/iproto_constants.h.
IPROTO raft key constants, generated from tarantool/src/box/iproto_constants.h.
IPROTO SQL info key constants, generated from tarantool/src/box/execute.h.
IPROTO type constants, generated from tarantool/src/box/iproto_constants.h.