You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cxf.apache.org by "Jason Pell (JIRA)" <ji...@apache.org> on 2014/12/01 00:45:12 UTC

[jira] [Comment Edited] (CXF-6118) Schema Validation refinements

    [ https://issues.apache.org/jira/browse/CXF-6118?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14229282#comment-14229282 ] 

Jason Pell edited comment on CXF-6118 at 11/30/14 11:44 PM:
------------------------------------------------------------

I changed the title of the jira, so when it appears in the release notes its not misleading, as the IN / OUT mappings are actually correct.

Added new SchemaValidation REQUEST and RESPONSE types which will map correctly to IN / OUT depending on whether its on client side or server side.

IN and OUT annotation will continue to be applied to incoming messages on both server and client without mapping.

Please refer to the following mail thread for details as to why changing the meaning of IN and OUT on the client is not the correct approach.

http://cxf.547215.n5.nabble.com/Re-cxf-git-commit-CXF-6118-support-overriding-schema-validation-at-jaxws-endpoint-and-client-level-al-tt5751632.htm


was (Author: jpell):
Added new SchemaValidation REQUEST and RESPONSE types which will map correctly to IN / OUT depending on whether its on client side or server side.

IN and OUT annotation will continue to be applied to incoming messages on both server and client without mapping.

Please refer to the following mail thread for details as to why changing the meaning of IN and OUT on the client is not the correct approach.

http://cxf.547215.n5.nabble.com/Re-cxf-git-commit-CXF-6118-support-overriding-schema-validation-at-jaxws-endpoint-and-client-level-al-tt5751632.htm

> Schema Validation refinements
> -----------------------------
>
>                 Key: CXF-6118
>                 URL: https://issues.apache.org/jira/browse/CXF-6118
>             Project: CXF
>          Issue Type: Bug
>          Components: JAX-WS Runtime
>    Affects Versions: 2.7.8, 2.7.13, 3.0.2
>         Environment: Java 1.7.0_51,
> Spring Framework 3.2.0,
> Windows 7
>            Reporter: Thomas Whitmore
>            Assignee: Jason Pell
>            Priority: Minor
>              Labels: client, operation, schema, validation
>             Fix For: 2.7.14
>
>         Attachments: problem example.zip
>
>
> Disabling input schema-validation for my <jaxws:client> was unsuccessful following the docs. Neither 'false' nor 'NONE' were effective and the client (an integration test) was still validating & throwing exceptions.
> Debugging the CXF code, I found Message.SCHEMA_VALIDATION_ENABLED being set to 'IN' by code in AbstractInDatabindingInterceptor.setOperationSchemaValidation(). This setting of 'IN' appears to be coming from the Service/ Endpoint definitions!
> I had defined the service (LoanApplicationWS) as validating IN (by means of annotations). When I changed the service validation to NONE, client was no longer forced to validate.
> There are two issues here:
> 1) Service/Endpoint validation settings, should not automatically be overriding Client settings 
> 2) Service OUT validation corresponds to Client IN validation;  the directions are inverted.
> The background here, is to extend a service & schema designed for "complete" Loan Applications to be able to retrieve "draft" applications -- which are only partly-formed, and thus do not include some elements required in the schema.
> For this reason, I intend to disable output validation of the Service; and correspondingly disable input validation at the Client.
> However, CXF is somehow finding validation settings Service/Endpoint and applying them (in an incorrect directional sense) to the Client.
> I've included screenshots of the Client 1) broken and 2) working, according to changes to the Service validation setting.
> Please find a partial project attached containing a few relevant files & the screenshots.
> Thanks,
> Regards
> Thomas



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)