You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@iotdb.apache.org by "SteveYurongSu (via GitHub)" <gi...@apache.org> on 2023/03/08 06:26:26 UTC
[GitHub] [iotdb] SteveYurongSu commented on a diff in pull request #9231: [IOTDB-2569]Support ZSTD Compression
SteveYurongSu commented on code in PR #9231:
URL: https://github.com/apache/iotdb/pull/9231#discussion_r1129020921
##########
tsfile/src/main/java/org/apache/iotdb/tsfile/compress/IUnCompressor.java:
##########
@@ -312,4 +315,45 @@ public CompressionType getCodecName() {
return CompressionType.GZIP;
}
}
+
+ class ZstdUnCompressor implements IUnCompressor {
+
+ @Override
+ public int getUncompressedLength(byte[] array, int offset, int length) throws IOException {
+ return (int) Zstd.decompressedSize(array, offset, length);
+ }
+
+ @Override
+ public int getUncompressedLength(ByteBuffer buffer) throws IOException {
+ return (int) Zstd.decompressedSize(buffer);
Review Comment:
Is this a time-consuming call?
##########
tsfile/src/main/java/org/apache/iotdb/tsfile/compress/IUnCompressor.java:
##########
@@ -312,4 +315,45 @@ public CompressionType getCodecName() {
return CompressionType.GZIP;
}
}
+
+ class ZstdUnCompressor implements IUnCompressor {
+
+ @Override
+ public int getUncompressedLength(byte[] array, int offset, int length) throws IOException {
+ return (int) Zstd.decompressedSize(array, offset, length);
Review Comment:
Is this a time-consuming call?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@iotdb.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org