|
|
@ -146,6 +146,8 @@ pub enum MongoErrorCode {
|
|
|
|
ScramProtocolError,
|
|
|
|
ScramProtocolError,
|
|
|
|
QueryCommandNotFound,
|
|
|
|
QueryCommandNotFound,
|
|
|
|
QueryNotTailable,
|
|
|
|
QueryNotTailable,
|
|
|
|
|
|
|
|
WriteConcernError,
|
|
|
|
|
|
|
|
DuplicateKey,
|
|
|
|
Unknown
|
|
|
|
Unknown
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
@ -222,6 +224,8 @@ impl BsoncError {
|
|
|
|
bindings::MONGOC_ERROR_SCRAM_PROTOCOL_ERROR => MongoErrorCode::ScramProtocolError,
|
|
|
|
bindings::MONGOC_ERROR_SCRAM_PROTOCOL_ERROR => MongoErrorCode::ScramProtocolError,
|
|
|
|
bindings::MONGOC_ERROR_QUERY_COMMAND_NOT_FOUND => MongoErrorCode::QueryCommandNotFound,
|
|
|
|
bindings::MONGOC_ERROR_QUERY_COMMAND_NOT_FOUND => MongoErrorCode::QueryCommandNotFound,
|
|
|
|
bindings::MONGOC_ERROR_QUERY_NOT_TAILABLE => MongoErrorCode::QueryNotTailable,
|
|
|
|
bindings::MONGOC_ERROR_QUERY_NOT_TAILABLE => MongoErrorCode::QueryNotTailable,
|
|
|
|
|
|
|
|
bindings::MONGOC_ERROR_WRITE_CONCERN_ERROR => MongoErrorCode::WriteConcernError,
|
|
|
|
|
|
|
|
bindings::MONGOC_ERROR_DUPLICATE_KEY => MongoErrorCode::DuplicateKey,
|
|
|
|
_ => MongoErrorCode::Unknown
|
|
|
|
_ => MongoErrorCode::Unknown
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|