cxf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sergey Beryozkin (JIRA)" <>
Subject [jira] [Commented] (CXF-5309) Support Bean Validation API for JAX-RS
Date Tue, 08 Oct 2013 13:26:42 GMT


Sergey Beryozkin commented on CXF-5309:

Hi, try a custom invoker:

This is where you will get all the type info, and do the validation. Custom invokers can be
used with and without Spring, and we will need a non-Spring validation support as well, so
it will work for all users. Similar idea will also work for JAX-WS.

Or may be you can implement the validation in the input CXF interceptor, PRE-INVOKE phase,
all the invocation parameters are already available there, 

List<Object> methodParams = MessageContentsList getContentsList(m); 

JAX-RS target method is available as "org.apache.cxf.resource.method" property. JAX-RS OperationResourceInfo
class (with the access to all of JAX-RS specific info for the current method and its class
owner) is available from "message.getExchange().get(OperationResourceInfo.class)". Using a
CXF interceptor may make it simpler to reuse some of the code with the JAX-WS runtime at the
next stage


> Support Bean Validation API for JAX-RS
> --------------------------------------
>                 Key: CXF-5309
>                 URL:
>             Project: CXF
>          Issue Type: Sub-task
>          Components: JAX-RS, JAX-WS Runtime
>            Reporter: Sergey Beryozkin

This message was sent by Atlassian JIRA

View raw message