]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
librbd: the journal SnapLimitEvent was not properly handled
authorJason Dillaman <dillaman@redhat.com>
Fri, 14 Feb 2020 14:35:43 +0000 (09:35 -0500)
committerJason Dillaman <dillaman@redhat.com>
Fri, 21 Feb 2020 14:03:09 +0000 (09:03 -0500)
It was not being properly decoded since it was missing from the
factory and it would output as an "Unknown" event code.

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
src/librbd/journal/Types.cc

index ee919d35d7b54ee874a1521279b6585577406057..d76a15e557cecb7f0723878197a84b10401d4a52 100644 (file)
@@ -471,6 +471,9 @@ void EventEntry::decode(bufferlist::const_iterator& it) {
   case EVENT_TYPE_DEMOTE_PROMOTE:
     event = DemotePromoteEvent();
     break;
+  case EVENT_TYPE_SNAP_LIMIT:
+    event = SnapLimitEvent();
+    break;
   case EVENT_TYPE_UPDATE_FEATURES:
     event = UpdateFeaturesEvent();
     break;
@@ -831,6 +834,9 @@ std::ostream &operator<<(std::ostream &out, const EventType &type) {
   case EVENT_TYPE_DEMOTE_PROMOTE:
     out << "Demote/Promote";
     break;
+  case EVENT_TYPE_SNAP_LIMIT:
+    out << "SnapLimit";
+    break;
   case EVENT_TYPE_UPDATE_FEATURES:
     out << "UpdateFeatures";
     break;