Spring / Spring Boot

Actuator (Spring Boot)

How to set up the spring boot actuator in spring project. https://stackoverflow.com/questions/29953157/spring-boot-actuator-without-spring-boot <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-actuator</artifactId> <version>1.3.5.RELEASE</version> </dependency> <dependency> <groupId>org.springframework</groupId> <artifactId>spring-web</artifactId> <version>4.3.5.RELEASE</version> </dependency> @Configuration @EnableWebMvc @Import({ EndpointAutoConfiguration.class , PublicMetricsAutoConfiguration.class , HealthIndicatorAutoConfiguration.class }) public class MyActuatorConfig { @Bean @Autowired public EndpointHandlerMapping endpointHandlerMapping(Collection<? extends MvcEndpoint> endpoints) { return new EndpointHandlerMapping(endpoints); } @Bean @Autowired public EndpointMvcAdapter metricsEndPoint(MetricsEndpoint delegate) { … Continue reading

Spring

Spring Framework – encodingFilter

in the web.xml <!– UTF-8 Filter –> <filter> <filter-name>encodingFilter</filter-name> <filter-class>org.springframework.web.filter.CharacterEncodingFilter</filter-class> <init-param> <param-name>encoding</param-name> <param-value>UTF-8</param-value> </init-param> </filter> <filter-mapping> <filter-name>encodingFilter</filter-name> <url-pattern>/*</url-pattern> </filter-mapping> EOD Continue reading