Commit 77d1241
Simon Democko
Add fallback to Thread Context Class Loader for resource loading
This commit adds a fallback to `Thread.currentThread().getContextClassLoader().getResourceAsStream(file)` in the `ClasspathHelper` class.
Previously, if the `ClasspathHelper.class.getResourceAsStream(file)` and `ClassLoader.getSystemResourceAsStream(file)` methods returned `null`, no further attempts were made to load the resource, which caused issues in Quarkus applications in dev mode.
This commit adds an additional fallback to `Thread.currentThread().getContextClassLoader().getResourceAsStream(file)` to improve compatibility with the Quarkus class loading model.
Related Issue: #19681 parent 08a7630 commit 77d1241
File tree
1 file changed
+5
-1
lines changed- modules/swagger-parser-v3/src/main/java/io/swagger/v3/parser/util
1 file changed
+5
-1
lines changedLines changed: 5 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
16 | | - | |
| 16 | + | |
17 | 17 | | |
18 | 18 | | |
19 | 19 | | |
| |||
22 | 22 | | |
23 | 23 | | |
24 | 24 | | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
25 | 29 | | |
26 | 30 | | |
27 | 31 | | |
| |||
0 commit comments