mirror of
https://github.com/ceph/ceph-csi.git
synced 2025-06-13 18:43:34 +00:00
rebase: bump github.com/ceph/go-ceph
Bumps [github.com/ceph/go-ceph](https://github.com/ceph/go-ceph) from 0.29.1-0.20240925141413-065319c78733 to 0.30.0. - [Release notes](https://github.com/ceph/go-ceph/releases) - [Changelog](https://github.com/ceph/go-ceph/blob/master/docs/release-process.md) - [Commits](https://github.com/ceph/go-ceph/commits/v0.30.0) --- updated-dependencies: - dependency-name: github.com/ceph/go-ceph dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com>
This commit is contained in:
committed by
mergify[bot]
parent
3bcf6afe30
commit
9152b4c2c7
35
vendor/github.com/ceph/go-ceph/cephfs/errors.go
generated
vendored
35
vendor/github.com/ceph/go-ceph/cephfs/errors.go
generated
vendored
@ -11,23 +11,8 @@ import (
|
||||
"github.com/ceph/go-ceph/internal/errutil"
|
||||
)
|
||||
|
||||
// cephFSError represents an error condition returned from the CephFS APIs.
|
||||
type cephFSError int
|
||||
|
||||
// Error returns the error string for the cephFSError type.
|
||||
func (e cephFSError) Error() string {
|
||||
return errutil.FormatErrorCode("cephfs", int(e))
|
||||
}
|
||||
|
||||
func (e cephFSError) ErrorCode() int {
|
||||
return int(e)
|
||||
}
|
||||
|
||||
func getError(e C.int) error {
|
||||
if e == 0 {
|
||||
return nil
|
||||
}
|
||||
return cephFSError(e)
|
||||
return errutil.GetError("cephfs", int(e))
|
||||
}
|
||||
|
||||
// getErrorIfNegative converts a ceph return code to error if negative.
|
||||
@ -46,22 +31,16 @@ var (
|
||||
// ErrEmptyArgument may be returned if a function argument is passed
|
||||
// a zero-length slice or map.
|
||||
ErrEmptyArgument = errors.New("Argument must contain at least one item")
|
||||
)
|
||||
|
||||
// Public CephFSErrors:
|
||||
|
||||
const (
|
||||
// ErrNotConnected may be returned when client is not connected
|
||||
// to a cluster.
|
||||
ErrNotConnected = cephFSError(-C.ENOTCONN)
|
||||
ErrNotConnected = getError(-C.ENOTCONN)
|
||||
// ErrNotExist indicates a non-specific missing resource.
|
||||
ErrNotExist = cephFSError(-C.ENOENT)
|
||||
)
|
||||
ErrNotExist = getError(-C.ENOENT)
|
||||
|
||||
// Private errors:
|
||||
// Private errors:
|
||||
|
||||
const (
|
||||
errInvalid = cephFSError(-C.EINVAL)
|
||||
errNameTooLong = cephFSError(-C.ENAMETOOLONG)
|
||||
errRange = cephFSError(-C.ERANGE)
|
||||
errInvalid = getError(-C.EINVAL)
|
||||
errNameTooLong = getError(-C.ENAMETOOLONG)
|
||||
errRange = getError(-C.ERANGE)
|
||||
)
|
||||
|
Reference in New Issue
Block a user