You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@servicemix.apache.org by "Grant McDonald (JIRA)" <ji...@apache.org> on 2006/11/13 12:30:02 UTC
[jira] Commented: (SM-728) Validation component / CopyTransformer /
SourceTransformer put a non serializable property in the message
[ https://issues.apache.org/activemq/browse/SM-728?page=comments#action_37436 ]
Grant McDonald commented on SM-728:
-----------------------------------
I think this is due to the erroneous use of the sourceTransformer directly in the transform method in ValidateComponent:
try {
SourceTransformer sourceTransformer = new SourceTransformer(); // this may be a problem
// Only DOMSource and SAXSource are allowed for validating
// See http://java.sun.com/j2se/1.5.0/docs/api/javax/xml/validation/Validator.html#validate(javax.xml.transform.Source,%20javax.xml.transform.Result)
// As we expect a DOMResult as output, we must ensure that the input is a
// DOMSource
DOMSource src = sourceTransformer.toDOMSource(out.getContent());
doValidation(validator,src,result);
if (errorHandler.hasErrors()) {
Fault fault = exchange.createFault();
// set the schema and source document as properties on the fault
fault.setProperty("org.apache.servicemix.schema", schema); // remove these prop sets
fault.setProperty("org.apache.servicemix.xml", src); // remove these prop sets
What occurs here is that the property is set on the Fault message which would explain why changing the CopyTransformer did not work. If no-one has any objections I would like to remove both of these properties as I wouldn't think they ultimately prove very useful.
> Validation component / CopyTransformer / SourceTransformer put a non serializable property in the message
> ---------------------------------------------------------------------------------------------------------
>
> Key: SM-728
> URL: https://issues.apache.org/activemq/browse/SM-728
> Project: ServiceMix
> Issue Type: Bug
> Components: servicemix-core
> Affects Versions: 3.0
> Environment: Windows XP Professional
> Reporter: Eyji
>
> See discussion with Guilaume Nodet on Nabble for ServiceMix User:
> http://www.nabble.com/forum/ViewPost.jtp?post=7093895&framed=y
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/activemq/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira