All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
as_status.h
Go to the documentation of this file.
1/*
2 * Copyright 2008-2025 Aerospike, Inc.
3 *
4 * Portions may be licensed to Aerospike, Inc. under one or more contributor
5 * license agreements.
6 *
7 * Licensed under the Apache License, Version 2.0 (the "License"); you may not
8 * use this file except in compliance with the License. You may obtain a copy of
9 * the License at http://www.apache.org/licenses/LICENSE-2.0
10 *
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
13 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
14 * License for the specific language governing permissions and limitations under
15 * the License.
16 */
17#pragma once
18
19#ifdef __cplusplus
20extern "C" {
21#endif
22
23//---------------------------------
24// Types
25//---------------------------------
26
27/**
28 * Status codes used as return values as as_error.code values.
29 */
30typedef enum as_status_e {
31 //---------------------------------
32 // Client Errors
33 //---------------------------------
34
35 /**
36 * Transaction commit called, but the transaction was already aborted.
37 */
39
40 /**
41 * Transaction abort called, but the transaction was already committed.
42 */
44
45 /**
46 * Transaction failed.
47 */
49
50 /**
51 * One or more keys failed in a batch.
52 */
54
55 /**
56 * No response received from server.
57 */
59
60 /**
61 * Max errors limit reached.
62 */
64
65 /**
66 * Abort split batch retry and use normal node retry instead.
67 * Used internally and should not be returned to user.
68 */
70
71 /**
72 * Max retries limit reached.
73 */
75
76 /**
77 * Async command delay queue is full.
78 */
80
81 /**
82 * Synchronous connection error.
83 */
85
86 /**
87 * Node invalid or could not be found.
88 */
90
91 /**
92 * Node invalid or could not be found.
93 */
95
96 /**
97 * Max connections would be exceeded.
98 */
100
101 /**
102 * Asynchronous connection error.
103 */
105
106 /**
107 * Query or scan was aborted in user's callback.
108 */
110
111 /**
112 * Host name could not be found in DNS lookup.
113 */
115
116 /**
117 * No more records available when parsing batch, scan or query records.
118 */
120
121 /**
122 * Invalid client API parameter.
123 */
125
126 /**
127 * Generic client API usage error.
128 */
130
131 /**
132 * Deprecated. Generic client error. Keep for legacy reasons.
133 */
135
136 //---------------------------------
137 // Success
138 //---------------------------------
139
140 /**
141 * Generic success.
142 */
144
145 //---------------------------------
146 // Server Errors
147 //---------------------------------
148
149 /**
150 * Generic error returned by server.
151 */
153
154 /**
155 * Record does not exist in database. May be returned by read, or write
156 * with policy AS_POLICY_EXISTS_UPDATE.
157 */
159
160 /**
161 * Generation of record in database does not satisfy write policy.
162 */
164
165 /**
166 * Request protocol invalid, or invalid protocol field.
167 */
169
170 /**
171 * Record already exists. May be returned by write with policy
172 * AS_POLICY_EXISTS_CREATE.
173 */
175
176 /**
177 * Bin already exists on a create-only operation.
178 */
180
181 /**
182 * A cluster state change occurred during the request. This may also be
183 * returned by scan operations with the fail_on_cluster_change flag set.
184 */
186
187 /**
188 * The server node is running out of memory and/or storage device space
189 * reserved for the specified namespace.
190 */
192
193 /**
194 * Request timed out. Can be triggered by client or server.
195 */
197
198 /**
199 * Operation not allowed in current configuration.
200 */
202
203 /**
204 * Partition is unavailable.
205 */
207
208 /**
209 * Bin modification operation can't be done on an existing bin due to its
210 * value type.
211 */
213
214 /**
215 * Record being (re-)written can't fit in a storage write block.
216 */
218
219 /**
220 * Too may concurrent requests for one record - a "hot-key" situation.
221 */
223
224 /**
225 * Scan aborted by user.
226 */
228
229 /**
230 * Sometimes our doc, or our customers wishes, get ahead of us. We may have
231 * processed something that the server is not ready for (unsupported feature).
232 */
234
235 /**
236 * Bin not found on update-only operation.
237 */
239
240 /**
241 * The server node's storage device(s) can't keep up with the write load.
242 */
244
245 /**
246 * Record key sent with command did not match key stored on server.
247 */
249
250 /**
251 * Namespace in request not found on server.
252 */
254
255 /**
256 * Sent too-long bin name (should be impossible in this client) or exceeded
257 * namespace's bin name quota.
258 */
260
261 /**
262 * Operation not allowed at this time.
263 */
265
266 /**
267 * Map element not found in UPDATE_ONLY write mode.
268 */
270
271 /**
272 * Map element exists in CREATE_ONLY write mode.
273 */
275
276 /**
277 * Attempt to use an Enterprise feature on a Community server or a server
278 * without the applicable feature key.
279 */
281
282 /**
283 * The operation cannot be applied to the current bin value on the server.
284 */
286
287 /**
288 * The command was not performed because the filter expression was
289 * false.
290 */
292
293 /**
294 * Write command loses conflict to XDR.
295 */
297
298 /**
299 * Write can't complete until XDR finishes shipping.
300 */
302
303 /**
304 * There are no more records left for query.
305 */
307
308 /**
309 * Security functionality not supported by connected server.
310 */
312
313 /**
314 * Security functionality not enabled by connected server.
315 */
317
318 /**
319 * Security scheme not supported
320 */
322
323 /**
324 * Administration command is invalid.
325 */
327
328 /**
329 * Administration field is invalid.
330 */
332
333 /**
334 * Security protocol not followed.
335 */
337
338 /**
339 * User name is invalid.
340 */
342
343 /**
344 * User was previously created.
345 */
347
348 /**
349 * Password is invalid.
350 */
352
353 /**
354 * Password has expired.
355 */
357
358 /**
359 * Forbidden password (e.g. recently used).
360 */
362
363 /**
364 * Security credential is invalid.
365 */
367
368 /**
369 * Login session expired.
370 */
372
373 /**
374 * Role name is invalid.
375 */
377
378 /**
379 * Role already exists.
380 */
382
383 /**
384 * Privilege is invalid.
385 */
387
388 /**
389 * Invalid IP whitelist.
390 */
392
393 /**
394 * Quotas not enabled on server.
395 */
397
398 /**
399 * Invalid quota.
400 */
402
403 /**
404 * User must be authenticated before performing database operations.
405 */
407
408 /**
409 * User does not possess the required role to perform the database operation.
410 */
412
413 /**
414 * Command not allowed because sender IP not whitelisted.
415 */
417
418 /**
419 * Quota exceeded.
420 */
422
423 /**
424 * Generic UDF error.
425 */
427
428 /**
429 * Transaction record blocked by a different transaction.
430 */
432
433 /**
434 * Transaction read version mismatch identified during commit.
435 * Some other command changed the record outside of the transaction.
436 */
438
439 /**
440 * Transaction deadline reached without a successful commit or abort.
441 */
443
444 /**
445 * Transaction write command limit (4096) exceeded.
446 */
448
449 /**
450 * Transaction was already committed.
451 */
453
454 /**
455 * Transaction was already aborted.
456 */
458
459 /**
460 * This record has been locked by a previous update in this transaction.
461 */
463
464 /**
465 * This transaction has already started. Writing to the same transaction with independent threads is unsafe.
466 */
468
469 /**
470 * Batch functionality has been disabled.
471 */
473
474 /**
475 * Batch max requests have been exceeded.
476 */
478
479 /**
480 * All batch queues are full.
481 */
483
484 /**
485 * Invalid/Unsupported GeoJSON.
486 */
488
489 /**
490 * Index found.
491 */
493
494 /**
495 * Index not found.
496 */
498
499 /**
500 * Index is out of memory.
501 */
503
504 /**
505 * Unable to read the index.
506 */
508
509 /**
510 * Generic secondary index error.
511 */
513
514 /**
515 * Index name is too long.
516 */
518
519 /**
520 * System already has maximum allowed indices.
521 */
523
524 /**
525 * Query was aborted.
526 */
528
529 /**
530 * Query processing queue is full.
531 */
533
534 /**
535 * Secondary index query timed out on server.
536 */
538
539 /**
540 * Generic query error.
541 */
543
544 //---------------------------------
545 // UDF Operations
546 //---------------------------------
547
548 /**
549 * UDF does not exist.
550 */
552 /**
553 * LUA file does not exist.
554 */
556
557} as_status;
558
559#ifdef __cplusplus
560} // end extern "C"
561#endif
as_status
Definition as_status.h:30
@ AEROSPIKE_MRT_VERSION_MISMATCH
Definition as_status.h:437
@ AEROSPIKE_QUOTA_EXCEEDED
Definition as_status.h:421
@ AEROSPIKE_ERR_UDF_NOT_FOUND
Definition as_status.h:551
@ AEROSPIKE_USE_NORMAL_RETRY
Definition as_status.h:69
@ AEROSPIKE_INVALID_ROLE
Definition as_status.h:376
@ AEROSPIKE_ERR_BATCH_QUEUES_FULL
Definition as_status.h:482
@ AEROSPIKE_ERR_BIN_NOT_FOUND
Definition as_status.h:238
@ AEROSPIKE_ERR_UDF
Definition as_status.h:426
@ AEROSPIKE_INVALID_CREDENTIAL
Definition as_status.h:366
@ AEROSPIKE_SECURITY_NOT_ENABLED
Definition as_status.h:316
@ AEROSPIKE_ERR_BIN_INCOMPATIBLE_TYPE
Definition as_status.h:212
@ AEROSPIKE_MRT_ABORTED
Definition as_status.h:457
@ AEROSPIKE_ERR_CLIENT_ABORT
Definition as_status.h:109
@ AEROSPIKE_ERR_INDEX_FOUND
Definition as_status.h:492
@ AEROSPIKE_ERR_FAIL_ELEMENT_EXISTS
Definition as_status.h:274
@ AEROSPIKE_ERR_SERVER_FULL
Definition as_status.h:191
@ AEROSPIKE_ERR_DEVICE_OVERLOAD
Definition as_status.h:243
@ AEROSPIKE_ERR_RECORD_GENERATION
Definition as_status.h:163
@ AEROSPIKE_EXPIRED_PASSWORD
Definition as_status.h:356
@ AEROSPIKE_ERR_LUA_FILE_NOT_FOUND
Definition as_status.h:555
@ AEROSPIKE_SECURITY_SCHEME_NOT_SUPPORTED
Definition as_status.h:321
@ AEROSPIKE_ERR_RECORD_TOO_BIG
Definition as_status.h:217
@ AEROSPIKE_INVALID_QUOTA
Definition as_status.h:401
@ AEROSPIKE_QUERY_END
Definition as_status.h:306
@ AEROSPIKE_ERR_BIN_EXISTS
Definition as_status.h:179
@ AEROSPIKE_ERR_CLUSTER
Definition as_status.h:206
@ AEROSPIKE_ERR_TIMEOUT
Definition as_status.h:196
@ AEROSPIKE_ERR_CLIENT
Definition as_status.h:129
@ AEROSPIKE_TXN_FAILED
Definition as_status.h:48
@ AEROSPIKE_XDR_KEY_BUSY
Definition as_status.h:301
@ AEROSPIKE_ERR_INDEX_NOT_FOUND
Definition as_status.h:497
@ AEROSPIKE_ILLEGAL_STATE
Definition as_status.h:336
@ AEROSPIKE_ERR_RECORD_KEY_MISMATCH
Definition as_status.h:248
@ AEROSPIKE_TXN_ALREADY_COMMITTED
Definition as_status.h:43
@ AEROSPIKE_USER_ALREADY_EXISTS
Definition as_status.h:346
@ AEROSPIKE_INVALID_FIELD
Definition as_status.h:331
@ AEROSPIKE_NO_MORE_RECORDS
Definition as_status.h:119
@ AEROSPIKE_ERR_BIN_NAME
Definition as_status.h:259
@ AEROSPIKE_ERR_INDEX
Definition as_status.h:512
@ AEROSPIKE_OK
Definition as_status.h:143
@ AEROSPIKE_ERR_FAIL_ELEMENT_NOT_FOUND
Definition as_status.h:269
@ AEROSPIKE_MAX_ERROR_RATE
Definition as_status.h:63
@ AEROSPIKE_FORBIDDEN_PASSWORD
Definition as_status.h:361
@ AEROSPIKE_ERR_TLS_ERROR
Definition as_status.h:89
@ AEROSPIKE_ERR_QUERY
Definition as_status.h:542
@ AEROSPIKE_MRT_MONITOR_EXISTS
Definition as_status.h:467
@ AEROSPIKE_INVALID_COMMAND
Definition as_status.h:326
@ AEROSPIKE_LOST_CONFLICT
Definition as_status.h:296
@ AEROSPIKE_BATCH_FAILED
Definition as_status.h:53
@ AEROSPIKE_ERR_SERVER
Definition as_status.h:152
@ AEROSPIKE_ERR_ALWAYS_FORBIDDEN
Definition as_status.h:201
@ AEROSPIKE_FILTERED_OUT
Definition as_status.h:291
@ AEROSPIKE_ERR_INDEX_NAME_MAXLEN
Definition as_status.h:517
@ AEROSPIKE_NOT_WHITELISTED
Definition as_status.h:416
@ AEROSPIKE_MRT_COMMITTED
Definition as_status.h:452
@ AEROSPIKE_ERR_GEO_INVALID_GEOJSON
Definition as_status.h:487
@ AEROSPIKE_ERR_ENTERPRISE_ONLY
Definition as_status.h:280
@ AEROSPIKE_ERR_PARAM
Definition as_status.h:124
@ AEROSPIKE_ERR_RECORD_NOT_FOUND
Definition as_status.h:158
@ AEROSPIKE_ERR_REQUEST_INVALID
Definition as_status.h:168
@ AEROSPIKE_INVALID_PASSWORD
Definition as_status.h:351
@ AEROSPIKE_ERR_FAIL_FORBIDDEN
Definition as_status.h:264
@ AEROSPIKE_TXN_ALREADY_ABORTED
Definition as_status.h:38
@ AEROSPIKE_ROLE_ALREADY_EXISTS
Definition as_status.h:381
@ AEROSPIKE_NOT_AUTHENTICATED
Definition as_status.h:406
@ AEROSPIKE_SECURITY_NOT_SUPPORTED
Definition as_status.h:311
@ AEROSPIKE_ERR_SCAN_ABORTED
Definition as_status.h:227
@ AEROSPIKE_ERR_BATCH_DISABLED
Definition as_status.h:472
@ AEROSPIKE_ERR_RECORD_BUSY
Definition as_status.h:222
@ AEROSPIKE_INVALID_PRIVILEGE
Definition as_status.h:386
@ AEROSPIKE_ERR_INVALID_NODE
Definition as_status.h:94
@ AEROSPIKE_ERR_BATCH_MAX_REQUESTS_EXCEEDED
Definition as_status.h:477
@ AEROSPIKE_ERR_OP_NOT_APPLICABLE
Definition as_status.h:285
@ AEROSPIKE_INVALID_USER
Definition as_status.h:341
@ AEROSPIKE_ERR_INVALID_HOST
Definition as_status.h:114
@ AEROSPIKE_MRT_EXPIRED
Definition as_status.h:442
@ AEROSPIKE_MRT_BLOCKED
Definition as_status.h:431
@ AEROSPIKE_NO_RESPONSE
Definition as_status.h:58
@ AEROSPIKE_ERR_QUERY_TIMEOUT
Definition as_status.h:537
@ AEROSPIKE_EXPIRED_SESSION
Definition as_status.h:371
@ AEROSPIKE_ERR_MAX_RETRIES_EXCEEDED
Definition as_status.h:74
@ AEROSPIKE_MRT_TOO_MANY_WRITES
Definition as_status.h:447
@ AEROSPIKE_ERR_QUERY_ABORTED
Definition as_status.h:527
@ AEROSPIKE_ROLE_VIOLATION
Definition as_status.h:411
@ AEROSPIKE_MRT_ALREADY_LOCKED
Definition as_status.h:462
@ AEROSPIKE_INVALID_WHITELIST
Definition as_status.h:391
@ AEROSPIKE_ERR_INDEX_OOM
Definition as_status.h:502
@ AEROSPIKE_QUOTAS_NOT_ENABLED
Definition as_status.h:396
@ AEROSPIKE_ERR_CONNECTION
Definition as_status.h:84
@ AEROSPIKE_ERR_NAMESPACE_NOT_FOUND
Definition as_status.h:253
@ AEROSPIKE_ERR_ASYNC_CONNECTION
Definition as_status.h:104
@ AEROSPIKE_ERR_INDEX_MAXCOUNT
Definition as_status.h:522
@ AEROSPIKE_ERR_QUERY_QUEUE_FULL
Definition as_status.h:532
@ AEROSPIKE_ERR_UNSUPPORTED_FEATURE
Definition as_status.h:233
@ AEROSPIKE_ERR_NO_MORE_CONNECTIONS
Definition as_status.h:99
@ AEROSPIKE_ERR_ASYNC_QUEUE_FULL
Definition as_status.h:79
@ AEROSPIKE_ERR_CLUSTER_CHANGE
Definition as_status.h:185
@ AEROSPIKE_ERR
Definition as_status.h:134
@ AEROSPIKE_ERR_RECORD_EXISTS
Definition as_status.h:174
@ AEROSPIKE_ERR_INDEX_NOT_READABLE
Definition as_status.h:507