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
Using @Resource to resolve the fileExtensionWhitelist dependency in ProcompressedArtifactFilter #1815
Using @Resource to resolve the fileExtensionWhitelist dependency in ProcompressedArtifactFilter #1815
Conversation
…rocompressedArtifactFilter. Resolves BroadleafCommerce/QA#3237
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@danielcolgrove this does not work and is unsafe to merge in. If you use @Resource
here in a filter, starting up with Spring Boot will fail since filters are registered directly with the servlet container, and the servlet container (like Tomcat) will try to inject into the @Resource
by doing a JNDI lookup. See #1771 and BroadleafCommerce/BroadleafCommercePrivate#958.
@phillipuniverse we saw the issue where the change (and reason) why it got changed to Casey was booting up with |
@danielcolgrove did a bit of research here and it seems like this is a common problem with primitive types like this. Random person on the internet from https://tamasgyorfi.net/2014/04/02/spring-injection-with-collections/ suggests to change it to this: @Value("#{blPrecompressedArtifactFileExtensionWhitelist}")
List<String> fileExtensionWhitelist; The The issue seems to be that when you Likely that we need to spot-check the other changes that I made in the referenced issues. |
@danielcolgrove @Jerry77oz 1 more thing on this, from the main man Juergen himself: https://jira.spring.io/browse/SPR-12180?focusedCommentId=107840&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-107840 |
…red bean. As stated in the PR comments, this is a suggested approach for resolving generic collection types.
Juergen has spoken! This was the only case of |
@Jerry77oz These changes worked for Casey. We should be able to merge. |
The changes Phillip suggested have been implemented
Resolves https://github.com/BroadleafCommerce/QA/issues/3237