# 请求状态码
eZooDB在各种请求的返回结果中,使用全局统一的状态码用于确认处理结果的状态。
- 每个状态码配有一个默认返回信息,业务请求可能会使用定制的返回消息,辅助请求者更快的定位问题;
- 500及以上状态码为系统预留的内部状态码;
| 状态码 | 描述 | 默认返回消息 |
|---|---|---|
| 0 | 成功 | "OK." |
| 1 | 未知错误 | "Unknown." |
| 2 | 数据库不存在 | "Database does not exist." |
| 3 | 未找到 | "Not found." |
| 4 | 操作不支持 | "Unsupported." |
| 5 | 已经存在 | "Already exist." |
| 6 | 用户不存在 | "User dose not exist." |
| 7 | 参数错误 | "Invalid parameter." |
| 8 | 数据库未加载 | "Database not loaded." |
| 9 | 数据库无法访问 | "Database inaccessible." |
| 10 | 用户已存在 | "User already exist." |
| 11 | 存在重复的键值 | "Duplicate keys." |
| 12 | 不合法的键值 | "Invalid key." |
| 13 | 不合法的类型 | "Invalid type." |
| 14 | 不安全的操作 | "Unsafe operation." |
| 15 | 队列已满 | "Queue is full." |
| 16 | 队列为空 | "Queue is empty." |
| 17 | 已弃用 | "Deprecated." |
| 18 | 枚举映射失败 | "Enumerate failed." |
| 19 | 文件不可访问 | "File inaccessible." |
| 20 | 文件格式错误 | "File format error." |
| 21 | 操作进行中 | "In processing" |
| 22 | 约束校验失败 | "Constraint verification failed." |
| 23 | 请求超时 | "Timeout." |
| 24 | 超出最大限制 | "Out of size." |
| 25 | 超出最大范围 | "Out of range." |
| 26 | 依赖库缺失 | "Lack of dependency library." |
| 27 | 备份文件已损坏 | "Backup files are damaged." |
| 28 | 数据不可写入 | "Not writable." |
| 29 | 认证失败 | "Authentication failed." |
| 30 | 权限不足 | "Authentication forbidden." |
| 31 | 旧密码错误 | "Old password error." |
| 32 | 数据不可读 | "Unreadable." |
| 33 | 点不存在 | "Node not exist." |
| 34 | 边不存在 | "Edge not exist." |
| 35 | 快照恢复异常 | "Restore failed from snapshot." |
| 36 | 创建快照异常 | "Create snapshot failed." |
| 37 | 事务不存在 | "Transaction not exist." |
| 38 | 内存不足 | "Bad memory allocate." |
| 39 | 副本不满足要求 | "replication not satisfied" |
| 40 | 接口等待超时 | "Interface wait timeout." |
| 41 | 网络异常 | "Network error." |
| 42 | 网络超时 | "Network timeout." |
| 500+ | 服务器内部错误 | "Internal server error." |