Skip to content

[WCM] Document PhpSessionStorage #2474

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 6 commits into from Apr 27, 2013
Merged

[WCM] Document PhpSessionStorage #2474

merged 6 commits into from Apr 27, 2013

Conversation

ghost
Copy link

@ghost ghost commented Apr 6, 2013

Q A
Doc fix? yes
New docs? yes (symfony/symfony#7571)
Applies to all (or 2.3+)
Fixed tickets na

@stof
Copy link
Member

stof commented Apr 6, 2013

You should add a note about the fact that the Symfony Session attributes are stored in a single key of $_SESSION. The Symfony code will not see all legacy session variables.

where you do not initially have the level of control you require.

As stated elsewhere, Symfony Sessions are designed to replace the use of
PHP's native `session_*()` functions and use of the `$_SESSION`
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You need to use double-` for code sections

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed.

@ghost
Copy link
Author

ghost commented Apr 6, 2013

@stof - done.

single: HTTP
single: HttpFoundation, Sessions

Integrating with legacy sessions
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Integrating with Legacy Sessions

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed.

@stanlemon
Copy link

You might consider adding a reference to how someone might use this storage bridge in the full stack framework. That will likely be a very common use case.

Very excited about this PR! I'm hoping it'll get merged in before I start my next project.

@ghost
Copy link
Author

ghost commented Apr 13, 2013

OK, Added.

@stanlemon
Copy link

👍

fabpot added a commit to symfony/symfony that referenced this pull request Apr 18, 2013
This PR was squashed before being merged into the master branch (closes #7571).

Discussion
----------

[2.3] Handle PHP sessions started outside of Symfony

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        | symfony/symfony-docs#2474

This PR brings a way to allow Symfony2 to manage a session started outside of Symfony in such a way that quite explicit. It also introduces more robust detection of previously started sessions under PHP 5.3 and supports real session status detection under PHP 5.4

Commits
-------

df99902 [2.3] Handle PHP sessions started outside of Symfony
fabpot added a commit to symfony/framework-bundle that referenced this pull request Apr 18, 2013
This PR was squashed before being merged into the master branch (closes #7571).

Discussion
----------

[2.3] Handle PHP sessions started outside of Symfony

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        | symfony/symfony-docs#2474

This PR brings a way to allow Symfony2 to manage a session started outside of Symfony in such a way that quite explicit. It also introduces more robust detection of previously started sessions under PHP 5.3 and supports real session status detection under PHP 5.4

Commits
-------

df99902 [2.3] Handle PHP sessions started outside of Symfony
fabpot added a commit to symfony/http-foundation that referenced this pull request Apr 18, 2013
This PR was squashed before being merged into the master branch (closes #7571).

Discussion
----------

[2.3] Handle PHP sessions started outside of Symfony

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        | symfony/symfony-docs#2474

This PR brings a way to allow Symfony2 to manage a session started outside of Symfony in such a way that quite explicit. It also introduces more robust detection of previously started sessions under PHP 5.3 and supports real session status detection under PHP 5.4

Commits
-------

df99902 [2.3] Handle PHP sessions started outside of Symfony
@ghost
Copy link
Author

ghost commented Apr 18, 2013

This can be merged now.

@stanlemon
Copy link

Something else that might be worth adding is a note about unsetting the custom path for session save paths. Personally, I like that Symfony does this - but because this change is designed specifically for legacy applications migrating over it makes sense to demonstrate how save path's can be cleared out since the legacy app most likely uses a different directly (probably php default).

Something as simple as...
session:
save_path: ~

with a brief explanation perhaps?

If you see value in this and want I can try to write something up.

@ghost
Copy link
Author

ghost commented Apr 18, 2013

Sure, if it's set that is.... maybe you can make a PR after this is merged?

@stanlemon
Copy link

Sure thing, I will do that. Thanks!

@ghost
Copy link
Author

ghost commented Apr 20, 2013

@weaverryan - this should be merged now, the feature was merged into Symfony.

@ghost
Copy link
Author

ghost commented Apr 26, 2013

ping @weaverryan - is there a problem merging this?

@weaverryan
Copy link
Member

Hey Drak!

Sorry for the delay - I'll get to this soon. I'm working from the oldest PR's to process all the WCM PR's for code that got recently merged.

Thanks!

weaverryan added a commit that referenced this pull request Apr 27, 2013
[WCM] Document PhpSessionStorage
@weaverryan weaverryan merged commit c1142dc into symfony:master Apr 27, 2013
weaverryan added a commit that referenced this pull request Apr 27, 2013
@weaverryan
Copy link
Member

Hey Drak!

Merged! Only minor changes at sha: 73e5095

Thanks!

fabpot added a commit to symfony/framework-bundle that referenced this pull request Nov 11, 2014
This PR was squashed before being merged into the master branch (closes #7571).

Discussion
----------

[2.3] Handle PHP sessions started outside of Symfony

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        | symfony/symfony-docs#2474

This PR brings a way to allow Symfony2 to manage a session started outside of Symfony in such a way that quite explicit. It also introduces more robust detection of previously started sessions under PHP 5.3 and supports real session status detection under PHP 5.4

Commits
-------

df99902 [2.3] Handle PHP sessions started outside of Symfony
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants