]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mon/PGMap: fix spacing around pretty-printed SI units 23471/head
authorSage Weil <sage@redhat.com>
Tue, 7 Aug 2018 13:48:45 +0000 (08:48 -0500)
committerSage Weil <sage@redhat.com>
Wed, 8 Aug 2018 15:55:18 +0000 (10:55 -0500)
"1k foo" not "1kfoo"

Signed-off-by: Sage Weil <sage@redhat.com>
qa/workunits/cephtool/test.sh
src/mon/PGMap.cc

index b7209de0ed93b5db6c37650dbbb40b7ed5952d42..d433c180539d9865997b5c2dbf8b446e71c0e8f7 100755 (executable)
@@ -1786,7 +1786,7 @@ function test_mon_osd_pool_quota()
   # get quotas
   #
   ceph osd pool get-quota tmp-quota-pool | grep 'max bytes.*10 B'
-  ceph osd pool get-quota tmp-quota-pool | grep 'max objects.*10 M objects'
+  ceph osd pool get-quota tmp-quota-pool | grep 'max objects.*10.*M objects'
   #
   # set valid quotas with unit prefix
   #
index 1c622625eb104d010ebbc7f5174f6b9b83d00e72..a1b8c70957474c958b6182611a94af7c8dc52425 100644 (file)
@@ -376,7 +376,7 @@ void PGMapDigest::print_oneline_summary(Formatter *f, ostream *out) const
     }
     int64_t iops = (pos_delta.stats.sum.num_rd + pos_delta.stats.sum.num_wr) / (double)stamp_delta;
     if (out)
-      *out << si_u_t(iops) << "op/s";
+      *out << si_u_t(iops) << " op/s";
     if (f)
       f->dump_unsigned("io_sec", iops);
   }
@@ -470,8 +470,8 @@ void PGMapDigest::recovery_rate_summary(Formatter *f, ostream *out,
     } else {
       *out << byte_u_t(bps) << "/s";
       if (pos_delta.stats.sum.num_keys_recovered)
-       *out << ", " << si_u_t(kps) << "keys/s";
-      *out << ", " << si_u_t(objps) << "objects/s";
+       *out << ", " << si_u_t(kps) << " keys/s";
+      *out << ", " << si_u_t(objps) << " objects/s";
     }
   }
 }
@@ -538,7 +538,7 @@ void PGMapDigest::client_io_rate_summary(Formatter *f, ostream *out,
       f->dump_int("read_op_per_sec", iops_rd);
       f->dump_int("write_op_per_sec", iops_wr);
     } else {
-      *out << si_u_t(iops_rd) << "op/s rd, " << si_u_t(iops_wr) << "op/s wr";
+      *out << si_u_t(iops_rd) << " op/s rd, " << si_u_t(iops_wr) << " op/s wr";
     }
   }
 }
@@ -595,7 +595,7 @@ void PGMapDigest::cache_io_rate_summary(Formatter *f, ostream *out,
     } else {
       if (have_output)
        *out << ", ";
-      *out << si_u_t(promote) << "op/s promote";
+      *out << si_u_t(promote) << " op/s promote";
       have_output = true;
     }
   }
@@ -605,7 +605,7 @@ void PGMapDigest::cache_io_rate_summary(Formatter *f, ostream *out,
     } else {
       if (have_output)
        *out << ", ";
-      *out << si_u_t(pos_delta.stats.sum.num_flush_mode_low) << "PG(s) flushing";
+      *out << si_u_t(pos_delta.stats.sum.num_flush_mode_low) << " PGs flushing";
       have_output = true;
     }
   }
@@ -615,7 +615,7 @@ void PGMapDigest::cache_io_rate_summary(Formatter *f, ostream *out,
     } else {
       if (have_output)
        *out << ", ";
-      *out << si_u_t(pos_delta.stats.sum.num_flush_mode_high) << "PG(s) flushing (high)";
+      *out << si_u_t(pos_delta.stats.sum.num_flush_mode_high) << " PGs flushing (high)";
       have_output = true;
     }
   }
@@ -625,7 +625,7 @@ void PGMapDigest::cache_io_rate_summary(Formatter *f, ostream *out,
     } else {
       if (have_output)
        *out << ", ";
-      *out << si_u_t(pos_delta.stats.sum.num_evict_mode_some) << "PG(s) evicting";
+      *out << si_u_t(pos_delta.stats.sum.num_evict_mode_some) << " PGs evicting";
       have_output = true;
     }
   }
@@ -635,7 +635,7 @@ void PGMapDigest::cache_io_rate_summary(Formatter *f, ostream *out,
     } else {
       if (have_output)
        *out << ", ";
-      *out << si_u_t(pos_delta.stats.sum.num_evict_mode_full) << "PG(s) evicting (full)";
+      *out << si_u_t(pos_delta.stats.sum.num_evict_mode_full) << " PGs evicting (full)";
     }
   }
 }