]> git.proxmox.com Git - ceph.git/blobdiff - ceph/src/rgw/services/svc_notify.h
import ceph 16.2.6
[ceph.git] / ceph / src / rgw / services / svc_notify.h
index 5b01d77b7bfc05c477fcfb5589ab3188a720bfc7..d4e3e2f5102103109490009724a93e02ae59c20e 100644 (file)
@@ -15,6 +15,7 @@ class RGWSI_Finisher;
 
 class RGWWatcher;
 class RGWSI_Notify_ShutdownCB;
+struct RGWCacheNotifyInfo;
 
 class RGWSI_Notify : public RGWServiceInstance
 {
@@ -41,7 +42,7 @@ private:
   bool enabled{false};
 
   double inject_notify_timeout_probability{0};
-  unsigned max_notify_retries{0};
+  static constexpr unsigned max_notify_retries = 10;
 
   string get_control_oid(int i);
   RGWSI_RADOS::Obj pick_control_obj(const string& key);
@@ -78,9 +79,8 @@ private:
   void _set_enabled(bool status);
   void set_enabled(bool status);
 
-  int robust_notify(const DoutPrefixProvider *dpp, 
-                    RGWSI_RADOS::Obj& notify_obj, bufferlist& bl,
-                    optional_yield y);
+  int robust_notify(const DoutPrefixProvider *dpp, RGWSI_RADOS::Obj& notify_obj,
+                   const RGWCacheNotifyInfo& bl, optional_yield y);
 
   void schedule_context(Context *c);
 public:
@@ -98,7 +98,8 @@ public:
       virtual void set_enabled(bool status) = 0;
   };
 
-  int distribute(const DoutPrefixProvider *dpp, const string& key, bufferlist& bl, optional_yield y);
+  int distribute(const DoutPrefixProvider *dpp, const string& key, const RGWCacheNotifyInfo& bl,
+                optional_yield y);
 
   void register_watch_cb(CB *cb);
 };