Posts

Showing posts from January, 2021

Rabbitmq server is running but management console is not

The management plugin is not enabled by default, you need to run the below command to enable it rabbitmq-plugins enable rabbitmq_management    

Response Headers are not exposed to the client application -Spring boot,Spring microservices

Image
 I had this problem and I want to share its solution I have Angular application that send HTTP requests to the server and the sent process success but the response returns with no headers or at least the default minimum headers.  I need to read the token and some other information from the header. Solution: Response headers are not exposed by default. you must explicitly expose it in your spring boot application, in the WebSecurityConfigurerAdapter class Add this bean to your web security @Bean     public CorsFilter corsFilter() {         final UrlBasedCorsConfigurationSource source = new UrlBasedCorsConfigurationSource();         final CorsConfiguration config = new CorsConfiguration();         config.setAllowCredentials(true);                config.addAllowedOrigin("*");         config.addAllowedHeader("*");         config.addAllowedMethod("OPTIONS");         config.addAllowedMethod("HEAD");         config.addAllowedMethod("GET");