github kjdev/php-ext-zstd 0.15.0

latest releases: 0.15.2, 0.15.1
24 days ago

๐Ÿš€ Major Features

  • Incremental Compression: Added zstd_(un)compress_init() and zstd_(un)compress_add() functions for streaming compression
    • 227ee4b Add incremental zstd_(un)compress_init() and zstd_(un)compress_add()
    • f9f707c refactor: zstd_compress_init() using php_zstd_context_create_compress()
    • d655ae2 refactor: zstd_compress_add() to use zend_string for input parameter
    • a7d5961 refactor: zstd_uncompress_init() using php_zstd_context_create_decompress()
    • bfca581 refactor: zstd_uncompress_add() to use zend_string for input parameter
  • ZstdContext Classes: Introduced Zstd\Compress\Context and Zstd\Uncompress\Context classes for object-oriented streaming
    • 91b8efa Add ZstdContext class stub
    • 8dac0f1 ZstdContext only exists in global namespace
    • 527741c refactor: ZstdContext -> ZstdUn)Compress\Context
    • 044cc55 Merge branch 'thekid-feature/incremental-obj'
  • Dictionary Support: Added dictionary parameter to compress and uncompress functions
    • cd8b88d feat: add dictionary parameter to compress and uncompress functions
    • ca71506 add: ddict field to php_zstd_context{} struct and handle its allocation/freeing
  • Named Arguments: Support for PHP 8.0+ named arguments
    • 6c144a6 feat: named arguments support (PHP 8.0+)
    • 8b8e84c test: add named arguments

๐Ÿ†™ Updates

  • Zstd Library: Updated to zstd 1.5.7
    • c53fd8d Update to zstd 1.5.7
    • ac2cef8 Merge pull request #80 from JakubOnderka/zstd-1.5.7
  • Constants Unification: Renamed constants for consistency:
    • f008254 refactor: rename constant LIBZSTD_VERSION_NUMBER -> ZSTD_VERSION_NUMBER
    • c93ac2e refactor: rename constant LIBZSTD_VERSION_STRING -> ZSTD_VERSION_STRING
    • 67222e3 refactor: replace all instances of DEFAULT_COMPRESS_LEVEL with ZSTD_CLEVEL_DEFAULT for consistency
    • 214a63f refactor: change default zstd.output_compression_level

๐Ÿงช Experimental Features

  • DCZ Support: Experimental compression dictionary transport support in output handler
    • 5c6d757 experimental: dcz support in output handler
    • ff9a729 test: add dcz output handler
    • fe87c47 docs: add experimental compression dictionary transport support info

๐Ÿ”ง Technical Improvements

  • Refactored internal compression/decompression to use stream-based approach with php_zstd_context{}
    • 6a88aea refactor: extract initialization logic into php_zstd_context_init()
    • 7415731 change: zstd_compress() to stream-based using php_zstd_context{}
    • 2c02139 change: zstd_compress_dict() to stream-based using php_zstd_context{}
    • 986e054 change: zstd_uncompress() to stream-based using php_zstd_context{}
    • d0e0806 change: zstd_uncompress_dict() to stream-based using php_zstd_context{}
    • 1a92e55 refactor: change php_zstd_stream_data{} to use ctx of php_zstd_context{}
  • Enhanced output handler with dictionary support
    • 0676513 change: php_zstd_output_handler_load_dict() to return dict data
    • 1fb430b fix: simplify output handler context start by removing intermediate variable and adding compression coding check
  • Improved error handling and memory management
    • cb6a848 remove: unused zstd_string_output_truncate()
    • bb58ed7 change: error message
    • bbc3adc refactor: zend parse parameters sets the return value on error to false
    • 96d5dce use Zend/zend_smart_string.h
    • e061583 Merge pull request #88 from remicollet/issue-php85-alpha3

๐Ÿ› Bug Fixes

  • Fixed streaming compressed data with zstd_uncompress_dict()
    • 80a5099 fix: streaming compressed data with zstd_uncompress_dict()
    • 8ed8865 test: add streaming compressed data with zstd_uncompress_dict()

๐Ÿ“š Documentation & Testing

  • Updated README.md with new features and minimum libzstd version requirements
    • 29b493e docs: update README.md and zstd.stub.php
    • b480694 docs: update README.md and zstd.stub.php
    • c6b079e docs: add minimu system libzstd library version to README.md
  • Added comprehensive tests for new functionality
    • 2575466 test: change to fit the minimum system libzstd library version
    • c121499 test: change error messages
    • 3dadf05 test: update error message for zstd_uncompress to reflect correct argument expectation
    • 34da37f test: addn and update update dict arguments
  • Updated stub files for better IDE support
    • e8cbb01 Fix wording
    • 92ab1cc chore: update test file permissions to non-executable

๐Ÿ”จ Build & CI

  • Enhanced Windows build process with appropriate toolset selection
    • d49a668 chore(ci): update windows script
    • cdc42be chore(ci): change arch for windows dll: x64 -> x86_64
    • 8afadfc chore(ci): update build script to select appropriate toolset and use latest windows runner
  • Added binary attributes for zstd and dict files in gitattributes
    • 4cc370f chore: add binary attributes for zstd and dict files in gitattributes
  • Updated CI workflows with proper permissions
    • 19f9cbc chore(.github/workflows): add permissions

Full Changelog: 0.14.0+pie...0.15.0

Don't miss a new php-ext-zstd release

NewReleases is sending notifications on new releases.