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

ASF GitHub Bot commented on CXF-7758:
-------------------------------------

TomasHofman opened a new pull request #423: CXF-7758 MTOM + SchemaValidation 
results in empty input stream from d…
URL: https://github.com/apache/cxf/pull/423
 
 
   …ata handler
   
   https://issues.apache.org/jira/browse/CXF-7758
   https://issues.jboss.org/browse/JBEAP-14830
   
   This is to allow checking `endpoint.getEndpointInfo()` even when 
`exchange.getBindingOperationInfo()` is not yet set.
   
   The `JAXBAttachmentSchemaValidationHack` is checking if the the validation 
is enabled in a phase before `exchange.getBindingOperationInfo()` is set. This 
leads to not correctly determining that validation is enabled and attachment 
datasources not being cached. Because the datasource is not cached, it returns 
the same InputStream to the validation unmarshaller and then to the 
application, resulting in the app not being able to read any data from the 
attachment DS.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


> MTOM + SchemaValidation results in empty input stream from data handler
> -----------------------------------------------------------------------
>
>                 Key: CXF-7758
>                 URL: https://issues.apache.org/jira/browse/CXF-7758
>             Project: CXF
>          Issue Type: Bug
>          Components: Core
>    Affects Versions: 3.2.4
>            Reporter: Tomas Hofman
>            Priority: Major
>         Attachments: sample_jboss_bug_apache_cxf.zip
>
>
> With enabled validation, data handler returns empty input stream for 
> attachment data.
> Reproducer:
> 1. Unzip the attachment
>  2. Build using "mvn clean install" and deploy war file to JBoss EAP 7.1.2.
>  3. Try calling the deployed soap service with attachments as given in the 
> sample soap UI project.
>  4. Notice the resulting file is empty. This happens only when schema 
> validation enabled. After removing SchemaValidation annotation it works fine.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to