Skip to content

Commit

Permalink
#310: fixed warnings with generic types
Browse files Browse the repository at this point in the history
  • Loading branch information
hohwille committed Jan 12, 2021
1 parent 1ca34be commit 0ac5c96
Showing 1 changed file with 8 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,10 @@ public class WebConfig {
* with their duration and status code.
*/
@Bean
public FilterRegistrationBean performanceLogFilter() {
public FilterRegistrationBean<PerformanceLogFilter> performanceLogFilter() {

FilterRegistrationBean registration = new FilterRegistrationBean();
Filter performanceLogFilter = new PerformanceLogFilter();
FilterRegistrationBean<PerformanceLogFilter> registration = new FilterRegistrationBean<>();
PerformanceLogFilter performanceLogFilter = new PerformanceLogFilter();
this.beanFactory.autowireBean(performanceLogFilter);
registration.setFilter(performanceLogFilter);
registration.addUrlPatterns("/*");
Expand All @@ -52,10 +52,10 @@ public DiagnosticContextFacade diagnosticContextFacade() {
* correlation id as MDC so it will be included in all associated logs.
*/
@Bean
public FilterRegistrationBean diagnosticContextFilter() {
public FilterRegistrationBean<DiagnosticContextFilter> diagnosticContextFilter() {

FilterRegistrationBean registration = new FilterRegistrationBean();
Filter diagnosticContextFilter = new DiagnosticContextFilter();
FilterRegistrationBean<DiagnosticContextFilter> registration = new FilterRegistrationBean<>();
DiagnosticContextFilter diagnosticContextFilter = new DiagnosticContextFilter();
this.beanFactory.autowireBean(diagnosticContextFilter);
registration.setFilter(diagnosticContextFilter);
registration.addUrlPatterns(ServiceConstants.URL_PATH_SERVICES + "/*");
Expand All @@ -66,9 +66,9 @@ public FilterRegistrationBean diagnosticContextFilter() {
* @return the {@link FilterRegistrationBean} to register the {@link CharacterEncodingFilter} to set the encoding.
*/
@Bean
public FilterRegistrationBean setCharacterEncodingFilter() {
public FilterRegistrationBean<CharacterEncodingFilter> setCharacterEncodingFilter() {

FilterRegistrationBean registration = new FilterRegistrationBean();
FilterRegistrationBean<CharacterEncodingFilter> registration = new FilterRegistrationBean<>();
CharacterEncodingFilter characterEncodingFilter = new CharacterEncodingFilter();
characterEncodingFilter.setEncoding("UTF-8");
characterEncodingFilter.setForceEncoding(false);
Expand Down

0 comments on commit 0ac5c96

Please sign in to comment.