I have controller:
@RestController
public class MyController {
@GetMapping(value = "/products/{value}")
public String get(@PathVariable String value) {
System.out.println(value);
return "OK";
}
}
After start server I try to send a message like this:
http://localhost:8080/products/Mazda
and I see in console Mazda. But when I send value with a backslash:
http://localhost:8080/products/Mazda\6
I get an error:
This application has no explicit mapping for /error, so you are seeing this as a fallback.
How can I pass a value with '\' symbol as get parameter to my controller?
I expect: Mazda\6