All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
as_status.h
Go to the documentation of this file.
1 /*
2  * Copyright 2008-2016 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
20 extern "C" {
21 #endif
22 
23 /*******************************************************************************
24  * TYPES
25  ******************************************************************************/
26 
27 /**
28  * Status codes used as return values as as_error.code values.
29  */
30 typedef enum as_status_e {
31 
32  /***************************************************************************
33  * Client Errors
34  **************************************************************************/
35  /**
36  * Asynchronous connection error.
37  */
39 
40  /**
41  * Asynchronous connection error.
42  */
44 
45  /**
46  * Query or scan was aborted in user's callback.
47  */
49 
50  /**
51  * Host name could not be found in DNS lookup.
52  */
54 
55  /**
56  * No more records available when parsing batch, scan or query records.
57  */
59 
60  /**
61  * Invalid client API parameter.
62  */
64 
65  /**
66  * Generic client API usage error.
67  */
69 
70  /**
71  * Deprecated. Generic client error. Keep for legacy reasons.
72  */
74 
75  /***************************************************************************
76  * Success
77  **************************************************************************/
78 
79  /**
80  * Generic success.
81  */
83 
84  /***************************************************************************
85  * Server Errors
86  **************************************************************************/
87 
88  /**
89  * Generic error returned by server.
90  */
92 
93  /**
94  * Record does not exist in database. May be returned by read, or write
95  * with policy AS_POLICY_EXISTS_UPDATE.
96  */
98 
99  /**
100  * Generation of record in database does not satisfy write policy.
101  */
103 
104  /**
105  * Request protocol invalid, or invalid protocol field.
106  */
108 
109  /**
110  * Record already exists. May be returned by write with policy
111  * AS_POLICY_EXISTS_CREATE.
112  */
114 
115  /**
116  * Bin already exists.
117  */
119 
120  /**
121  * A cluster state change occurred during the request. This may also be
122  * returned by scan operations with the fail_on_cluster_change flag set.
123  */
125 
126  /**
127  * The server node is running out of memory and/or storage device space
128  * reserved for the specified namespace.
129  */
131 
132  /**
133  * Request timed out. Can be triggered by client or server.
134  */
136 
137  /**
138  * XDR is not available for the cluster.
139  */
141 
142  /**
143  * Generic cluster discovery & connection error.
144  */
146 
147  /**
148  * Bin modification operation can't be done on an existing bin due to its
149  * value type.
150  */
152 
153  /**
154  * Record being (re-)written can't fit in a storage write block.
155  */
157 
158  /**
159  * Too may concurrent requests for one record - a "hot-key" situation.
160  */
162 
163  /**
164  * Scan aborted by user.
165  */
167 
168  /**
169  * Sometimes our doc, or our customers wishes, get ahead of us. We may have
170  * processed something that the server is not ready for (unsupported feature).
171  */
173 
174  /**
175  * Bin-level replace-only supported on server but not on client.
176  */
178 
179  /**
180  * The server node's storage device(s) can't keep up with the write load.
181  */
183 
184  /**
185  * Record key sent with transaction did not match key stored on server.
186  */
188 
189  /**
190  * Namespace in request not found on server.
191  */
193 
194  /**
195  * Sent too-long bin name (should be impossible in this client) or exceeded
196  * namespace's bin name quota.
197  */
199 
200  /**
201  * Operation not allowed at this time.
202  */
204 
205  /**
206  * There are no more records left for query.
207  */
209 
210  /**
211  * Security functionality not supported by connected server.
212  */
214 
215  /**
216  * Security functionality not enabled by connected server.
217  */
219 
220  /**
221  * Security type not supported by connected server.
222  */
224 
225  /**
226  * Administration command is invalid.
227  */
229 
230  /**
231  * Administration field is invalid.
232  */
234 
235  /**
236  * Security protocol not followed.
237  */
239 
240  /**
241  * User name is invalid.
242  */
244 
245  /**
246  * User was previously created.
247  */
249 
250  /**
251  * Password is invalid.
252  */
254 
255  /**
256  * Password has expired.
257  */
259 
260  /**
261  * Forbidden password (e.g. recently used)
262  */
264 
265  /**
266  * Security credential is invalid.
267  */
269 
270  /**
271  * Role name is invalid.
272  */
274 
275  /**
276  * Role already exists.
277  */
279 
280  /**
281  * Privilege is invalid.
282  */
284 
285  /**
286  * User must be authentication before performing database operations.
287  */
289 
290  /**
291  * User does not possess the required role to perform the database operation.
292  */
294 
295  /**
296  * Generic UDF error.
297  */
299 
300  /**
301  * The requested item in a large collection was not found.
302  */
304 
305  /**
306  * Batch functionality has been disabled.
307  */
309 
310  /**
311  * Batch max requests have been exceeded.
312  */
314 
315  /**
316  * All batch queues are full.
317  */
319 
320  /**
321  * Invalid/Unsupported GeoJSON
322  */
324 
325  /**
326  * Index found.
327  */
329 
330  /**
331  * Index not found
332  */
334 
335  /**
336  * Index is out of memory
337  */
339 
340  /**
341  * Unable to read the index.
342  */
344 
345  /**
346  * Generic secondary index error.
347  */
349 
350  /**
351  * Index name is too long.
352  */
354 
355  /**
356  * System already has maximum allowed indices.
357  */
359 
360  /**
361  * Query was aborted.
362  */
364 
365  /**
366  * Query processing queue is full.
367  */
369 
370  /**
371  * Secondary index query timed out on server.
372  */
374 
375  /**
376  * Generic query error.
377  */
379 
380  /***************************************************************************
381  * UDF OPERATIONS
382  **************************************************************************/
383 
384  /**
385  * UDF does not exist.
386  */
388  /**
389  * LUA file does not exist.
390  */
392 
393  /***************************************************************************
394  * Large Data Type (LDT) OPERATIONS
395  **************************************************************************/
396 
397  /** Internal LDT error. */
399 
400  /** LDT item not found */
402 
403  /** Unique key violation: Duplicated item inserted when 'unique key" was set.*/
405 
406  /** General error during insert operation. */
408 
409  /** General error during search operation. */
411 
412  /** General error during delete operation. */
414 
415 
416  /** General input parameter error. */
418 
419  // -------------------------------------------------
420 
421  /** LDT Type mismatch for this bin. */
423 
424  /** The supplied LDT bin name is null. */
426 
427  /** The supplied LDT bin name must be a string. */
429 
430  /** The supplied LDT bin name exceeded the 14 char limit. */
432 
433  /** Internal Error: too many open records at one time. */
435 
436  /** Internal Error: Top Record not found. */
438 
439  /** Internal Error: Sub Record not found. */
441 
442  /** LDT Bin does not exist. */
444 
445  /** Collision: LDT Bin already exists. */
447 
448  /** LDT control structures in the Top Record are damaged. Cannot proceed. */
450 
451  // -------------------------------------------------
452 
453  /** Internal Error: LDT Subrecord pool is damaged. */
455 
456  /** LDT control structures in the Sub Record are damaged. Cannot proceed. */
458 
459  /** Error encountered while opening a Sub Record. */
461 
462  /** Error encountered while updating a Sub Record. */
464 
465  /** Error encountered while creating a Sub Record. */
467 
468  /** Error encountered while deleting a Sub Record. */
470 
471  /** Error encountered while closing a Sub Record. */
473 
474  /** Error encountered while updating a TOP Record. */
476 
477  /** Error encountered while creating a TOP Record. */
479 
480  // -------------------------------------------------
481 
482  /** The filter function name was invalid. */
484 
485  /** The filter function was not found. */
487 
488  /** The function to extract the Unique Value from a complex object was invalid. */
490 
491  /** The function to extract the Unique Value from a complex object was not found. */
493 
494  /** The function to transform an object into a binary form was invalid. */
496 
497  /** The function to transform an object into a binary form was not found. */
499 
500  /** The function to untransform an object from binary form to live form was invalid. */
502 
503  /** The function to untransform an object from binary form to live form not found. */
505 
506  /** The UDF user module name for LDT Overrides was invalid */
508 
509  /** The UDF user module name for LDT Overrides was not found */
511 
512 } as_status;
513 
514 #ifdef __cplusplus
515 } // end extern "C"
516 #endif