Hello,
I am trying to create a Spring rest controller in my Bloomreach project but the API is not recognised
Here is my Rest controller class . Is there a way to integrate Spring framework annotations inside Bloomreach project ? Am I missing a config change ? Do I have to match the url somewhere, or create a xml configuration ? Thank you
@RestController
public class CVentAPI {
private static final Logger LOGGER = LoggerFactory.getLogger(CVentAPI.class);
@RequestMapping("/test")
public void testMethod(){
LOGGER.info("asdasdasdasdasd");
}
}
@jasper.floor - I know you are the best here and always helped me
Hi @machak - I owe you if you can help me here I know you guys are the best on Bloomreach stuff . I remember you helped me perviously on Bloomreach support platform
I was able to integrate spring framework into hot container, and created a couple of APIs. But, the issue is that when I’m trying to create a POST request which accepts as parameter a @RequestBody object, I am getting a 415 error " Resolved [org.springframework.web.HttpMediaTypeNotSupportedException: Content type ‘application/json;charset=UTF-8’ not supported] " even though I set the consumes attribute in my post mapping
Below is a snapshot of my API call and my object
Do you know if this something Bloomreach related ? I have worked on my other Spring projects like this and never got this issue