9.6 KiB
Executable file
9.6 KiB
Executable file
Change Log
All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog and this project adheres to Semantic Versioning.
3.3.0 - 2021-07-04
Added
- Support for psr/container v2.x #26
3.2.0 - 2020-11-30
Fixed
3.1.0 - 2020-01-19
Changed
- Zend Diactoros is deprecated, switched to Laminas Diactoros #20, #21.
THIS IS A BREAKING CHANGE, so, if you want to keep using Zend Diactoros, you should configure the
Factoryas follows:Factory::setFactory( new FactoryDiscovery([ 'request' => 'Zend\Diactoros\RequestFactory', 'response' => 'Zend\Diactoros\ResponseFactory', 'serverRequest' => 'Zend\Diactoros\ServerRequestFactory', 'stream' => 'Zend\Diactoros\StreamFactory', 'uploadedFile' => 'Zend\Diactoros\UploadedFileFactory', 'uri' => 'Zend\Diactoros\UriFactory', ]) );
3.0.1 - 2019-11-29
Fixed
- Moved a dependency to dev
- Updated docs
3.0.0 - 2019-11-29
Added
- Added
FactoryInterfacethat returns all PSR-17 factories - Added
FactoryDiscoveryclass to discover automatically PSR-17 implementation libraries - Added
Factory::getFactory()andFactory::setFactory()to set manually PSR-17 factories - Added
Factory::getResponseFactory() - Added
Factory::getRequestFactory() - Added
Factory::getServerRequestFactory() - Added
Factory::getStreamFactory() - Added
Factory::getUriFactory() - Added
Factory::getUploadedFileFactory() - Added
Sunriseto the list of factories detected automatically
Removed
- Support for PHP 7.0 and 7.1
Factory::setStrategyHttpErrorException::setContextmethod, to make the exception class inmutable- Traits
HasResponseFactoryandHasStreamFactory
2.2.0 - 2019-03-05
Added
2.1.1 - 2018-08-11
Added
- Added
Nyholm\Psr7to the list of factories detected automatically
2.1.0 - 2018-08-02
Added
- New trait
HasResponseFactoryused by many middlewares that need to configure the PSR-17 response factory. - New trait
HasStreamFactoryused by many middlewares that need to configure the PSR-17 stream factory.
2.0.0 - 2018-08-01
Added
- New methods added to
Factoryto return PSR-17 factories:getResponseFactory,getServerRequestFactory,getStreamFactoryandgetUriFactory. - New method
Factory::setStrategies()to configure the priority order of the Diactoros, Guzzle and Slim factories or register new classes. - Added a second argument to
Callablehandlerconstructor to pass a response factory
Changed
- Exchanged abandoned
http-interop/http-factorywithpsr/http-factory - Changed the signature of
Factory::createServerRequest()to be aligned with PSR-17 - Changed the signature of
Factory::createStream()to be aligned with PSR-17 - Changed the signature of
Factory::createResponse()to be aligned with PSR-17
1.2.0 - 2018-07-17
Changed
- Updated
http-interop/http-factoryto0.4
1.1.0 - 2018-06-25
Added
- Imported
HttpErrorExceptionfrom error handler middleware
1.0.0 - 2018-01-24
Changed
- Replaced
http-interop/http-server-middlewarewithpsr/http-server-middleware.
Removed
- Removed
Middlewares\Utils\Helpersbecause contains just one helper and it's no longer needed.
0.14.0 - 2017-12-16
Added
- New class
RequestHandlerContainerimplementing PSR-11 to resolve handlers in any format (classes, callables) and return PSR-15RequestHandlerInterfaceinstances. This can be used to resolve router handlers, for example.
Changed
- The signature of
CallableHandlerwas simplified. Removed$resolverand$argumentsin the constructor.
Removed
- Deleted all callable resolvers classes. Use the
RequestHandlerContainer, or any other PSR-11 implementation.
0.13.0 - 2017-11-16
Changed
- The minimum PHP version supported is 7.0
- Replaced
http-interop/http-middlewarewithhttp-interop/http-server-middleware. - Changed
Middlewares\Utils\CallableHandlersignature. Now it is instantiable and can be used as middleware and server request handler.
Removed
Middlewares\Utils\CallableMiddleware. UseMiddlewares\Utils\CallableHandlerinstead.
0.12.0 - 2017-09-18
Changed
- Append
.distsuffix to phpcs.xml and phpunit.xml files - Changed the configuration of phpcs and php_cs
- Upgraded phpunit to the latest version and improved its config file
- Updated
http-interop/http-middlewareto0.5
0.11.1 - 2017-05-06
Changed
Middlewares\Utils\CallableHandlerexpects one of the following values returned by the callable:- A
Psr\Http\Message\ResponseInterface nullor scalar- an object with
__toStringmethod implemented Otherwise, throws anUnexpectedValueException
- A
Middlewares\Helpers::fixContentLengthonly modifies or removes theContent-Lengthheader, but does not add it if didn't exist previously.
0.11.0 - 2017-03-25
Added
- New class
Middlewares\Utils\Helperswith common helpers to manipulate PSR-7 messages - New helper
Middlewares\Utils\Helpers::fixContentLengthused to add/modify/remove theContent-Lengthheader of a http message.
Changed
- Updated
http-interop/http-factoryto0.3
0.10.1 - 2017-02-27
Fixed
- Fixed changelog file
0.10.0 - 2017-02-27
Changed
- Replaced deprecated
container-interopbypsr/contaienr(PSR-11). Middlewares\Utils\Dispatcherthrows exceptions if the middlewares does not implementInterop\Http\ServerMiddleware\MiddlewareInterfaceor does not return an instance ofPsr\Http\Message\ResponseInterface.- Moved the default factories to
Middlewares\Utils\Factorynamespace. - Minor code improvements.
0.9.0 - 2017-02-05
Added
- Callable resolves to create callables from various representations
Removed
Middlewares\Utils\CallableHandler::resolve
0.8.0 - 2016-12-22
Changed
- Updated
http-interop/http-middlewareto0.4 - Updated
friendsofphp/php-cs-fixerto2.0
0.7.0 - 2016-12-06
Added
- New static helper
Middlewares\Utils\Dispatcher::runto create and dispatch a request easily
0.6.1 - 2016-12-06
Fixed
- Ensure that the body of the serverRequest is writable and seekable.
0.6.0 - 2016-12-06
Added
- ServerRequest factory
Middlewares\Utils\DispatcheracceptsClosureas middleware components
Changed
Middlewares\Utils\Dispatchercreates automatically a response if the stack is exhausted
0.5.0 - 2016-11-22
Added
Middlewares\Utils\CallableMiddlewareclass, to create middlewares from callablesMiddlewares\Utils\Dispatcherclass, to execute the middleware stack and return a response.
0.4.0 - 2016-11-13
Changed
- Updated
http-interop/http-factoryto0.2
0.3.1 - 2016-10-03
Fixed
- Bug in CallableHandler that resolve to the declaring class of a method instead the final class.
0.3.0 - 2016-10-03
Added
Middlewares\Utils\CallableHandlerclass, allowing to resolve and execute callables safely.
0.2.0 - 2016-10-01
Added
- Uri factory
0.1.0 - 2016-09-30
Added
- Response factory
- Stream factory