[jbossws-issues] [JBoss JIRA] (JBWS-2570) @SchemaValidation annotation does not work if schemaLocation property is not specified

Steve Cohen (Commented) (JIRA) jira-events at lists.jboss.org
Tue Oct 11 08:25:16 EDT 2011


    [ https://issues.jboss.org/browse/JBWS-2570?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12633804#comment-12633804 ] 

Steve Cohen commented on JBWS-2570:
-----------------------------------

Another possible workaround is here:
http://community.jboss.org/message/570377#570377
Stuff the schema under META-INF in an EJB WAR, basically.
                
> @SchemaValidation annotation does not work if schemaLocation property is not specified
> --------------------------------------------------------------------------------------
>
>                 Key: JBWS-2570
>                 URL: https://issues.jboss.org/browse/JBWS-2570
>             Project: JBoss Web Services
>          Issue Type: Bug
>      Security Level: Public(Everyone can see) 
>          Components: jbossws-native
>         Environment: jboss 4.2.3.GA
> jbossws-native-3.0.5.GA
>            Reporter: Nick Gudushauri
>             Fix For: community contributions
>
>         Attachments: DataTypes.xsd, MessageTypes.xsd, SampleService.wsdl
>
>
> Steps to reproduce:
> 1. Create simpe JAX-WS service
> 2. Annotate it with  @SchemaValidation annotation WITHOUT specifying optional schemaLocation property (In such case schema should be extracted from the WSDL)
> 3. Send test request
> As the result no schema validation is performed and you will see the following messages in log:
> 17:07:13,421 INFO [SOAPBodyElementDoc] Validating: DOM_VALID
> 17:07:13,421 WARN [SchemaExtractor] Cannot find element: {http://schemas.xmlsoap.org/wsdl/}types
> 17:07:13,625 INFO [UCCServicesBean] Invoking UCC registerClearingOrder service by cer
> 17:07:14,515 INFO [SOAPBodyElementDoc] Validating: DOM_VALID
> 17:07:14,515 WARN [SchemaExtractor] Cannot find element: {http://schemas.xmlsoap.org/wsdl/}types
> The problem root is that org.jboss.ws.extensions.validation.SchemaExtractor class could not load 'types' element from WSDL as this element does not present in WSDL directly but imported via 'import' element.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        


More information about the jbossws-issues mailing list