Skip to content

Commit

Permalink
dep: update go-ceph from nixpanic
Browse files Browse the repository at this point in the history
  • Loading branch information
nixpanic committed Feb 13, 2020
1 parent 8d1835a commit fe7f6bb
Show file tree
Hide file tree
Showing 8 changed files with 275 additions and 51 deletions.
6 changes: 3 additions & 3 deletions Gopkg.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Gopkg.toml
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@
name = "k8s.io/utils"

[[constraint]]
branch = "rbd/watchers"
branch = "wip/for-ceph-csi"
source = "github.com/nixpanic/go-ceph"
name = "github.com/ceph/go-ceph"

Expand Down
4 changes: 1 addition & 3 deletions pkg/rbd/rbd_util.go
Original file line number Diff line number Diff line change
Expand Up @@ -165,9 +165,7 @@ func createImage(ctx context.Context, pOpts *rbdVolume, volSz int64, cr *util.Cr
return errors.Wrapf(err, "failed to get ioctx for connection")
}

// image is not returned to the caller
// no need to Close(), the image is not open after Create()
_, err = librbd.Create4(ioctx, pOpts.RbdImageName, uint64(volSz*util.MiB), options)
err = librbd.CreateImage(ioctx, pOpts.RbdImageName, uint64(volSz*util.MiB), options)
if err != nil {
return errors.Wrapf(err, "failed to create rbd image")
}
Expand Down
4 changes: 2 additions & 2 deletions pkg/util/cephcmds.go
Original file line number Diff line number Diff line change
Expand Up @@ -245,8 +245,8 @@ func CreateObject(ctx context.Context, monitors string, cr *Credentials, poolNam
ioctx.SetNamespace(namespace)
}

err = ioctx.Create(objectName, rados.RadosCreateExclusive)
if err == rados.RadosErrorObjectExist {
err = ioctx.Create(objectName, rados.CreateExclusive)
if err == rados.ErrObjectExists {
return ErrObjectExists{objectName, err}
} else if err != nil {
klog.Errorf(Log(ctx, "failed creating omap (%s) in pool (%s): (%v)"), objectName, poolName, err)
Expand Down
228 changes: 228 additions & 0 deletions vendor/github.com/ceph/go-ceph/rbd/features.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

20 changes: 20 additions & 0 deletions vendor/github.com/ceph/go-ceph/rbd/features_mimic.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

20 changes: 20 additions & 0 deletions vendor/github.com/ceph/go-ceph/rbd/features_nautilus.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

42 changes: 0 additions & 42 deletions vendor/github.com/ceph/go-ceph/rbd/rbd.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit fe7f6bb

Please sign in to comment.