Skip to content

test: refactor header inclusion to speed up building (for test/extensions/filters/network/...)#12051

Merged
lizan merged 2 commits intoenvoyproxy:masterfrom
foreseeable:re_test_extensions_filters_network
Jul 14, 2020
Merged

test: refactor header inclusion to speed up building (for test/extensions/filters/network/...)#12051
lizan merged 2 commits intoenvoyproxy:masterfrom
foreseeable:re_test_extensions_filters_network

Conversation

@foreseeable
Copy link
Contributor

Signed-off-by: Muge Chen mugechen@google.com

Refactor mock class include directive after dividing test/server/mocks.h (#11649)

Since the refactoring affects ~100 files so I split it up to several pull requests (previous one #11952)

Building time comparison for affected tests: see spreadsheet at #10917 comment

Commit Message: refactor header inclusion to speed up building
Additional Description:
Risk Level: low
Testing: exsiting tests
Docs Changes: N/A
Release Notes: no
Related Issues: #10917

\cc @ahedberg @bbarenblat

Signed-off-by: Muge Chen <mugechen@google.com>
@foreseeable foreseeable changed the title test: refactor header inclusion to speed up building test: refactor header inclusion to speed up building (for test/extensions/filters/network/...) Jul 14, 2020
Signed-off-by: Muge Chen <mugechen@google.com>
@junr03 junr03 self-assigned this Jul 14, 2020
@lizan lizan merged commit c342493 into envoyproxy:master Jul 14, 2020
scheler pushed a commit to scheler/envoy that referenced this pull request Aug 4, 2020
…ions/filters/network/...) (envoyproxy#12051)

Commit Message: refactor header inclusion to speed up building
Additional Description:
Risk Level: low
Testing: exsiting tests
Docs Changes: N/A
Release Notes: no
Related Issues: envoyproxy#10917

Signed-off-by: Muge Chen <mugechen@google.com>
Signed-off-by: scheler <santosh.cheler@appdynamics.com>
htuch pushed a commit that referenced this pull request Aug 28, 2020
We need to reduce resource consumption of test compilation by simplifying mock library inclusions. #10917
One way to do that is to break the monolithic mock headers into different mock classes and then refactor the code base (like #12053 #12051 #11797)
It's hard to refactor them manually. So I wrote headersplit, a tool based on libclang and python to help me divide the monolithic mock header and replace includes after dividing automatically. This tool can also generate building time comparison between before/after refactoring.

Risk level: low
Testing: Build succeeds.

Signed-off-by: Muge Chen <mugechen@google.com>
clarakosi pushed a commit to clarakosi/envoy that referenced this pull request Sep 3, 2020
)

We need to reduce resource consumption of test compilation by simplifying mock library inclusions. envoyproxy#10917
One way to do that is to break the monolithic mock headers into different mock classes and then refactor the code base (like envoyproxy#12053 envoyproxy#12051 envoyproxy#11797)
It's hard to refactor them manually. So I wrote headersplit, a tool based on libclang and python to help me divide the monolithic mock header and replace includes after dividing automatically. This tool can also generate building time comparison between before/after refactoring.

Risk level: low
Testing: Build succeeds.

Signed-off-by: Muge Chen <mugechen@google.com>
Signed-off-by: Clara Andrew-Wani <candrewwani@gmail.com>
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.

4 participants