hce-node application  1.4.3
HCE Hierarchical Cluster Engine node application
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
proto.h File Reference
#include <stddef.h>
#include <stdint.h>
Include dependency graph for proto.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  cl_proto_s
struct  cl_comp_proto_s
struct  cl_msg_field_s
struct  cl_msg_op_s
struct  cl_msg_key_s
struct  cl_msg_number_s
struct  cl_msg_s
struct  as_msg_s

Macros

#define CL_PROTO_RESULT_OK   0
#define CL_PROTO_RESULT_FAIL_UNKNOWN   1
#define CL_PROTO_RESULT_FAIL_NOTFOUND   2
#define CL_PROTO_RESULT_FAIL_GENERATION   3
#define CL_PROTO_RESULT_FAIL_PARAMETER   4
#define CL_PROTO_RESULT_FAIL_KEY_EXISTS   5
#define CL_PROTO_RESULT_FAIL_BIN_EXISTS   6
#define CL_PROTO_RESULT_FAIL_CLUSTER_KEY_MISMATCH   7
#define CL_PROTO_RESULT_FAIL_PARTITION_OUT_OF_SPACE   8
#define CL_PROTO_RESULT_FAIL_TIMEOUT   9
#define CL_PROTO_RESULT_FAIL_NOXDS   10
#define CL_PROTO_RESULT_FAIL_UNAVAILABLE   11
#define CL_PROTO_RESULT_FAIL_INCOMPATIBLE_TYPE   12
#define CL_PROTO_RESULT_FAIL_RECORD_TOO_BIG   13
#define CL_PROTO_RESULT_FAIL_KEY_BUSY   14
#define CL_PROTO_VERSION   2
#define CL_PROTO_TYPE_INFO   1
#define CL_PROTO_TYPE_CL_MSG   3
#define CL_PROTO_TYPE_CL_MSG_COMPRESSED   4
#define CL_RESULT_OK   0
#define CL_RESULT_FAIL   1
#define CL_RESULT_NOTFOUND   2
#define CL_MSG_FIELD_TYPE_NAMESPACE   0
#define CL_MSG_FIELD_TYPE_SET   1
#define CL_MSG_FIELD_TYPE_KEY   2
#define CL_MSG_FIELD_TYPE_BIN   3
#define CL_MSG_FIELD_TYPE_DIGEST_RIPE   4
#define CL_MSG_FIELD_TYPE_GU_TID   5
#define CL_MSG_FIELD_TYPE_DIGEST_RIPE_ARRAY   6
#define CL_MSG_FIELD_TYPE_TRID   7
#define CL_MSG_FIELD_TYPE_SCAN_OPTIONS   8
#define CL_MSG_OP_READ   1
#define CL_MSG_OP_WRITE   2
#define CL_MSG_OP_WRITE_UNIQUE   3
#define CL_MSG_OP_WRITE_NOW   4
#define CL_MSG_OP_INCR   5
#define CL_MSG_OP_APPEND_SEGMENT   6
#define CL_MSG_OP_APPEND_SEGMENT_EXT   7
#define CL_MSG_OP_APPEND_SEGMENT_QUERY   8
#define CL_MSG_OP_APPEND   9
#define CL_MSG_OP_PREPEND   10
#define CL_MSG_OP_TOUCH   11
#define CL_MSG_OP_MC_INCR   129
#define CL_MSG_OP_MC_APPEND   130
#define CL_MSG_OP_MC_PREPEND   131
#define CL_MSG_OP_MC_TOUCH   132
#define CL_MSG_INFO1_READ   (1 << 0)
#define CL_MSG_INFO1_GET_ALL   (1 << 1)
#define CL_MSG_INFO1_GET_ALL_NODATA   (1 << 2)
#define CL_MSG_INFO1_VERIFY   (1 << 3)
#define CL_MSG_INFO1_XDS   (1 << 4)
#define CL_MSG_INFO1_NOBINDATA   (1 << 5)
#define CL_MSG_INFO2_WRITE   (1 << 0)
#define CL_MSG_INFO2_DELETE   (1 << 1)
#define CL_MSG_INFO2_GENERATION   (1 << 2)
#define CL_MSG_INFO2_GENERATION_GT   (1 << 3)
#define CL_MSG_INFO2_GENERATION_DUP   (1 << 4)
#define CL_MSG_INFO2_WRITE_UNIQUE   (1 << 5)
#define CL_MSG_INFO2_WRITE_BINUNIQUE   (1 << 6)
#define CL_MSG_INFO2_WRITE_MERGE   (1 << 7)
#define CL_MSG_INFO3_LAST   (1 << 0)
#define CL_MSG_INFO3_TRACE   (1 << 1)
#define CL_MSG_INFO3_TOMBSTONE   (1 << 2)
#define CL_MSG_INFO3_REPLACE   (1 << 3)

Typedefs

typedef struct cl_comp_proto_s cl_comp_proto

Enumerations

enum  cl_particle_type {
  CL_PARTICLE_TYPE_NULL = 0, CL_PARTICLE_TYPE_INTEGER = 1, CL_PARTICLE_TYPE_FLOAT = 2, CL_PARTICLE_TYPE_STRING = 3,
  CL_PARTICLE_TYPE_BLOB = 4, CL_PARTICLE_TYPE_TIMESTAMP = 5, CL_PARTICLE_TYPE_DIGEST = 6, CL_PARTICLE_TYPE_JAVA_BLOB = 7,
  CL_PARTICLE_TYPE_CSHARP_BLOB = 8, CL_PARTICLE_TYPE_PYTHON_BLOB = 9, CL_PARTICLE_TYPE_RUBY_BLOB = 10, CL_PARTICLE_TYPE_MAX = 11
}

Functions

struct cl_proto_s __attribute__ ((__packed__)) cl_proto
void cl_proto_swap (cl_proto *m)
void cl_msg_swap_header (cl_msg *m)
void cl_msg_swap_field (cl_msg_field *mf)
void cl_msg_swap_fields (cl_msg *m)
void cl_msg_swap_ops (cl_msg *m)
void cl_msg_swap_op (cl_msg_op *op)
void cl_msg_swap_fields_and_ops (cl_msg *m)

Variables

uint8_t version
uint8_t type
uint64_t sz
uint8_t data []
uint32_t field_sz
uint32_t op_sz
uint8_t op
uint8_t particle_type
uint8_t name_sz
uint8_t name []
cl_msg_field f
uint8_t key []
uint32_t number
uint8_t header_sz
uint8_t info1
uint8_t info2
uint8_t info3
uint8_t unused
uint8_t result_code
uint32_t generation
uint32_t record_ttl
uint32_t transaction_ttl
uint16_t n_fields
uint16_t n_ops
cl_proto proto
cl_msg m

Macro Definition Documentation

#define CL_MSG_FIELD_TYPE_BIN   3

Definition at line 251 of file proto.h.

#define CL_MSG_FIELD_TYPE_DIGEST_RIPE   4

Definition at line 252 of file proto.h.

#define CL_MSG_FIELD_TYPE_DIGEST_RIPE_ARRAY   6

Definition at line 254 of file proto.h.

#define CL_MSG_FIELD_TYPE_GU_TID   5

Definition at line 253 of file proto.h.

#define CL_MSG_FIELD_TYPE_KEY   2

Definition at line 250 of file proto.h.

#define CL_MSG_FIELD_TYPE_NAMESPACE   0

Definition at line 248 of file proto.h.

#define CL_MSG_FIELD_TYPE_SCAN_OPTIONS   8

Definition at line 256 of file proto.h.

#define CL_MSG_FIELD_TYPE_SET   1

Definition at line 249 of file proto.h.

#define CL_MSG_FIELD_TYPE_TRID   7

Definition at line 255 of file proto.h.

#define CL_MSG_INFO1_GET_ALL   (1 << 1)

Definition at line 322 of file proto.h.

#define CL_MSG_INFO1_GET_ALL_NODATA   (1 << 2)

Definition at line 323 of file proto.h.

#define CL_MSG_INFO1_NOBINDATA   (1 << 5)

Definition at line 326 of file proto.h.

#define CL_MSG_INFO1_READ   (1 << 0)

Definition at line 321 of file proto.h.

#define CL_MSG_INFO1_VERIFY   (1 << 3)

Definition at line 324 of file proto.h.

#define CL_MSG_INFO1_XDS   (1 << 4)

Definition at line 325 of file proto.h.

#define CL_MSG_INFO2_DELETE   (1 << 1)

Definition at line 329 of file proto.h.

#define CL_MSG_INFO2_GENERATION   (1 << 2)

Definition at line 330 of file proto.h.

#define CL_MSG_INFO2_GENERATION_DUP   (1 << 4)

Definition at line 332 of file proto.h.

#define CL_MSG_INFO2_GENERATION_GT   (1 << 3)

Definition at line 331 of file proto.h.

#define CL_MSG_INFO2_WRITE   (1 << 0)

Definition at line 328 of file proto.h.

#define CL_MSG_INFO2_WRITE_BINUNIQUE   (1 << 6)

Definition at line 334 of file proto.h.

#define CL_MSG_INFO2_WRITE_MERGE   (1 << 7)

Definition at line 335 of file proto.h.

#define CL_MSG_INFO2_WRITE_UNIQUE   (1 << 5)

Definition at line 333 of file proto.h.

#define CL_MSG_INFO3_LAST   (1 << 0)

Definition at line 337 of file proto.h.

#define CL_MSG_INFO3_REPLACE   (1 << 3)

Definition at line 340 of file proto.h.

#define CL_MSG_INFO3_TOMBSTONE   (1 << 2)

Definition at line 339 of file proto.h.

#define CL_MSG_INFO3_TRACE   (1 << 1)

Definition at line 338 of file proto.h.

#define CL_MSG_OP_APPEND   9

Definition at line 312 of file proto.h.

#define CL_MSG_OP_APPEND_SEGMENT   6

Definition at line 309 of file proto.h.

#define CL_MSG_OP_APPEND_SEGMENT_EXT   7

Definition at line 310 of file proto.h.

#define CL_MSG_OP_APPEND_SEGMENT_QUERY   8

Definition at line 311 of file proto.h.

#define CL_MSG_OP_INCR   5

Definition at line 308 of file proto.h.

#define CL_MSG_OP_MC_APPEND   130

Definition at line 317 of file proto.h.

#define CL_MSG_OP_MC_INCR   129

Definition at line 316 of file proto.h.

#define CL_MSG_OP_MC_PREPEND   131

Definition at line 318 of file proto.h.

#define CL_MSG_OP_MC_TOUCH   132

Definition at line 319 of file proto.h.

#define CL_MSG_OP_PREPEND   10

Definition at line 313 of file proto.h.

#define CL_MSG_OP_READ   1

Definition at line 304 of file proto.h.

#define CL_MSG_OP_TOUCH   11

Definition at line 314 of file proto.h.

#define CL_MSG_OP_WRITE   2

Definition at line 305 of file proto.h.

#define CL_MSG_OP_WRITE_NOW   4

Definition at line 307 of file proto.h.

#define CL_MSG_OP_WRITE_UNIQUE   3

Definition at line 306 of file proto.h.

#define CL_PROTO_RESULT_FAIL_BIN_EXISTS   6

Definition at line 25 of file proto.h.

#define CL_PROTO_RESULT_FAIL_CLUSTER_KEY_MISMATCH   7

Definition at line 26 of file proto.h.

#define CL_PROTO_RESULT_FAIL_GENERATION   3

Definition at line 22 of file proto.h.

#define CL_PROTO_RESULT_FAIL_INCOMPATIBLE_TYPE   12

Definition at line 31 of file proto.h.

#define CL_PROTO_RESULT_FAIL_KEY_BUSY   14

Definition at line 33 of file proto.h.

#define CL_PROTO_RESULT_FAIL_KEY_EXISTS   5

Definition at line 24 of file proto.h.

#define CL_PROTO_RESULT_FAIL_NOTFOUND   2

Definition at line 21 of file proto.h.

#define CL_PROTO_RESULT_FAIL_NOXDS   10

Definition at line 29 of file proto.h.

#define CL_PROTO_RESULT_FAIL_PARAMETER   4

Definition at line 23 of file proto.h.

#define CL_PROTO_RESULT_FAIL_PARTITION_OUT_OF_SPACE   8

Definition at line 27 of file proto.h.

