@Test public void validationEnabledInvalidInput() throws Exception { SchemaFactory schemaFactory = SchemaFactory.newInstance(XMLConstants.W3C_XML_SCHEMA_NS_URI); schemaFactory.newSchema(new StreamSource(getClass().getClassLoader().getResourceAsStream("xsd/foo.xsd"))); when(request.getInputStream()).thenReturn( new TestServletInputStream(buildSoapMessage(null, firstOpInDuplicate, null, null))); when(request.getScheme()).thenReturn("http"); soapCommandProcessor.setSchemaValidationEnabled(true); soapCommandProcessor.process(command); assertEquals(CommandStatus.Complete, command.getStatus()); assertSoapyEquals(buildSoapMessage(null, null, invalidInputFault, null), testOut.getOutput()); verify(response).setContentType(MediaType.TEXT_XML); verify(response).setStatus(HttpServletResponse.SC_INTERNAL_SERVER_ERROR); verify(logger).logAccess(eq(command), any(ExecutionContext.class), anyLong(), anyLong(), any(MediaType.class), any(MediaType.class), any(ResponseCode.class)); }
@ManagedAttribute public void setSchemaValidationEnabled(boolean schemaValidationEnabled) { this.schemaValidationEnabled = schemaValidationEnabled; }
SoapTransportCommandProcessor extends AbstractTerminateableHttpCommandProcessor<OMElement> { @ManagedAttribute public void setSchemaValidationEnabled(boolean schemaValidationEnabled) { this.schemaValidationEnabled = schemaValidationEnabled; } }
SoapTransportCommandProcessor extends AbstractTerminateableHttpCommandProcessor<OMElement> { @ManagedAttribute public void setSchemaValidationEnabled(boolean schemaValidationEnabled) { this.schemaValidationEnabled = schemaValidationEnabled; } SoapTransportCommandProcessor(DehydratedExecutionContextResolution contextResolution, String requestTimeoutHeader, SchemaValidationFailureParser schemaValidationFailureParser); }
SoapTransportCommandProcessor extends AbstractTerminateableHttpCommandProcessor<OMElement> { @ManagedAttribute public void setSchemaValidationEnabled(boolean schemaValidationEnabled) { this.schemaValidationEnabled = schemaValidationEnabled; } SoapTransportCommandProcessor(DehydratedExecutionContextResolution contextResolution, String requestTimeoutHeader, SchemaValidationFailureParser schemaValidationFailureParser); @ManagedAttribute boolean isSchemaValidationEnabled(); @ManagedAttribute void setSchemaValidationEnabled(boolean schemaValidationEnabled); @Override void onCougarStart(); }
SoapTransportCommandProcessor extends AbstractTerminateableHttpCommandProcessor<OMElement> { @ManagedAttribute public void setSchemaValidationEnabled(boolean schemaValidationEnabled) { this.schemaValidationEnabled = schemaValidationEnabled; } SoapTransportCommandProcessor(DehydratedExecutionContextResolution contextResolution, String requestTimeoutHeader, SchemaValidationFailureParser schemaValidationFailureParser); @ManagedAttribute boolean isSchemaValidationEnabled(); @ManagedAttribute void setSchemaValidationEnabled(boolean schemaValidationEnabled); @Override void onCougarStart();  }