Skip to content

[HttpFoundation] Move Session Support Away #12839

Closed
@timglabisch

Description

@timglabisch

most issues in the HttpFoundation Component are related to Sessions.

The HttpFoundation is described as:
The HttpFoundation component defines an object-oriented layer for the HTTP specification.

if you read the http specification there is nothing related to sessions, even more sessions are violating the idea of a stateless protocol.

Sessions are just a concept how to use cookies in combination with a server side key value store.
If you take a look at the HttpFoundation, now it knows a lot about our server side key value stores like the filesystem memcached, pdo, mongo, memcache. this has nothing todo with "an object-oriented layer for the HTTP specification".

i don't want to say that we should not support the concept of sessions. the idea is just to accept that sessions are not related to http.

consider the difference:

 $request->getSession()->get('foo')

vs

$sessionStorage->byRequest($request)->get('foo')

so it would be up to any kind of session storage to know about rfc6265

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions