FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

Releases · hyperf/hyperf · GitHub

/ hyperf Public

Releases: hyperf/hyperf

Release v3.2.4

Choose a tag to compare

Filter
limingxinleo released this 10 Aug 14:11
58d9f50

Added

  • #7792 Added function Hyperf\Support\assert_instanceof().

Optimized

  • #7790 Support nacos v1 v2 and v3 for reading hosts from instance list.
  • #7796 Optimized race condition in StreamHandler when creating log directory under coroutine concurrency.

New Contributors

Full Changelog: v3.2.3...v3.2.4

Release v3.2.3

Choose a tag to compare

Filter
limingxinleo released this 30 Jul 06:08
b6ff374

Added

  • #7783 Added function Hyperf\Support\existent.

Fixed

  • #7782 Fixed incorrect @Property type in generated models, such as @property int $id -> @property ?int $id.
  • #7784 #7785 Fixed phpdoc for Hyperf\ModelCache\Cacheable.
  • #7786 Fixed phpdocs for Hyperf\Database\Model\Builder.
  • #7788 Fixed bug that MorphTo relationships eager loading specific columns.

Full Changelog: v3.2.2...v3.2.3

Release v3.2.2

Choose a tag to compare

Filter
limingxinleo released this 26 Jul 09:02
7532749

Removed

  • #7778 Removed deprecated code, including ConsumerProcess::$queue backward compatibility, forceIndexes() (use forceIndex()), str_replace_once() (use strReplaceOnce()), ClassLoader::loadDotenv(), GrpcClient::hanldeNaming(), the watcher legacy config fallback, and the deprecated RuleCollector, Tracer\Adapter\HttpClientFactory, Tracer\Aspect\JsonRpcAspect, and ViewEngine\Contract\Enumerable aliases.

Fixed

  • #7768 Fixed bug that Hyperf\Validation\Concerns\ValidatesAttributes::validateMultipleOf cannot support float.
  • #7771 Fixed bug that gen:migration-from-database cannot work.
  • #7774 Fixed bug that Hyperf\Di\ScanHandler\ProcScanHandler cannot work.

Full Changelog: v3.2.1...v3.2.2

Release v3.2.1

Choose a tag to compare

Filter
limingxinleo released this 15 Jun 10:23
1827445

Fixed

  • #7760 Fixed bug that ModelRewriteInheritanceVisitor cannot work for command gen:model.

Added

  • #7759 Added Hyperf\Logger\Handler\StreamHandler which don't contain set_error_handler.

Optimized

  • #7761 Optimized Hyperf\Coordinator\Timer::tick() to run the callback inside Hyperf\Coroutine\wait() so it executes in a properly managed coroutine context.
  • #7761 Optimize the wait() method to check whether Hyperf\Coroutine\Waiter exists in the Container.

Full Changelog: v3.2.0...v3.2.1

Release v3.1.70

Choose a tag to compare

Filter
huangdijia released this 16 Jun 01:29
2e8e5c4

What's Changed

  • docs: add indonesian translation for hyperf by @aldok10 in #7752
  • Optimized Hyperf\Coordinator\Timer::tick() to run the callback inside Hyperf\Coroutine\wait() so it executes in a properly managed coroutine context. by @huangdijia in #7761
  • Release v3.1.70 by @limingxinleo in #7762

Full Changelog: v3.1.69...v3.1.70

Release v3.2.0

Choose a tag to compare

Filter
limingxinleo released this 07 Jun 09:27
c40705c

Break Changes

  1. The BC of Carbon component

    • Carbon::createFromTimestamp() don't read the default timezone by date_default_timezone_get() for v3.0.
    • Carbon::diffInDays() no longer returns an absolute value by default. Use the $absolute parameter to control whether the result is absolute.
  2. #7625 Renamed JobInterface::getQueueName() to getPoolName() in async-queue component for terminology consistency.

<?php
// Before
class CustomJob extends \Hyperf\AsyncQueue\Job
{
    public function getQueueName(): string
    {
        return 'custom';
    }
}

// After
class CustomJob extends \Hyperf\AsyncQueue\Job
{
    public function getPoolName(): string
    {
        return 'custom';
    }
}
<?php

use Carbon\Carbon;

$t = time();

# The break usage
Carbon::createFromTimestamp($t, date_default_timezone_get());

# The correct usage
Carbon::createFromTimestamp($t, date_default_timezone_get());
  1. The logger configuration structure has been changed. Please refer to #7563.
<?php

// Before
return [
    'default' => [
        'driver' => 'daily',
        'path' => BASE_PATH . '/runtime/logs/hyperf.log',
        'level' => env('LOG_LEVEL', 'debug'),
        'days' => 7,
    ],
];

