Skip to content

[HttpFoundation] Drop support for ApacheRequest #32255

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jul 3, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 9 additions & 4 deletions UPGRADE-4.4.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ DependencyInjection
services:
App\Handler:
tags: ['app.handler']

App\HandlerCollection:
arguments: [!tagged app.handler]
```
Expand All @@ -36,7 +36,7 @@ DependencyInjection
services:
App\Handler:
tags: ['app.handler']

App\HandlerCollection:
arguments: [!tagged_iterator app.handler]
```
Expand All @@ -60,6 +60,11 @@ HttpClient

* Added method `cancel()` to `ResponseInterface`

HttpFoundation
--------------

* `ApacheRequest` is deprecated, use `Request` class instead.

HttpKernel
----------

Expand All @@ -84,11 +89,11 @@ Security
TwigBridge
----------

* Deprecated to pass `$rootDir` and `$fileLinkFormatter` as 5th and 6th argument respectively to the
* Deprecated to pass `$rootDir` and `$fileLinkFormatter` as 5th and 6th argument respectively to the
`DebugCommand::__construct()` method, swap the variables position.

Validator
---------

* Deprecated passing an `ExpressionLanguage` instance as the second argument of `ExpressionValidator::__construct()`.
* Deprecated passing an `ExpressionLanguage` instance as the second argument of `ExpressionValidator::__construct()`.
Pass it as the first argument instead.
5 changes: 2 additions & 3 deletions UPGRADE-5.0.md
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ DependencyInjection
services:
App\Handler:
tags: ['app.handler']

App\HandlerCollection:
arguments: [!tagged_iterator app.handler]
```
Expand All @@ -114,7 +114,6 @@ DoctrineBridge
* Passing an `IdReader` to the `DoctrineChoiceLoader` when the query cannot be optimized with single id field will throw an exception, pass `null` instead
* Not passing an `IdReader` to the `DoctrineChoiceLoader` when the query can be optimized with single id field will not apply any optimization


DomCrawler
----------

Expand Down Expand Up @@ -268,6 +267,7 @@ HttpFoundation
use `Symfony\Component\Mime\FileBinaryMimeTypeGuesser` instead.
* The `FileinfoMimeTypeGuesser` class has been removed,
use `Symfony\Component\Mime\FileinfoMimeTypeGuesser` instead.
* `ApacheRequest` has been removed, use the `Request` class instead.

HttpKernel
----------
Expand Down Expand Up @@ -518,7 +518,6 @@ Workflow
property: state
```


* Support for using a workflow with a single state marking is dropped. Use a state machine instead.

Before:
Expand Down
4 changes: 4 additions & 0 deletions src/Symfony/Component/HttpFoundation/ApacheRequest.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,13 @@

namespace Symfony\Component\HttpFoundation;

@trigger_error(sprintf('The "%s" class is deprecated since Symfony 4.4, use "%s" instead.', ApacheRequest::class, Request::class), E_USER_DEPRECATED);

/**
* Request represents an HTTP request from an Apache server.
*
* @deprecated since Symfony 4.4. Use the Request class instead.
*
* @author Fabien Potencier <fabien@symfony.com>
*/
class ApacheRequest extends Request
Expand Down
1 change: 1 addition & 0 deletions src/Symfony/Component/HttpFoundation/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ CHANGELOG
-----

* passing arguments to `Request::isMethodSafe()` is deprecated.
* `ApacheRequest` is deprecated, use the `Request` class instead.

4.3.0
-----
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
use PHPUnit\Framework\TestCase;
use Symfony\Component\HttpFoundation\ApacheRequest;

/** @group legacy */
class ApacheRequestTest extends TestCase
{
/**
Expand Down