Commit e6b87245 authored by Ramon Nou's avatar Ramon Nou
Browse files

Testing stats

parent deefa105
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -61,6 +61,7 @@ gkfs:
      -DGKFS_USE_GUIDED_DISTRIBUTION:BOOL=ON
      -DGKFS_ENABLE_PARALLAX:BOOL=ON
      -DGKFS_ENABLE_ROCKSDB:BOOL=ON
      -DGKFS_CHUNK_STATS:BOOL=ON
      ${CI_PROJECT_DIR}
    - make -j$(nproc) install
    # reduce artifacts size
+4 −0
Original line number Diff line number Diff line
@@ -52,6 +52,10 @@ if(GKFS_ENABLE_CODE_COVERAGE)
  target_code_coverage(distributor AUTO)
endif()

if(GKFS_ENABLE_CODE_COVERAGE)
  target_code_coverage(statistics AUTO)
endif()

# get spdlog
set(FETCHCONTENT_QUIET ON)

+2 −1
Original line number Diff line number Diff line
@@ -219,6 +219,7 @@ void
FsData::parallax_size_md(unsigned int size_md) {
    FsData::parallax_size_md_ = static_cast<unsigned long long>(
            size_md * 1024ull * 1024ull * 1024ull);
}

const std::shared_ptr<gkfs::utils::Stats>&
FsData::stats() const {
+4 −5
Original line number Diff line number Diff line
@@ -586,11 +586,6 @@ parse_input(const cli_options& opts, const CLI::App& desc) {
    fs::create_directories(rootdir_path);
    GKFS_DATA->rootdir(rootdir_path.native());

    if(desc.count("--output-stats")) {
        GKFS_DATA->output_stats(true);
    }


    if(desc.count("--metadir")) {
        auto metadir = opts.metadir;

@@ -655,9 +650,13 @@ parse_input(const cli_options& opts, const CLI::App& desc) {

    if(desc.count("--parallaxsize")) { // Size in GB
        GKFS_DATA->parallax_size_md(stoi(opts.parallax_size));
    }
    if(desc.count("--output-stats")) {
        auto stats_file = opts.stats_file;
        GKFS_DATA->stats_file(stats_file);
        GKFS_DATA->output_stats(true);
        GKFS_DATA->spdlogger()->debug("{}() Stats Enabled: '{}'", __func__,
                                      stats_file);
    }
}

+2 −1
Original line number Diff line number Diff line
@@ -251,7 +251,8 @@ class Daemon:
                 '--rootdir', self.rootdir,
                 '-l', self._address,
                 '--metadir', self._metadir,
                 '--dbbackend', self._database]
                 '--dbbackend', self._database, 
                 '--output-stats', self.logdir / 'stats.log' ]
        if self._database == "parallaxdb" :
            args.append('--clean-rootdir-finish')

+1 −1

File changed.

Contains only whitespace changes.

Loading