zstd is no longer in beta -- s/ZSTD_BETA/ZSTD/g
authorChip Turner <chip@fb.com>
Thu, 1 Sep 2016 23:40:08 +0000 (16:40 -0700)
committerFacebook Github Bot <facebook-github-bot-bot@fb.com>
Thu, 1 Sep 2016 23:53:46 +0000 (16:53 -0700)
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
folly/io/Compression.h
folly/io/test/CompressionTest.cpp

index 356699cf49f2487635d6e21fc97049469d92c934..d83a7b5cabca70c0162e7bd1b5b264af7d4ae023 100644 (file)
@@ -946,7 +946,7 @@ std::unique_ptr<IOBuf> 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<Codec> 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;
index 3575d8e4837acbb91f565bbcbf4a2941b7486a65..3d46d4c5a0b2e91ddea14902769b4986ce6d7a73 100644 (file)
@@ -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
index a1d48b9d6e2e494308cf10aa3ddb50fc5bde7026..d0d35af28a2de03ff9457cbf684baca29aef07e5 100644 (file)
@@ -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