// After
return [
    'default' => 'default',
    'channels' => [
        'default' => [
            'driver' => 'daily',
            'path' => BASE_PATH . '/runtime/logs/hyperf.log',
            'level' => env('LOG_LEVEL', 'debug'),
            'days' => 7,
        ],
        // Add your custom channels here
    ],
];
  1. The cache configuration structure has been changed. Please refer to #7594.
<?php
// Before
return [
    'default' => [
        'driver' => RedisDriver::class,
        'packer' => PhpSerializerPacker::class,
        'prefix' => 'c:',
    ],
];

// After
return [
    'default' => env('CACHE_DRIVER', 'default'),
    'stores' => [
        'default' => [
            'driver' => RedisDriver::class,
            'packer' => PhpSerializerPacker::class,
            'prefix' => 'c:',
        ],
    ],
];
  1. Added dependencies when using swow.

config/autoload/dependencies.php

<?php
use Hyperf\Contract\ResponseEmitterInterface;
use Hyperf\Engine\ResponseEmitter;

return [
    ResponseEmitterInterface::class => ResponseEmitter::class,
];

Warn

  1. If you have upgraded to PHP 8.4, please note that both the fgetcsv and fputcsv methods now require providing a default value for the escape parameter.
fputcsv($fp, $fields) must be changed to fputcsv($fp, $fields, escape: '')
fgetcsv($fp) must be changed to fgetcsv($fp, escape: '')

Dependencies Upgrade

  • Upgrade the php version to >=8.2
  • Upgrade the elasticsearch/elasticsearch version to ^8.0 || ^9.0
  • Upgrade the nikic/php-parser version to 5.6
  • Upgrade the symfony/* components to ^6.0 || ^7.0
  • Upgrade the phpunit/phpunit version to ^11.0
  • Upgrade the version of google/protobuf to ^3.6.1 || ^4.2.
  • Upgrade the version of guzzlehttp/guzzle to ^7.0.

Removed

  • #7278 Removed abandoned laminas/laminas-mime package.
  • #7573 Removed deprecated Hyperf\Serializer\Contract\CacheableSupportsMethodInterface interface.
  • #7609 Removed backward compatibility code from Hyperf\AsyncQueue\JobMessage serialization.
  • #7610 Removed deprecated code scheduled for v3.2 removal, including Collection backward compatibility, ProxyTrait parameter mapping, ResumeExitCoordinatorListener, SocketIO Future flag parameter, and WebSocket HandeShakeException typo alias.

Optimized

  • #6804 Optimized the code for reading contents from file when using Hyperf\Di\ReflectionManager::getAllClassesByFinder().
  • #7142 Enhance array shuffle method to support custom random engines.
  • #7431 Optimized the toCssClasses and toCssStyles methods by directly using the input array to simplify the code logic.
  • #7523 Modernize array utilities and JSON validation using PHP 8.4+ functions with polyfills.
  • #7620 Added Symfony 7.4 compatibility with batch command registration.
  • #7653 Improved Parser::parseResponse return value format by replacing Grpc\StringifyAble with Google\Rpc\Status objects for better standardization and code readability.
  • #7658 Optimized event listener provider by adding cache for non-anonymous event classes to avoid repeated listener resolution.

Added

  • #6538 Support to specify the queue name based on the job.
  • #6591 Support v3.0 for nesbot/carbon.
  • #6761 Added toJson method to Hyperf\Contract\Jsonable.
  • #6794 feat: Add Htmlable contract interface for HTTP responses.
  • #7019 Added PDO subclass support for PHP 8.4.
  • #7198 Added connection name to QueryException.
  • #7202 Added support for elasticsearch 8.x.
  • #7629 Added support for elasticsearch 9.x.
  • #7214 Improve Hyperf\Support\Fluent.
  • #7247 Added Hyperf\Pipeline\Pipeline::finally().
  • #7274 Support to take multiple items for shift() and pop() in Hyperf\Collection\Collection.
  • #7302 Added partition() and reject() to Hyperf\Collection\Arr.
  • #7312 Added Macroable support to Hyperf\Context\Context.
  • #7605 Added NonCoroutine attribute for flexible test execution control.
  • #7618 Added a new registration mode for async queue consumer processes that supports automatic registration based on configuration, eliminating the need for manual process registration in config/autoload/processes.php.
  • #7621 Added timestamp prefix to StdoutLogger output format.
  • #7717 Added package database-sqlserver.

Changed

  • #6760 Changed the default type of deleted_at to datetime for hyperf/database.
  • #7208 Throw exceptions when the value is smaller than zero for Hyperf\Database\Query\Builder::limit().
  • #7372 Use empty string as escape for function str_getcsv.
  • #7462 Replaced influxdb/influxdb-php into influxdata/influxdb-client-php.
  • #7563 Changed the logger configuration structure.
  • #7594 Changed the cache configuration structure.
  • #7615 Renamed $queue property to $pool in ConsumerProcess for async-queue component.
  • #7625 Renamed getQueueName() to getPoolName() in async-queue component for terminology consistency.
  • #7714 Don't support Monolog 2.x, only 3.x is supported.

Fixed

  • #6934 Fixed bug that sortByMany() don't return the same result like sortBy().

New Contributors

Full Changelog: v3.1.63...v3.2.0

Release v3.1.69

Choose a tag to compare

Filter
limingxinleo released this 09 May 02:22
c28fdd7

Fixed

  • #7731 Fixed bug that the Macroable of Hyperf\HttpServer\Response cannot work.
  • #7734 Fixed bug that memory leak when using Redis::pipeline() for long-lived environment.
  • #7736 Fixed bug that keys method in RedisDriver does not return array when sMembers returns a non-array value.
  • #7737 Fixed bug that PostgresProcessor cannot process indexes and foreign keys when columns is null.
  • #7745 Fixed bug that getUri()->getHost() returns server IP instead of domain when using Swoole 6.2.0, due to server_addr having higher priority than header['host'] in getUriFromGlobals().

New Contributors

Full Changelog: v3.1.68...v3.1.69

Release v3.1.68

Choose a tag to compare

Filter
limingxinleo released this 21 Apr 09:04
e611146

Fixed

  • #7738 Fixed bug that Hyperf\Database\Concerns\BuildsQueries::getOriginalColumnNameForCursorPagination cannot work.
  • #7739 Fixed bug that http server broken by nacos service not found.
  • #7740 Fixed bug that Aws\Handler\GuzzleV6\GuzzleHandler not found.

Optimized

  • #7741 Optimized the Hyperf\Amqp\Message\Message::getTypeString() method to prevent conflicts between property and getter methods.

Full Changelog: v3.1.67...v3.1.68

Release v3.1.67

Choose a tag to compare

Filter
limingxinleo released this 24 Feb 02:51
38fdb8b

Added

  • #7459 Support using model name like App\\Model\\User for validation rule exists and unique.
  • #7555 Added Hyperf\Crontab\Mutex\RedisServerMutexByNodeName.
  • #7607 Added casts AsCollection for hyperf/database.
  • #7648 Support aliyun mse signature for nacos.

Optimized

  • #7676 Optimized the client tagging for hyperf/tracer.

Fixed

  • #7703 Fixed bug that the default ttl cannot work for memory driver of hyperf/cache.
  • #7705 Fixed bug that eachById cannot work for Hyperf\Database\Query\Builder.
  • #7712 Fixed bug that the classes cache cannot decode.

New Contributors

Full Changelog: v3.1.66...v3.1.67

Release v3.1.66

Choose a tag to compare

Filter
limingxinleo released this 25 Jan 07:42
6e12cf3

Added

  • #7667 #7672 Added support for client_count option to create multiple gRPC clients with load balancing in hyperf/grpc-client.
  • #7668 Added the $isCookiePersistent parameter to Hyperf\Guzzle\PoolHandler to enable persistent cookies.
  • #7670 Added --path option to generator commands for specifying custom output locations.
  • #7684 Added method Hyperf\Database\Schema\Builder::withoutForeignKeyConstraints().
  • #7693 Added methods cascadeOnDelete(), restrictOnDelete(), noActionOnDelete(), restrictOnUpdate(), nullOnUpdate(), noActionOnUpdate() for ForeignKeyDefinition.
  • #7698 Added Pool::flushAll() and PoolFactory::flushAll() methods to close all pool connections.
  • #7699 Added methods whereJsonContainsKey(), orWhereJsonContainsKey(), whereJsonDoesntContainKey(), orWhereJsonDoesntContainKey() for Query Builder.

Optimized

  • #7675 Removed redundant timer cleanup code from metric listeners since the Timer component now handles cleanup automatically.
  • #7687 Optimized handling of ValidationException in JSON-RPC core middleware to properly return INVALID_PARAMS error responses.

Fixed

  • #7669 Fix PostgreSQL boolean handling for emulated prepares and raw SQL.
  • #7682 Fixed incorrect return type for Blueprint::foreign() which caused static analysis errors when chaining references(), on(), etc.

New Contributors

Full Changelog: v3.1.65...v3.1.66


Back | FazBrowse Home | New Git URL