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

refactor scenarios to add resource sets to tomcat in order to find faces resources #1979

Merged
merged 1 commit into from Nov 1, 2023

Conversation

persapiens
Copy link
Member

Depending on how we run Spring Boot with Tomcat (packaged jar, packaged war, unpackaged), JsfTomcatLifecycleListener adds resources to enable Tomcat to find Faces resources.

Usually, if one of the resource sets of Tomcat is DirResourceSet, nothing is done because Tomcat can find Faces resources with it. However, if this resource set contains a BOOT-INF folder, it does not contain Faces resources, and it is necessary to add classpath resource sets.

Build of joinfaces-gradle-jar-example creates an empty dir BOOT-INF/classes/META-INF/resources. Tomcat identified this folder as DirResourceSet. It was blocking JsfTomcatLifecycleListener from adding the faces resources folder META-INF/resources.

This PR is a tentative to solve #1969

…ces resources.

changing situations with DirResourceSet.
usually, if one of the resources sets is DirResourceSet, nothing is done. 
however, if this resource set contains BOOT-INF folder, it is necessary to add classpath resource sets.
@codecov
Copy link

codecov bot commented Oct 31, 2023

Codecov Report

Attention: 9 lines in your changes are missing coverage. Please review.

Comparison is base (a07771e) 0.00% compared to head (a24265f) 62.49%.
Report is 7 commits behind head on 5.2.x.

Additional details and impacted files
@@             Coverage Diff              @@
##             5.2.x    #1979       +/-   ##
============================================
+ Coverage         0   62.49%   +62.49%     
- Complexity       0       31       +31     
============================================
  Files            0      100      +100     
  Lines            0     1637     +1637     
  Branches         0      165      +165     
============================================
+ Hits             0     1023     +1023     
- Misses           0      573      +573     
- Partials         0       41       +41     
Files Coverage Δ
.../joinfaces/autoconfigure/tomcat/TomcatRuntime.java 100.00% <100.00%> (ø)
...toconfigure/tomcat/JsfTomcatLifecycleListener.java 71.76% <25.00%> (ø)

... and 98 files with indirect coverage changes

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@larsgrefer larsgrefer merged commit 467b2cf into joinfaces:5.2.x Nov 1, 2023
7 checks passed
@persapiens persapiens deleted the jar-launcher branch December 20, 2023 01:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants