pub enum Error {
ParseError(ParseError),
ReqwestError(Error),
IOError(Error),
InvalidRequest,
IsSealed,
NotFound,
Unauthorized,
SessionExpired,
Other,
}Expand description
The Error
Variants§
ParseError(ParseError)
ParseError is returned when there was an error parsing a url
ReqwestError(Error)
ReqwestError is returned when the request made to vault itself fails
IOError(Error)
IOError is returned by operations that have to do some sort of IO, like the helper function for the kubernetes backend, which loads the JWT token from a local file
InvalidRequest
InvalidRequest is returned when the made to vault was missing data or was invalid/ malformed data and therefore was rejected by vault before doing anything
IsSealed
IsSealed is returned when the given vault instance is not available because it is currently sealed and therefore does not accept or handle any requests other than to unseal it
NotFound
NotFound is returned when the given vault endpoint/path was not found on the actual vault instance that you are connected to
Unauthorized is returned when your current Session has either expired and has not been renewed or when the credentials for login are not valid and therefore rejected or when you try to access something that you dont have the permissions to do so
SessionExpired
SessionExpired is returned when the session you tried to use is expired and was configured to not automatically obtain a new session, when it notices that the current one is expired
Other
Other simply represents all other errors that could not be grouped into on the other categories listed above