From c78f92a01dfdd0cc4eff81e90dd9e0832fd77bfc Mon Sep 17 00:00:00 2001 From: Chip Turner Date: Thu, 1 Sep 2016 16:40:08 -0700 Subject: [PATCH] zstd is no longer in beta -- s/ZSTD_BETA/ZSTD/g Summary: itshappening Need to override unit test failures after repeated landing failures unrelated to the change. Reviewed By: yfeldblum Differential Revision: D3803301 fbshipit-source-id: b6581e3d2ff6baba57eb0f61b890a61107118bf7 --- folly/io/Compression.cpp | 4 ++-- folly/io/Compression.h | 6 ++---- folly/io/test/CompressionTest.cpp | 4 ++-- 3 files changed, 6 insertions(+), 8 deletions(-) diff --git a/folly/io/Compression.cpp b/folly/io/Compression.cpp index 356699cf..d83a7b5c 100644 --- a/folly/io/Compression.cpp +++ b/folly/io/Compression.cpp @@ -946,7 +946,7 @@ std::unique_ptr LZMA2Codec::doUncompress(const IOBuf* data, #ifdef FOLLY_HAVE_LIBZSTD /** - * ZSTD_BETA compression + * ZSTD compression */ class ZSTDCodec final : public Codec { public: @@ -968,7 +968,7 @@ std::unique_ptr ZSTDCodec::create(int level, CodecType type) { } ZSTDCodec::ZSTDCodec(int level, CodecType type) : Codec(type) { - DCHECK(type == CodecType::ZSTD_BETA); + DCHECK(type == CodecType::ZSTD); switch (level) { case COMPRESSION_LEVEL_FASTEST: level_ = 1; diff --git a/folly/io/Compression.h b/folly/io/Compression.h index 3575d8e4..3d46d4c5 100644 --- a/folly/io/Compression.h +++ b/folly/io/Compression.h @@ -73,11 +73,9 @@ enum class CodecType { LZMA2_VARINT_SIZE = 7, /** - * Use ZSTD_BETA compression. - * This format is not yet final; please do not rely on it for anything other - * than testing purposes yet. + * Use ZSTD compression. */ - ZSTD_BETA = 8, + ZSTD = 8, /** * Use gzip compression. This is the same compression algorithm as ZLIB but diff --git a/folly/io/test/CompressionTest.cpp b/folly/io/test/CompressionTest.cpp index a1d48b9d..d0d35af2 100644 --- a/folly/io/test/CompressionTest.cpp +++ b/folly/io/test/CompressionTest.cpp @@ -128,7 +128,7 @@ TEST(CompressionTestNeedsUncompressedLength, Simple) { EXPECT_TRUE(getCodec(CodecType::LZMA2)->needsUncompressedLength()); EXPECT_FALSE(getCodec(CodecType::LZMA2_VARINT_SIZE) ->needsUncompressedLength()); - EXPECT_TRUE(getCodec(CodecType::ZSTD_BETA)->needsUncompressedLength()); + EXPECT_TRUE(getCodec(CodecType::ZSTD)->needsUncompressedLength()); EXPECT_FALSE(getCodec(CodecType::GZIP)->needsUncompressedLength()); } @@ -183,7 +183,7 @@ INSTANTIATE_TEST_CASE_P( CodecType::LZ4_VARINT_SIZE, CodecType::LZMA2, CodecType::LZMA2_VARINT_SIZE, - CodecType::ZSTD_BETA, + CodecType::ZSTD, CodecType::GZIP))); class CompressionVarintTest -- 2.34.1