Commit 00f5f7d3 authored by Marc Vef's avatar Marc Vef
Browse files

Only run statistics code if enabled

parent d56480aa
Loading
Loading
Loading
Loading
+4 −3
Original line number Diff line number Diff line
@@ -295,6 +295,7 @@ init_environment() {
#endif

    // Initialize Stats
    if(GKFS_DATA->enable_stats() || GKFS_DATA->enable_chunkstats())
        GKFS_DATA->stats(std::make_shared<gkfs::utils::Stats>(
                GKFS_DATA->enable_chunkstats(), GKFS_DATA->enable_prometheus(),
                GKFS_DATA->stats_file(), GKFS_DATA->prometheus_gateway()));