I am using path variable and when i hit the request i get 400 BAD Request
URL : http://localhost:8085/testing/v3/w200/http%3A%2F%2Fwww.bildarchivaustria.at%2FPreview%2F15620341.jpg
I don't know why it's not working. It might be something very simple that i am missing. Please help
Here is my code :
@RestController
@RequestMapping("/testing/v3")
public class ControllerV3
{
@GetMapping(value = "/{size}/{url}")
public ResponseEntity<byte[]> testByUrl(
@PathVariable(name="size", value="size" , required = false) String size,
@PathVariable("url") String url,
WebRequest webRequest, HttpServletResponse response) {
long startTime = 0;
if (LOG.isDebugEnabled()) {
startTime = System.nanoTime();
LOG.debug("url = {}, size = {}", url, size);
}
// i do other process here and return the image or video
}
}