-
Notifications
You must be signed in to change notification settings - Fork 163
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add ZSTD compression #367
Add ZSTD compression #367
Conversation
@Enmk Could you please trigger CI for this? |
case static_cast<uint8_t>(CompressionMethodByte::NONE): { | ||
|
||
throw CompressionError("compression method not defined" + std::to_string((method))); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please handle invalid\unsupported compression methods too:
} | |
} | |
default: | |
throw CompressionError("Unknown or unsupported compression method " + std::to_string((method))); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some modifications required
clickhouse/base/compressed.h
Outdated
}; | ||
|
||
// see DB::CompressionMethodByte from src/Compression/CompressionInfo.h of ClickHouse project | ||
enum class CompressionMethodByte : uint8_t { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is that a part of the public API that users should know about? If not, please move away from the headers to the cpp.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
moved to cpp
clickhouse/client.h
Outdated
@@ -3,6 +3,8 @@ | |||
#include "query.h" | |||
#include "exceptions.h" | |||
|
|||
#include "base/compressed.h" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
IMO this is not the best decision: clients are not expected to rely on stuff in base
, at least explicitly. I think it is best to move the CompressionMethod
declaration back to client.h
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
To resolve #35