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

Improve performance of fat jar loading #1119

Closed
philwebb opened this issue Jun 17, 2014 · 3 comments
Closed

Improve performance of fat jar loading #1119

philwebb opened this issue Jun 17, 2014 · 3 comments
Labels
type: enhancement A general enhancement
Milestone

Comments

@philwebb
Copy link
Member

Whilst investigating #1117 I discovered that we have some quite inefficient code for fat jar loading.

@philwebb philwebb added this to the 1.1.2 milestone Jun 17, 2014
@dsyer dsyer removed the backlog label Jun 20, 2014
@dsyer
Copy link
Member

dsyer commented Jun 20, 2014

Would this make #1106 and #1122 redundant?

@philwebb
Copy link
Member Author

@dsyer No, I'm adding caching when JARs are scanned but if the underlying file changes you're still boned.

@philwebb philwebb changed the title Add Jar Caching Improve performance of fat jar loading Jun 20, 2014
philwebb pushed a commit that referenced this issue Jun 20, 2014
Drop JarEntryFilter arguments from the JarFile constructor and the
getNestedJarFile methods. Filtered JarFiles can still be obtained by
using the getFilteredJarFile() method.

This helps simplify the code a little and will make it easier to add
caching.

See gh-1119
philwebb pushed a commit that referenced this issue Jun 20, 2014
Update JarFile to reuse the previously parsed entries when creating
filtered jars. This saves needing to re-scan the underlying file to
recreate a subset of entries.

See gh-1119
philwebb pushed a commit that referenced this issue Jun 20, 2014
Cache root jar files in the Handler and also store nested jar files in
the JarEntryData.

See gh-1119
philwebb pushed a commit that referenced this issue Jun 20, 2014
Improve fat JAR performance.

See gh-1119
@philwebb
Copy link
Member Author

Before/After timings for the Tomcat Sample:

Started SampleTomcatApplication in 3.566 seconds (JVM running for 4.057)
Started SampleTomcatApplication in 2.66 seconds (JVM running for 3.07)

Before/After timings for Sagan

Started SiteMain in 29.093 seconds (JVM running for 30.44)
Started SiteMain in 15.979 seconds (JVM running for 16.908)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: enhancement A general enhancement
Projects
None yet
Development

No branches or pull requests

2 participants