Skip to content

Commit

Permalink
error when hitting compression of kv-ir until functionality is added
Browse files Browse the repository at this point in the history
  • Loading branch information
AVMatthews committed Dec 5, 2024
1 parent 2f3365f commit 02159d9
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
11 changes: 5 additions & 6 deletions components/core/src/clp_s/CommandLineArguments.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,9 @@ CommandLineArguments::parse_arguments(int argc, char const** argv) {
po::options_description compression_options("Compression options");
std::string metadata_db_config_file_path;
std::string input_path_list_file_path;
std::string file_type;
constexpr std::string_view cJsonFileType{"json"};
constexpr std::string_view cKeyValueIrFileType{"kv-ir"};
std::string file_type{cJsonFileType};
// clang-format off
compression_options.add_options()(
"compression-level",
Expand Down Expand Up @@ -205,8 +207,8 @@ CommandLineArguments::parse_arguments(int argc, char const** argv) {
"Do not record log order at ingestion time."
)(
"file-type",
po::value<std::string>(&file_type)->value_name("FILE_TYPE"),
"The type of file that is to be compressed to archive (e.g json or kv-ir)"
po::value<std::string>(&file_type)->value_name("FILE_TYPE")->default_value(file_type),
"The type of file being compressed (json or kv-ir)"
);
// clang-format on

Expand Down Expand Up @@ -260,9 +262,6 @@ CommandLineArguments::parse_arguments(int argc, char const** argv) {
throw std::invalid_argument("No input paths specified.");
}

constexpr std::string_view cJsonFileType{"json"};
constexpr std::string_view cKeyValueIrFileType{"kv-ir"};

if (parsed_command_line_options.count("file-type") > 0) {
if (cJsonFileType == file_type) {
m_file_type = FileType::Json;
Expand Down
2 changes: 2 additions & 0 deletions components/core/src/clp_s/clp-s.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,8 @@ bool compress(CommandLineArguments const& command_line_arguments) {
// Functionality Coming in later PR
// -->Call new parsing function in Json Parser to parse IRv2 to archive
// -->Check for error from parsing function
SPDLOG_ERROR("Compressing Key Valur IR Files is not yet supported");
return false;
} else {
if (false == parser.parse()) {
SPDLOG_ERROR("Encountered error while parsing input");
Expand Down

0 comments on commit 02159d9

Please sign in to comment.