Hi, I have a spring boot application with embed tomcat, when i deploy my application(a war package with 329 jar and 227Mb size) to servers, when i first loading a class by Class.forName, it take several seconds. I debug some tomcat source code, finally i noticed that when i load a class not loaded before, it will always run into getArchiveEntries, it will check archiveEntries is null and load from war file. And i also noticed in JarWarResourceSet gc method will periodic execution set archiveEntries=null.Caused class load slowly when archiveEntries=null, because it will scan all of my war package resources to build a cache. I'm override JarWarResourceSet let gc method do nothing, it fixed my problem. But I don’t know if I’m right, so I’m asking here. tomcat version: 8.5.39 spring boot version: 2.0.9.RELEASE
Bugzilla is not a support forum. Please direct your question to the Apache Tomcat users mailing list. http://tomcat.apache.org/lists.html