]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
rgw: RGWRestConn allow keys to be initialized
authorAbhishek Lekshmanan <abhishek@suse.com>
Thu, 23 Feb 2017 10:12:31 +0000 (11:12 +0100)
committerYehuda Sadeh <yehuda@redhat.com>
Tue, 10 Apr 2018 15:03:10 +0000 (08:03 -0700)
This allows for other s3 clients to be created, we previously only set
the value of S3 system key from rados.

Signed-off-by: Abhishek Lekshmanan <abhishek@suse.com>
src/rgw/rgw_rest_conn.cc
src/rgw/rgw_rest_conn.h

index d087c5a323003b4bb6f1fa8182bea3a7b36cb4a7..a8871efdd47efebe1e381e603035d9a4d57fb9dc 100644 (file)
@@ -8,9 +8,11 @@
 
 RGWRESTConn::RGWRESTConn(CephContext *_cct, RGWRados *store,
                          const string& _remote_id,
-                         const list<string>& remote_endpoints)
+                         const list<string>& remote_endpoints,
+                         RGWAccessKey _cred)
   : cct(_cct),
     endpoints(remote_endpoints.begin(), remote_endpoints.end()),
+    key(std::move(_cred)),
     remote_id(_remote_id)
 {
   if (store) {
index e9941856f577132603a3fa08009fbec6ac31d505..32c7e673e86ce3f29fe0d0776f1b704348547f34 100644 (file)
@@ -60,7 +60,8 @@ class RGWRESTConn
 
 public:
 
-  RGWRESTConn(CephContext *_cct, RGWRados *store, const string& _remote_id, const list<string>& endpoints);
+  RGWRESTConn(CephContext *_cct, const string& _remote_id, const list<string>& endpoints, RGWAccessKey _cred);
+
   // custom move needed for atomic
   RGWRESTConn(RGWRESTConn&& other);
   RGWRESTConn& operator=(RGWRESTConn&& other);