#define CL_PROTO_RESULT_FAIL_RECORD_TOO_BIG   13

Definition at line 32 of file proto.h.

#define CL_PROTO_RESULT_FAIL_TIMEOUT   9

Definition at line 28 of file proto.h.

#define CL_PROTO_RESULT_FAIL_UNAVAILABLE   11

Definition at line 30 of file proto.h.

#define CL_PROTO_RESULT_FAIL_UNKNOWN   1

Definition at line 20 of file proto.h.

#define CL_PROTO_RESULT_OK   0

Definition at line 19 of file proto.h.

#define CL_PROTO_TYPE_CL_MSG   3

Definition at line 90 of file proto.h.

#define CL_PROTO_TYPE_CL_MSG_COMPRESSED   4

Definition at line 91 of file proto.h.

#define CL_PROTO_TYPE_INFO   1

Definition at line 89 of file proto.h.

#define CL_PROTO_VERSION   2

Definition at line 88 of file proto.h.

#define CL_RESULT_FAIL   1

Definition at line 94 of file proto.h.

#define CL_RESULT_NOTFOUND   2

Definition at line 95 of file proto.h.

#define CL_RESULT_OK   0

Definition at line 93 of file proto.h.

Typedef Documentation

Enumeration Type Documentation

Enumerator:
CL_PARTICLE_TYPE_NULL 
CL_PARTICLE_TYPE_INTEGER 
CL_PARTICLE_TYPE_FLOAT 
CL_PARTICLE_TYPE_STRING 
CL_PARTICLE_TYPE_BLOB 
CL_PARTICLE_TYPE_TIMESTAMP 
CL_PARTICLE_TYPE_DIGEST 
CL_PARTICLE_TYPE_JAVA_BLOB 
CL_PARTICLE_TYPE_CSHARP_BLOB 
CL_PARTICLE_TYPE_PYTHON_BLOB 
CL_PARTICLE_TYPE_RUBY_BLOB 
CL_PARTICLE_TYPE_MAX 

Definition at line 53 of file proto.h.

Function Documentation

struct as_msg_s __attribute__ ( (__packed__)  )
void cl_msg_swap_field ( cl_msg_field *  mf)
void cl_msg_swap_fields ( cl_msg *  m)
void cl_msg_swap_fields_and_ops ( cl_msg *  m)
void cl_msg_swap_header ( cl_msg *  m)
void cl_msg_swap_op ( cl_msg_op *  op)
void cl_msg_swap_ops ( cl_msg *  m)
void cl_proto_swap ( cl_proto *  m)

Variable Documentation

uint8_t data

Definition at line 222 of file proto.h.

cl_msg_field f

Definition at line 268 of file proto.h.

uint32_t field_sz

Definition at line 257 of file proto.h.

uint32_t generation

Definition at line 299 of file proto.h.

uint8_t header_sz

Definition at line 293 of file proto.h.

uint8_t info1

Definition at line 294 of file proto.h.

uint8_t info2

Definition at line 295 of file proto.h.

uint8_t info3

Definition at line 296 of file proto.h.

uint8_t key[]

Definition at line 269 of file proto.h.

cl_msg m

Definition at line 302 of file proto.h.

uint16_t n_fields

Definition at line 302 of file proto.h.

uint16_t n_ops

Definition at line 303 of file proto.h.

uint8_t name[]

Definition at line 266 of file proto.h.

uint8_t name_sz

Definition at line 265 of file proto.h.

uint32_t number

Definition at line 274 of file proto.h.

uint8_t op

Definition at line 262 of file proto.h.

uint32_t op_sz

Definition at line 261 of file proto.h.

uint8_t particle_type

Definition at line 263 of file proto.h.

cl_proto proto

Definition at line 301 of file proto.h.

uint32_t record_ttl

Definition at line 300 of file proto.h.

uint8_t result_code

Definition at line 298 of file proto.h.

uint64_t sz

Definition at line 221 of file proto.h.

uint32_t transaction_ttl

Definition at line 301 of file proto.h.

uint8_t type

Definition at line 220 of file proto.h.

uint8_t unused

Definition at line 297 of file proto.h.

uint8_t version

Definition at line 219 of file proto.h.