-
Notifications
You must be signed in to change notification settings - Fork 41.2k
Error after upgrade to SB 1.4.2 - java.io.FileNotFoundException: JAR entry !/META-INF/services/javax.validation.spi.ValidationProvider #7360
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
Comments
Thanks for the sample project. Interestingly, the problem doesn't occur when using jar packaging and embedding Tomcat 8.5.6. |
With both Tomcat 8.5.5 and Tomcat 8.5.6 the initial URL is:
Things then diverge. With 8.5.6,
Calling With 8.5.5,
Calling @markt-asf Could you take a look at this please? It looks like a regression in Tomcat. 8.5.8 appears to have the same problem. |
I can take a look. As an aside, that initial URL looks odd. The "...!/!/.." sequence in the middle looks wrong although I don't think it is related to this issue. |
@markt-asf Thanks. I agree it looks odd. In addition to |
The * I'd expect. "*/" in a war: URL is the Tomcat equivalent of "!/" in a jar: URL. If we use !/ in WAR URLs it confuses the JRE's handling of JAR URLs. |
Aah, I see. Thanks. The URL is coming from a WebResourceRoot.getClassLoaderResources("/META-INF/services/javax.validation.spi.ValidationProvider") Its
And baseUrl + "!/" + resource.getName() |
You are ahead of me. I'm still getting my test environment set up. Thanks for that. I should be able to convert that into a unit test. |
What do you know. That extra !/ does appear to be the issue. I have a test case for jar:war:file: but I want to add some more test cases before committing this. Should have the fix committed later today. The fix will be in the next set of releases (current ETA, around 1 month from now). |
I can have snapshots available sooner (i.e. shortly after the fix is committed) if that is useful. |
Thanks, @markt-asf. A snapshot would be useful. |
Thanks for the snapshots. I can confirm that they've fixed the problem reported here. Unfortunately, they've introduced a new problem that appears to be a regression in how Connectors are handled during startup. I've opened https://bz.apache.org/bugzilla/show_bug.cgi?id=60368. |
Looks like Tomcat issue 60368 is now fixed. |
When we close this we should also check the server port issue reported in #7615 |
Unfortunately there's a nasty performance regression in Tomcat 8.5.9 which adds ~4 seconds to the shut down time on macOS when Air Drop is enabled. As I understand it, other OSes with could also be affected depending on the network configuration. The problem is particularly noticeable when using DevTools as it adds ~4 seconds to the time taken for every restart. The regression's been fixed in http://svn.apache.org/viewvc?view=revision&revision=1774098. Due to the performance degradation, we're going to have to wait for 8.5.10 to fix this issue so it's not going to make it into 1.4.3. If you're affected by this issue but won't be affected by the performance regression or think that you can live with it, overriding |
When the time comes, the necessary changes are available in this branch. |
out of curiosity, would 8.5.7 or 8.5.8 be a valid candidate? (until 8.5.10?) because we're hitting the bug where all of the jar's are being added to the static resource cache, that was fixed in 8.5.7. |
No, otherwise we would have already upgraded. We need the fix for http://bz.apache.org/bugzilla/show_bug.cgi?id=60368 which is only in 8.5.9 |
Still blocked. 8.5.11 has been released but it's yet to make it to Maven Central. |
Still missing 8.5.11. @markt-asf anything you can do to get the bits transferred? |
The upgrade has broken four Tomcat customisation tests. Reopening. |
Hi,
After upgrading from Spring Boot 1.4.1 to 1.4.2 i get an error which seems to be a strange combination of injecting a LocalValidatorFactoryBean with a @FilterRegistrationBean definition.
This error only occurs running standalone. Very odd. The error occurs on Linux / Windows and Mac.
I've managed to simplify and recreate the issue on bitbucket: https://bitbucket.org/davidmelia/spring-boot-validation-error (mvn clean install and run start.sh)
If you downgrade tomcat to 8.5.5 in the war pom.xml the problem goes away and I think it's related to the Tomcat 8.5.6 bugfix https://bz.apache.org/bugzilla/show_bug.cgi?id=60087
The error is
Thanks
The text was updated successfully, but these errors were encountered: