jackson-jaxrs-providers icon indicating copy to clipboard operation
jackson-jaxrs-providers copied to clipboard

Add support for 'read at' via new annotation, JSON Pointer expression

Open cowtowncoder opened this issue 10 years ago • 0 comments

Once databind adds support for reading a sub-tree:

https://github.com/FasterXML/jackson-databind/issues/820

it would make sense to expose this from JAX-RS endpoint as well. A new annotation, something like:

@Path("/api")
public int submitAccount(@JsonAt("/request/payload/accounts/0") Account account) {
    ...
}

might make sense. It would basically allow binding only a subset of incoming document into parameter, skipping other payload efficiently (although caller will still send it).

cowtowncoder avatar Jun 18 '15 05:06 cowtowncoder