Module: CephStorage::StorageObject::RadosWrapper

Included in:
RadosStorageObject, RadosStorageObjectEnumerator, Xattr, XattrEnumerator
Defined in:
lib/ceph_storage/storage_object/rados_wrapper.rb

Overview

This code is here to wrap around CephRuby::rados_object Methods. It assigns one of the pool_factory cartridges to the RadosObject

Instance Method Summary collapse

Instance Method Details

#wrap_me(*method_names) ⇒ Object



7
8
9
10
11
12
13
14
15
16
17
18
# File 'lib/ceph_storage/storage_object/rados_wrapper.rb', line 7

def wrap_me(*method_names)
  method_names.each do |m|
    define_method(m) do |*args|
      log("#{m} wrapping with rados_pool")
      pool_factory.rados_pool do |p|
        p.ensure_open
        self.pool = p
        super(*args)
      end
    end
  end
end