Skip to content

Releases: ceph/go-ceph

Release v0.7.0

08 Dec 17:30
Compare
Choose a tag to compare

The maintainers and contributors to go-ceph are pleased to announce the v0.7.0 release. This is another great step towards making it possible to use the power of the Ceph APIs in the Go language.

For this release we'd like to highlight the ability to quickly create thickly provisioned RBD images by using the WriteSame function call. By using WriteSame, the caller can fill an image with zeros without repeated write calls.

As this is a v0.x release we do not guarantee backwards compatibility with previous versions of the code. However, we aim not to disrupt existing consumers of the library and thus make an effort not to immediately implement breaking changes without very good justification. Please see the "Deprecations & Removals" section to get a sense of what you can expect to change in the future and prepare your code ahead of time. You may also want to view "Deprecations & Removals" of previous releases as they are not repeated here.

New Features

  • In the rados package
    • Add GetNamespace implementing rados_ioctx_get_namespace
    • Add constants mapping to those in librados prefixed by LIBRADOS_OP_FLAG
  • In the rbd package
    • Add ListMetadata implementing rbd_metadata_list
    • Add WriteSame implementing rbd_writesame
  • In the cephfs package
    • Add File method Truncate implementing ceph_ftruncate
    • Add Truncate implementing ceph_truncate
  • In the cephfs admin package
    • Add SubVolRmFlags type
    • Add RemoveSubVolumWithFlags function

Deprecations & Removals

As of go-ceph v0.5.0 support for Ceph "luminous" and "mimic" were officially deprecated. With v0.6.0 support for "luminous" was no longer maintained. With this release support for ceph "mimic" for building go-ceph will no longer be maintained. Do note that server-client version compatibility for go-ceph is the same as the native Ceph libraries, as these are what go-ceph builds upon. The above changes only alter what versions of Ceph go-ceph expects to successfully compile with.

In the cephfs admin package, functions for managing subvolumegroup snapshots have been removed. The APIs in ceph that are used to implement these functions were disabled in recent versions of nautilus and octopus. Since these functions were only added in go-ceph v0.6.0, and the cephfs admin api is not yet considered stable, they were removed without first going through a deprecation cycle.

Other

  • Improve function documentation
  • Changes to the CI test matrix
  • CI and workflow automation
  • Replace the use of unsafe.Pointer for callback management
    with C functions to avoid risk of dangling pointers.
  • Simplify the internal logic managing callback IDs
  • Other fixes and improvements

Release v0.6.0

13 Oct 14:28
Compare
Choose a tag to compare

The maintainers and contributors to go-ceph are pleased to announce the v0.6.0 release. This is another great step towards making it possible to use the power of the Ceph APIs in the Go language.

For this release we'd like to highlight the new "cephfs admin" package. This package can be used to create, delete, & otherwise manage cephfs subvolumes, subvolume groups, snapshots, and clones. This library makes use of two API calls from the rados package [1]. As it does not depend directly on the libcephfs APIs themselves it has been created as a separate package located at "github.com/ceph/go-ceph/cephfs/admin".

As this is a v0.x release we do not guarantee backwards compatibility with previous versions of the code. However, we aim not to disrupt existing consumers of the library and thus make an effort not to immediately implement breaking changes without very good justification. Please see the "Deprecations & Removals" section to get a sense of what you can expect to change in the
future and prepare your code ahead of time. You may also want to view "Deprecations & Removals" of previous releases as they are not repeated here.

Because the cephfs admin package is brand new, we intend on being more lax with backwards compatibility for a release or two. While we'd prefer not to change anything, we will more readily make changes as needed because the package is
still immature compared to the other sub-packages. Feedback, via our github issue tracker, about this new package is especially welcome.

New Features

  • In the rbd package
    • Add Sparsify implementing rbd_sparsify
    • Add GetParent implementing rbd_get_parent. New code should prefer to use GetParent rather than GetParentInfo. The latter may be deprecated and removed in future releases
    • Add GetSnapID implementing rbd_get_snap_id
    • Add GetSnapByID implementing rbd_snap_get_name
    • Add GetSnapTimestamp implementing rbd_snap_get_timestamp()
    • Add SetSnapByID implementing rbd_snap_set_by_id()
  • In the cephfs package
    • Add Preadv implementing ceph_preadv
    • Add Pwritev implementing ceph_pwritev
  • In the cephfs admin package
    • A new cephfs admin package has been added. See above for context, see the generated API documentation [2] to see the functions added and what features are covered.

Deprecations & Removals

As of go-ceph v0.5.0 support for Ceph "luminous" and "mimic" were officially deprecated. With this release support for ceph "luminous" for building go-ceph will no longer be maintainted. We intend to proceed similarly for "mimic" in go-ceph v0.7.0. Do note that server-client version compatibility for go-ceph is the same as the native Ceph libraries, as these are what go-ceph builds upon. The above changes only alter what versions of Ceph go-ceph expects to successfully compile with.

Other

  • Improve reliability of CI tests.
  • Improve the project README file.
  • Simplify, and make more unified, the handling of callback functions
  • Many other fixes and improvements

[1] - The functions MonCommand and MgrCommand. However, the underlying types in cephfs admin only require an interface matching MonCommand and MgrCommand and can thus be customized by the calling code by providing the cephfs admin any type that meets the interface.

[2] - https://pkg.go.dev/github.com/ceph/go-ceph@v0.6.0/cephfs/admin - please note that it may take some time for this web version to populate. You can always use the go doc command line tool instead.

Release v0.5.0

11 Aug 14:06
Compare
Choose a tag to compare

The maintainers and contributors to go-ceph are pleased to announce the v0.5.0 release. This is another great step towards making it possible to use the power of the Ceph APIs in the Go language.

For this release we'd like to highlight the new snapshot functions added to the rbd package. With these functions users of the rbd module can now perform more complete management of image snapshots.

We've also changed how errors produced by many of the calls work. Previously, each package exported its own error type. This is no longer the case (see Deprecations & Removals). Instead, we encourage users of the library to use Go's error.Is & error.As functions or sentinel error comparison on older versions of Go, where appropriate.

This release announces the deprecation of, and plan to remove, "luminous" and "mimic" support. See "Deprecations & Removals" section for details.

As this is a v0.x release we do not guarantee backwards compatibility with previous versions of the code. However, we aim not to disrupt existing consumers of the library and thus make an effort not to immediately implement breaking changes without very good justification. Please see the "Deprecations & Removals" section to get a sense of what you can expect to change in the
future and prepare your code ahead of time. You may also want to view "Deprecations & Removals" of previous releases as they are not repeated here.

New Features

  • In the rados package
    • Add ParseConfigArgv implementing rados_conf_parse_argv
    • Add GetLastVersion implementing rados_get_last_version
    • Add CreateSnap implementing rados_ioctx_snap_create
    • Add RemoveSnap implementing rados_ioctx_snap_remove
    • Add LookupSnap implementing rados_ioctx_snap_lookup
    • Add GetSnapName implementing rados_ioctx_snap_get_name
    • Add GetSnapStamp implementing rados_ioctx_snap_get_stamp
    • Add ListSnaps implementing rados_ioctx_snap_list
    • Add RollbackSnap implementing rados_ioctx_snap_rollback
    • Add SetReadSnap implementing rados_ioctx_snap_set_read
  • In the rbd package
    • Add GetCreateTimestamp implementing rbd_get_create_timestamp
    • Add GetAccessTimestamp implementing rbd_get_access_timestamp
    • Add GetModifyTimestamp implementing rbd_get_modify_timestamp
    • Add UpdateWatch implementing rbd_update_watch
    • Add Unwatch implementing rbd_update_unwatch
    • Add a Watch type for managing watches
    • Add GetSnapNamespaceType implementing rbd_snap_get_namespace_type
    • Add GetSnapTrashNamespace implementing rbd_snap_get_trash_namespace
    • Add PoolInit implementing rbd_pool_init
    • Add GetAllPoolStats implementing rbd_pool_stats_get and related accessor functions
    • Add GetPoolID implementing rados_ioctx_get_id
  • In the cephfs package
    • Add StatFS implementing ceph_statfs
    • Add ParseConfigArgv implementing ceph_conf_parse_argv
    • Add ParseDefaultConfigEnv implementing ceph_conf_parse_env
    • Add GetXattr implementing ceph_fgetxattr (file method)
    • Add SetXattr implementing ceph_fsetxattr (file method)
    • Add ListXattr implementing ceph_flistxattr (file method)
    • Add RemoveXattr implementing ceph_fremovexattr (file method)
    • Add GetXattr implementing ceph_getxattr (path based)
    • Add ListXattr implementing ceph_listxattr (path based)
    • Add RemoveXattr implementing ceph_removexattr (path based)
    • Add SetXattr implementing ceph_setxattr (path based)
    • Add LgetXattr implementing ceph_lgetxattr (path based)
    • Add LlistXattr implementing ceph_llistxattr (path based)
    • Add LremoveXattr implementing ceph_lremovexattr (path based)
    • Add LsetXattr implementing ceph_lsetxattr (path based)

Deprecations & Removals

  • The rados package no longer exports a RadosError type
  • The rbd package no longer exports an RBDError type
  • The cephfs package no longer exports a CephFSError type
  • The fields Parent_pool and Parent_name have been removed from the ImageInfo struct in the rbd package as these fields never contained data

As of this release (go-ceph v0.5.0) support for Ceph "luminous" and "mimic" are officially deprecated. We plan to remove support for "luminous" in go-ceph v0.6.0 and to remove support for "mimic" in go-ceph v0.7.0. If you are building go-ceph against either of these versions of Ceph, please plan accordingly. Do note that server-client version compatibility for go-ceph is the same as the native Ceph libraries, as these are what go-ceph builds upon. These plans only change what versions of Ceph go-ceph expects to successfully compile with.

Other

  • It is now easier to execute the go-ceph test suite with multiple different ceph versions
  • Internal support for splitting C buffers into string slices has been improved
  • Improved documentation for ParseDefaultConfigEnv in the rados package
  • Error types that represent an error code value produced by a Ceph API function call now have an .ErrorCode() method that can be used as a feature of last resort when the raw error code value is needed
  • Various improvements to the test scripts and tooling
  • Many other fixes and improvements

Release v0.4.0

16 Jun 16:03
Compare
Choose a tag to compare

The maintainers and contributors to go-ceph are pleased to announce the v0.4.0 release. This is another great step towards making it possible to use the power of the Ceph APIs in the Go language.

For this release we'd like to highlight the numerous additions to the cephfs package. These changes add many functions that are equivalent for the file-systems APIs that are commonly used on unix-like systems. Now, for many uses cases, one ought to be able to use go-ceph in place of a locally mounted CephFS file system.

As this is a v0.x release we do not guarantee backwards compatibility with previous versions of the code. However, we aim not to disrupt existing consumers of the library and thus make an effort not to immediately implement breaking changes without very good justification. Please see the "Deprecations & Removals" section to get a sense of what you can expect to change in the future and prepare your code ahead of time. You may also want to view "Deprecations & Removals" of previous releases as they are not repeated here.

New Features

  • In the rados package
    • Add MgrCommand and MgrCommandWithInputBuffer implmementing rados_mgr_command
    • Add OsdCommand and OsdCommandWithInputBuffer implmementing rados_osd_command
    • Add MonCommandTarget and MonCommandTargetWithInputBuffer implmementing rados_mon_command_target
  • In the rbd package
    • Add ImageOptionFlatten constant for RBD_IMAGE_OPTION_FLATTEN (Mimic)
    • Add ImageOptionCloneFormat constant for RBD_IMAGE_OPTION_CLONE_FORMAT (Nautilus)
    • Add ImageOptionMirrorImageMode constant for RBD_IMAGE_OPTION_MIRROR_IMAGE_MODE (Octopus)
    • Add GetPoolMetadata implementing rbd_pool_metadata_get
    • Add SetPoolMetadata implementing rbd_pool_metadata_set
    • Add RemovePoolMetadata implementing rbd_pool_metadata_remove
    • Add NamespaceCreate implementing rbd_namespace_create
    • Add NamespaceExists implementing rbd_namespace_exists
    • Add NamespaceRemove implementing rbd_namespace_remove
    • Add NamespaceList implementing rbd_namespace_list
  • In the cephfs package
    • Add a UserPerm type based on UserPerm from libcephfs
    • Add Init function implementing ceph_init
    • Add SetMountPerms implementing ceph_mount_perms_set
    • Add a File type and functions to support I/O on files:
      • Open (ceph_open)
      • Close (ceph_close)
      • Read and ReadAt (ceph_read)
      • Write and WriteAt (ceph_write)
      • Seek (ceph_lseek)
    • Add Unlink implementing ceph_unlink
    • Add DType type for directory entries
    • Add Link implementing ceph_link
    • Add Symlink implementing ceph_symlink
    • Add Readlink implementing ceph_readlink
    • Add Fchmod implementing ceph_fchmod
    • Add Fchown implementing ceph_fchown
    • Add Statx implementing ceph_statx
    • Add ReadDirPlus implementing ceph_readdirplus_r
    • Add Fstatx implementing ceph_fstatx
    • Add Fallocate implementing ceph_fallocate
    • Add Flock implementing ceph_flock
    • Add Fsync and Sync implementing ceph_fsync
    • Add Rename implementing ceph_rename

Deprecations & Removals

No new deprecations or removals in this release.

Other

  • Improve the ability of tests to clean up state between runs
  • Various changes to keep .go files smaller and more organized
  • Added shared code to help handle retrying internal calls
  • Improved and added more internal validation of function inputs and state
  • Add shared code to help handle C/Go interaction
  • Added a contrib tool for checking how much of the Ceph C APIs go-ceph covers
  • Improved error handling in rbd when attempting to remove opened images
  • Various improvements to the test scripts and tooling
  • Many other fixes and improvements

Release v0.3.0

14 Apr 19:53
Compare
Choose a tag to compare

The maintainers and contributors to go-ceph are pleased to announce the v0.3.0 release. This is another great step towards making it possible to use the power of the Ceph APIs in the Go language.

As this is a v0.x release we do not guarantee backwards compatibility with previous versions of the code. However, we aim not to disrupt existing consumers of the library and thus make an effort not to immediately implement breaking changes without very good justification. Please see the "Deprecations & Removals" section to get a sense of what you can expect to change in the future and prepare your code ahead of time. You may also want to view "Deprecations & Removals" of previous releases as they are not repeated here.

New Features

  • In the rbd package:
    • Add UpdateFeatures implementing rbd_update_features
    • Add FeatureSet type for for mapping between features and their names
    • Add FeatureOperations constant for RBD_FEATURE_OPERATIONS
    • Add FeatureMigrating constant for RBD_FEATURE_MIGRATING
    • Add ListWatchers implementing rbd_watchers_list
    • Add DiffIterate implementing rbd_diff_iterate2
  • In the cephfs package:
    • Add MountWithRoot to support the "root" argument to ceph_mount
    • Add GetFsCid implementing ceph_get_fs_cid
    • Add SetConfigOption implementing ceph_conf_set
    • Add GetConfigOption implementing ceph_conf_get
    • The Release function is now idempotent
    • Add a Directory type for interacting with CephFS directories
    • Add Directoy Open implementing ceph_opendir
    • Add Directoy Close implementing ceph_closedir
    • Add ReadDir implementing ceph_readdir_r
    • Add RewindDir implementing ceph_rewinddir

