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

Flyway "(unsupported protocol: war)" with Tomcat 8.0.41 and unpackWARs=false #1549

Closed
thomasmey opened this issue Mar 10, 2017 · 3 comments
Closed

Comments

@thomasmey
Copy link
Contributor

Hi,

this Tomcat commit apache/tomcat80@7e767cc#diff-a72fb99b0729353084d2c437f749e718 broke Flyway in


with Tomcat config unpackWARs=false.
The returned URL is now war: instead of jar:

@thomasmey
Copy link
Contributor Author

The fix from #1512 is incomplete as the JarFileClassPathLocationScanner will get used for protocol "war" but the protocol separator is then "*/" and not "!/", so getJarFromUrl() will fail to correctly determine the file name.

This whole code fragment looks very similar to https://github.com/spring-projects/spring-framework/blob/master/spring-core/src/main/java/org/springframework/core/io/support/PathMatchingResourcePatternResolver.java#L578 which has a similar bug reported in https://jira.spring.io/browse/SPR-15332

@axelfontaine
Copy link
Contributor

Arrgghh!! OK, we'll have to adjust for this.

@axelfontaine axelfontaine added this to the Flyway 5.0.0 milestone Mar 12, 2017
axelfontaine pushed a commit to flyway/flywaydb.org that referenced this issue Apr 3, 2017
@axelfontaine
Copy link
Contributor

Thanks for the PR! Merged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants