Skip to content
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

Dynamic class file deduplication across shims in dist jar build #3545

Merged
merged 7 commits into from
Sep 20, 2021

Conversation

gerashegalov
Copy link
Collaborator

@gerashegalov gerashegalov commented Sep 19, 2021

  • uses a binary diff to collect a list of class files identical for all shims in the current build (reduces the jar from 115M to 83M)
  • fixes duplicate storage of the shared resources from unshimmed-base, down to 76M

Numbers are for the biggest jar profile snapshotsWithDatabricks

Signed-off-by: Gera Shegalov gera@apache.org

- uses a binary diff to collect a list of class files identicall for all
  shims in the current build

Signed-off-by: Gera Shegalov <gera@apache.org>
Signed-off-by: Gera Shegalov <gera@apache.org>
@gerashegalov gerashegalov marked this pull request as ready for review September 20, 2021 07:27
@gerashegalov
Copy link
Collaborator Author

build

Signed-off-by: Gera Shegalov <gera@apache.org>
@gerashegalov
Copy link
Collaborator Author

build

build/buildall Show resolved Hide resolved
dist/scripts/binary-dedupe.sh Outdated Show resolved Hide resolved
Copy link
Collaborator

@revans2 revans2 left a comment

Choose a reason for hiding this comment

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

Just a small nit.

dist/scripts/binary-dedupe.sh Outdated Show resolved Hide resolved
- added brief -q output to suppress content diff
- added a unique label to protect from a match in file name
- added a regex
- class files for different classes can't be identical becuase class files
  store class names

Signed-off-by: Gera Shegalov <gera@apache.org>
@gerashegalov
Copy link
Collaborator Author

build

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.

4 participants