Deprecations & Removals

  • Previously, constants in the rbd package prefixed with ImageOption were prefixed with RbdImageOption. The previous naming scheme has been deprecated. The old names are now aliases to the new names and the old names will likely be dropped in a future release.
  • Previously, the types ImageOptions and ImageOption were named RbdImageOptions and RbdImageOption. The previous naming scheme has been deprecated. The old names are now aliases to the new names and the old names will likely be dropped in a future release.

Other

  • The library is now being tested with Ceph's Octopus (v15.2.z) release
  • Various code-quality improvements have been applied to all sub-packages
  • Various documentation improvements across all sub-packages
  • Various improvements to the test scripts and tooling
  • Many other fixes and improvements

Release v0.2.0

13 Feb 16:05
Compare
Choose a tag to compare

The maintainers and contributors to go-ceph are pleased to announce the v0.2.0 release. This is our first official release and a big step towards making it possible to use the power of the Ceph APIs in in the Go language.

As this is a v0.x release we do not guarantee backwards compatibility with previous versions of the code. However, we aim not to disrupt existing consumers of the library and thus make an effort not to immediately implement breaking changes without very good justification. Please see the "Depreciations & Removals" section to get a sense of what you can expect to change in the future and prepare your code ahead of time.

New Features

  • In the rados package:
    • Add GetPoolByName implemeting rados_pool_lookup
    • Add GetPoolByID implemeting rados_pool_reverse_lookup
    • Add PGCommand and PGCommandWithInputBuffer implemeting rados_pg_command
    • Add Create implementing rados_write_op_create
  • In the rbd package:
    • Add GetMetadata implementing rbd_metadata_get
    • Add SetMetadata implementing rbd_metadata_set
    • Add RemoveMetadata implementing rbd_metadata_remove
    • Add RbdImageOptions type
    • Add OpenImage as a more proper implementation of rbd_open
    • Add OpenImageReadOnly as a more proper implementation of rbd_open_read_only
    • Add CreateImage implementing rbd_create4
    • Add RemoveImage as a more proper implementation of rbd_remove
    • Add GetId implementing rbd_get_id
    • Add OpenImageById implementing rbd_open_by_id
    • Add OpenImageByIdReadOnly implementing rbd_open_by_id_read_only
    • Add CloneImage implementing rbd_clone3
  • In the cephfs package:
    • Add CreateFromRados implementing ceph_create_from_rados
    • Add CreateMountWithId supporting an id argument to ceph_create
    • Add MdsCommand and MdsCommandWithInputBuffer implementing ceph_mds_command

Deprecation & Removals

  • Numerous error values have been renamed from ErrorFoo to ErrFoo. Aliases for the old name have been left in place. The old form has been deprecated and will be removed in a future version
  • The rados package defined a GetRadosError error conversion function. This function has been removed from the package.
  • The rbd package defined a GetError error conversion function. This function has been removed from the package.
  • The rbd Image Open() method is deprecated and may be removed in the future. Use the OpenImage function variants instead.
  • Functions deprecated in Ceph "Nautilus" are no longer used in go-ceph. Rather, compatible replacement functions are used. Use Go build flags to select for older Ceph versions if needed [1]

Other

  • Various improvements to the test scripts and tooling
  • Improve documentation for many existing types and function calls
  • Removed printing calls and logging calls
  • A number of tests have been added for functions that lacked them
  • The handling of "errno-style" error handling across all packages has been unified
  • The go-ceph library is now a Go module [2]
  • Many other fixes and improvements

Please use our GitHub Issue Tracker [3] to contact us about bugs, questions, or comments. The maintainers actively monitor this resource and it is the most effective way to reach us about go-ceph at this time.

[1] - #139

[2] - https://github.com/golang/go/wiki/Modules

[3] - https://github.com/ceph/go-ceph/issues