Skip to content

[VarDumper] Reduce size of serialized Data objects #23413

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 5, 2017

Conversation

nicolas-grekas
Copy link
Member

@nicolas-grekas nicolas-grekas commented Jul 5, 2017

Q A
Branch? 3.3
Bug fix? yes
New feature? no
BC breaks? no
Deprecations? no
Tests pass? no
Fixed tickets #23233
License MIT
Doc PR -

By using Stub objects a lot, especially for arrays, Data objects generate heavy serialized strings.
By implemeting Serializable on Data, this PR removes most of the boilerplate.

This PR also removes duplicate data in LoggerDataCollector, and reduces the backtrace of silenced errors to their 3 last items - which should be enough - and is otherwise responsible for a significant portion of the serialized payloads.

This is not the last possible step towards shrinking serialized profiles, but the next one is more complex -and maybe this one is good enough? Please give feedback if you can.

@fabpot
Copy link
Member

fabpot commented Jul 5, 2017

Thank you @nicolas-grekas.

@fabpot fabpot merged commit 70bd2bc into symfony:3.3 Jul 5, 2017
fabpot added a commit that referenced this pull request Jul 5, 2017
…s-grekas)

This PR was merged into the 3.3 branch.

Discussion
----------

[VarDumper] Reduce size of serialized Data objects

| Q             | A
| ------------- | ---
| Branch?       | 3.3
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | no
| Fixed tickets | #23233
| License       | MIT
| Doc PR        | -

By using `Stub` objects a lot, especially for arrays, `Data` objects generate heavy serialized strings.
By implemeting `Serializable` on `Data`, this PR removes most of the boilerplate.

This PR also removes duplicate data in `LoggerDataCollector`, and reduces the backtrace of silenced errors to their 3 last items - which should be enough - and is otherwise responsible for a significant portion of the serialized payloads.

This is not the last possible step towards shrinking serialized profiles, but the next one is more complex -and maybe this one is good enough? Please give feedback if you can.

Commits
-------

70bd2bc [VarDumper] Reduce size of serialized Data objects
@nicolas-grekas nicolas-grekas deleted the lighter-dump-ser branch July 5, 2017 13:28
@fabpot fabpot mentioned this pull request Jul 5, 2017
nicolas-grekas added a commit that referenced this pull request Jul 10, 2017
This PR was merged into the 3.2 branch.

Discussion
----------

[HttpKernel] fix DumpDataCollector tests

| Q             | A
| ------------- | ---
| Branch?       | 3.2
| Bug fix?      | yes
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets |
| License       | MIT
| Doc PR        |

to reflect the changes from #23413

Commits
-------

5dbee5b [HttpKernel] fix DumpDataCollector tests
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants