[HttpFoundation] Prepare to split out session handler callback from session storage.
[HttpFoundation] Split session handler callbacks to separate object.
[HttpFoundation] Refactor session handlers.
[HttpFoundation] Move session handler classes.
[HttpFoundation] Refactor tests.
[HttpFoundation] Add and relocate tests.
[FrameworkBundle] Add session.handler service and handler_id configuration property.

Revert service back to session.storage.native
Rename session.storage.native_file to session.handler.native_file (which is the default so no BC break from 2.0)
[DoctrineBridge] Refactor session storage to handler.
[HttpFoundation] Add tests and some CS/docblocks.
[FrameworkBundle] Make use of session API.
[HttpFoundation] Refactor away options property.

It does not make sense to try and store session ini directives since they can be changes outside
of the class as they are part of the global state.

Coding stan
[DoctrineBridge][HttpFoundation] Refactored tests.
[HttpKernel] Mock must invoke constructor.
[HttpFoundation][FrameworkBundle] Separate out mock session storage and stop polluting global namespace.

This makes mock sessions truly mock and not to interfere with global namespace.
Add getters and setters for session name and ID.
Refactor SessionStorage to NativeSessionStorage.

Native here refers to the fact the session storage interacts with real PHP sessions.
Changelog and upgrading changes.
[HttpFoundation] Add more tests.
[FrameworkBundle + WebProfilerBundle] Optimized images and icons with PunnyPNG
[HttpFoundation] Remove hard coded assumptions and replace with API calls.
merged branch stloyd/optimal-images (PR #3573)

Commits
-------

6ad201f [FrameworkBundle + WebProfilerBundle] Optimized images and icons with PunnyPNG

Discussion
----------

[FrameworkBundle + WebProfilerBundle] Optimized images and icons with PunnyPNG

It's addition to #3571, in this one I optimized also some gifs, and replaced some of gifs with png, i.e. `spinner.gif` is almost 1kb smaller.

---------------------------------------------------------------------------

by vicb at 2012-03-12T10:27:59Z

-1 for .gif -> .png (the original images might be used by some 3rd party bundles)

---------------------------------------------------------------------------

by stloyd at 2012-03-12T10:36:51Z

@vicb Do you know any ? Because I'm not =)

Mainly because of change you mentioned this PR is on `master`, so if @fabpot would like it, I can also add note to `UPGRADE-2.1` (`CHANGELOG-2.1` ?) file about this change.

---------------------------------------------------------------------------

by stof at 2012-03-12T11:49:03Z

@stloyd you should update the toolbar templates which contain the base64 encoded version of the icons too so that they use the same version

---------------------------------------------------------------------------

by Tobion at 2012-03-12T12:09:29Z

+1 for png

---------------------------------------------------------------------------

by stloyd at 2012-03-12T12:13:18Z

@stof Added. Thanks for reminding =)

If this PR will be merged, I will send PRs into related bundles (Doctrine, Monolog, SwitfMailer).

---------------------------------------------------------------------------

by fabpot at 2012-03-13T11:04:42Z

I agree with @vicb. No need to convert gifs to pngs; the benefits are not worth the change.

---------------------------------------------------------------------------

by Tobion at 2012-03-13T11:35:56Z

I disagree strongly. A sophisticated framework such as symfony should promote web best practices. PNGs are simply better for icons and image compression is an important topic because of web traffic consumption. Google does not research in JPG replacement (webp) for no reason.

---------------------------------------------------------------------------

by fabpot at 2012-03-14T11:51:31Z

It's not about promoting best practices and I agree that using png would have been better. The point is to not break BC when it is not strictly needed.

---------------------------------------------------------------------------

by Tobion at 2012-03-14T12:14:33Z

How about not replacing gif but instead putting png next to them and using png by default for profiler etc.
So anybody who used these gif images (still don't know who that should be outside the framework, and these are not part of the API) could still use them.

---------------------------------------------------------------------------

by fabpot at 2012-03-14T13:48:44Z

looks like a good compromise to me.

---------------------------------------------------------------------------

by flyboarder at 2012-03-14T16:07:58Z

+1 for side-by-side , gif's can always be removed later.

---------------------------------------------------------------------------

by stloyd at 2012-03-14T22:32:50Z

@fabpot Rebased and restored `.gif` files.