elide-spring-boot-starter problemMarch 28, 2021 at 5:52pm (Edited 4 months ago)
Build project with elide-spring-boot-starter - 5.0.0-pr32 I use elide-spring-boot-example project like example for my project. https://github.com/Goganesh/jsonApi-java-example/tree/master/education A have some problems with json api spec:
- Fields request - http://localhost:8080/json/materials?fields[materials]=name result - 400 bad request Invalid character found in the request target [/json/materials?page[size]=2&page[number]=1]. The valid characters are defined in RFC 7230 and RFC 3986
- Pagination request - request http://localhost:8080/json/materials?page[size]=2&page[number]=1 result - 400 bad request Invalid character found in the request target [/json/materials?page[size]=2&page[number]=1]. The valid characters are defined in RFC 7230 and RFC 3986
- Documentation problem request - http://localhost:8080/doc result - 
What is my problem ? Help me please
March 29, 2021 at 2:24pm
1 & 2 are probably related to using tomcat and its newer, strict, default behavior for some characters:
If you use Jetty (look at example repo pom) or configure tomcat correctly, those issues should resolve.
Even though these are reserved characters, they are commonly used in REST APIs
Square braces for example are baked into the JSON-API spec for things like sparse field:
For (3), you are setting the API version of your swagger document to "1.0"
But none of your models are versioned
I recommend removing the elide.swagger.version flag in your application.yaml
Then your unversioned models will show up in your unversioned swagger document.
I think the docs are not adequate to describe this nuance. I'm going to file an issue to improve the documentation for swagger API versions.