forked from TrueCloudLab/frostfs-sdk-go
[#215] client: Introduce apemanager rpc interface
* Introduce `APEManagerAddChain`, `APEManagerRemoveChain`, `APEManagerListChains`. * Introduce reqeuest/response types for these handlers (Prm*, Res*). * Inroduce status type for apemanager `APEManagerAccessDenied`; add unit-tests. Signed-off-by: Airat Arifullin <a.arifullin@yadro.com>
This commit is contained in:
parent
32a975a20d
commit
b2ad1f3b3e
7 changed files with 310 additions and 0 deletions
|
@ -61,6 +61,12 @@ func IsErrSessionNotFound(err error) bool {
|
|||
return wrapsErrType[*apistatus.SessionTokenNotFound](err)
|
||||
}
|
||||
|
||||
// IsErrAPEManagerAccessDenied checks if err corresponds to FrostFS status return
|
||||
// corresponding to apemanager access deny. Supports wrapped errors.
|
||||
func IsErrAPEManagerAccessDenied(err error) bool {
|
||||
return wrapsErrType[*apistatus.APEManagerAccessDenied](err)
|
||||
}
|
||||
|
||||
// returns error describing missing field with the given name.
|
||||
func newErrMissingResponseField(name string) error {
|
||||
return fmt.Errorf("missing %s field in the response", name)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue