You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@activemq.apache.org by "Marcel Casado (JIRA)" <ji...@apache.org> on 2011/07/03 09:08:21 UTC
[jira] [Created] (AMQ-3388) Http/https protocol uses Xstream for
serializing commands in xml. Field additions to the commands bresks xtream
serializacion between amq versions
Http/https protocol uses Xstream for serializing commands in xml. Field additions to the commands bresks xtream serializacion between amq versions
---------------------------------------------------------------------------------------------------------------------------------------------------
Key: AMQ-3388
URL: https://issues.apache.org/jira/browse/AMQ-3388
Project: ActiveMQ
Issue Type: Improvement
Components: Transport
Affects Versions: 5.5.0, 5.4.2, 5.4.1
Reporter: Marcel Casado
Addition of fields in commands used between clients and brokers in newer amq versions breaks easily the http transport that uses xstream for xml serialization.
The make xstream more tolerant to this changes between version in org.apache.activemq.transport.xstream.XStreamWireFormat we could add the code below so xstream ignores unknown fields :
// Implementation methods
// -------------------------------------------------------------------------
protected XStream createXStream() {
// return new XStream();
return new XStream() {
protected MapperWrapper wrapMapper(MapperWrapper next) {
return new MapperWrapper(next) {
public boolean shouldSerializeMember(Class definedIn, String fieldName) {
return definedIn != Object.class ? super.shouldSerializeMember(definedIn, fieldName) : false;
}
};
}
};
}
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Updated] (AMQ-3388) Http/https protocol uses Xstream for
serializing commands in xml. Field additions to the commands bresks xtream
serializacion between amq versions
Posted by "Marcel Casado (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/AMQ-3388?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Marcel Casado updated AMQ-3388:
-------------------------------
Patch Info: [Patch Available]
> Http/https protocol uses Xstream for serializing commands in xml. Field additions to the commands bresks xtream serializacion between amq versions
> ---------------------------------------------------------------------------------------------------------------------------------------------------
>
> Key: AMQ-3388
> URL: https://issues.apache.org/jira/browse/AMQ-3388
> Project: ActiveMQ
> Issue Type: Improvement
> Components: Transport
> Affects Versions: 5.4.1, 5.4.2, 5.5.0
> Reporter: Marcel Casado
>
> Addition of fields in commands used between clients and brokers in newer amq versions breaks easily the http transport that uses xstream for xml serialization.
> To make xstream more tolerant to this changes between versions in org.apache.activemq.transport.xstream.XStreamWireFormat we could add the code below so xstream ignores unknown fields :
> // Implementation methods
> // -------------------------------------------------------------------------
> protected XStream createXStream() {
> // return new XStream();
> return new XStream() {
> protected MapperWrapper wrapMapper(MapperWrapper next) {
> return new MapperWrapper(next) {
> public boolean shouldSerializeMember(Class definedIn, String fieldName) {
> return definedIn != Object.class ? super.shouldSerializeMember(definedIn, fieldName) : false;
> }
> };
> }
> };
> }
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Updated] (AMQ-3388) Http/https protocol uses Xstream for
serializing commands in xml. Field additions to the commands bresks xtream
serializacion between amq versions
Posted by "Marcel Casado (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/AMQ-3388?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Marcel Casado updated AMQ-3388:
-------------------------------
Description:
Addition of fields in commands used between clients and brokers in newer amq versions breaks easily the http transport that uses xstream for xml serialization.
To make xstream more tolerant to this changes between versions in org.apache.activemq.transport.xstream.XStreamWireFormat we could add the code below so xstream ignores unknown fields :
// Implementation methods
// -------------------------------------------------------------------------
protected XStream createXStream() {
// return new XStream();
return new XStream() {
protected MapperWrapper wrapMapper(MapperWrapper next) {
return new MapperWrapper(next) {
public boolean shouldSerializeMember(Class definedIn, String fieldName) {
return definedIn != Object.class ? super.shouldSerializeMember(definedIn, fieldName) : false;
}
};
}
};
}
was:
Addition of fields in commands used between clients and brokers in newer amq versions breaks easily the http transport that uses xstream for xml serialization.
The make xstream more tolerant to this changes between version in org.apache.activemq.transport.xstream.XStreamWireFormat we could add the code below so xstream ignores unknown fields :
// Implementation methods
// -------------------------------------------------------------------------
protected XStream createXStream() {
// return new XStream();
return new XStream() {
protected MapperWrapper wrapMapper(MapperWrapper next) {
return new MapperWrapper(next) {
public boolean shouldSerializeMember(Class definedIn, String fieldName) {
return definedIn != Object.class ? super.shouldSerializeMember(definedIn, fieldName) : false;
}
};
}
};
}
> Http/https protocol uses Xstream for serializing commands in xml. Field additions to the commands bresks xtream serializacion between amq versions
> ---------------------------------------------------------------------------------------------------------------------------------------------------
>
> Key: AMQ-3388
> URL: https://issues.apache.org/jira/browse/AMQ-3388
> Project: ActiveMQ
> Issue Type: Improvement
> Components: Transport
> Affects Versions: 5.4.1, 5.4.2, 5.5.0
> Reporter: Marcel Casado
>
> Addition of fields in commands used between clients and brokers in newer amq versions breaks easily the http transport that uses xstream for xml serialization.
> To make xstream more tolerant to this changes between versions in org.apache.activemq.transport.xstream.XStreamWireFormat we could add the code below so xstream ignores unknown fields :
> // Implementation methods
> // -------------------------------------------------------------------------
> protected XStream createXStream() {
> // return new XStream();
> return new XStream() {
> protected MapperWrapper wrapMapper(MapperWrapper next) {
> return new MapperWrapper(next) {
> public boolean shouldSerializeMember(Class definedIn, String fieldName) {
> return definedIn != Object.class ? super.shouldSerializeMember(definedIn, fieldName) : false;
> }
> };
> }
> };
> }
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (AMQ-3388) Http/https protocol uses Xstream for
serializing commands in xml. Field additions to the commands bresks xtream
serializacion between amq versions
Posted by "Timothy Bish (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/AMQ-3388?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13059210#comment-13059210 ]
Timothy Bish commented on AMQ-3388:
-----------------------------------
How about working up a patch file and attaching with grants to apache?
> Http/https protocol uses Xstream for serializing commands in xml. Field additions to the commands bresks xtream serializacion between amq versions
> ---------------------------------------------------------------------------------------------------------------------------------------------------
>
> Key: AMQ-3388
> URL: https://issues.apache.org/jira/browse/AMQ-3388
> Project: ActiveMQ
> Issue Type: Improvement
> Components: Transport
> Affects Versions: 5.4.1, 5.4.2, 5.5.0
> Reporter: Marcel Casado
>
> Addition of fields in commands used between clients and brokers in newer amq versions breaks easily the http transport that uses xstream for xml serialization.
> To make xstream more tolerant to this changes between versions in org.apache.activemq.transport.xstream.XStreamWireFormat we could add the code below so xstream ignores unknown fields :
> // Implementation methods
> // -------------------------------------------------------------------------
> protected XStream createXStream() {
> // return new XStream();
> return new XStream() {
> protected MapperWrapper wrapMapper(MapperWrapper next) {
> return new MapperWrapper(next) {
> public boolean shouldSerializeMember(Class definedIn, String fieldName) {
> return definedIn != Object.class ? super.shouldSerializeMember(definedIn, fieldName) : false;
> }
> };
> }
> };
> }
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Issue Comment Edited] (AMQ-3388) Http/https protocol uses
Xstream for serializing commands in xml. Field additions to the commands
bresks xtream serializacion between amq versions
Posted by "Marcel Casado (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/AMQ-3388?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13059478#comment-13059478 ]
Marcel Casado edited comment on AMQ-3388 at 7/4/11 3:21 PM:
------------------------------------------------------------
In this patch a Factory for xstream is added and all the classes that need and instance uses is static method to get a new instance. The method has a flag to whether to create it with a wrapper that ignores unknown fields. All the classes needing a XStream instance ask for the ignoring fields instance giving some flexibility on changes in the commands APT with respect fields. In the future xstream could provide this in a more configurable way :http://jira.codehaus.org/browse/XSTR-30
was (Author: marcelcasado):
In this patch a Factory for stream is added and all the classes that need and instance uses is static method to get a new instance. The method has a flag whether to create to create it with a wrapper that ignores unknown fields. All the classes needing a XStream instance ask for the ignoring fields instance giving some flexibility on changes in the commands APT with respecto fields. In the future xstream could provide this in a more configurable way :http://jira.codehaus.org/browse/XSTR-30
> Http/https protocol uses Xstream for serializing commands in xml. Field additions to the commands bresks xtream serializacion between amq versions
> ---------------------------------------------------------------------------------------------------------------------------------------------------
>
> Key: AMQ-3388
> URL: https://issues.apache.org/jira/browse/AMQ-3388
> Project: ActiveMQ
> Issue Type: Improvement
> Components: Transport
> Affects Versions: 5.4.1, 5.4.2, 5.5.0
> Reporter: Marcel Casado
> Attachments: AMQ-3388.patch
>
>
> Addition of fields in commands used between clients and brokers in newer amq versions breaks easily the http transport that uses xstream for xml serialization.
> To make xstream more tolerant to this changes between versions in org.apache.activemq.transport.xstream.XStreamWireFormat we could add the code below so xstream ignores unknown fields :
> // Implementation methods
> // -------------------------------------------------------------------------
> protected XStream createXStream() {
> // return new XStream();
> return new XStream() {
> protected MapperWrapper wrapMapper(MapperWrapper next) {
> return new MapperWrapper(next) {
> public boolean shouldSerializeMember(Class definedIn, String fieldName) {
> return definedIn != Object.class ? super.shouldSerializeMember(definedIn, fieldName) : false;
> }
> };
> }
> };
> }
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Updated] (AMQ-3388) Http/https protocol uses Xstream for
serializing commands in xml. Field additions to the commands bresks xtream
serializacion between amq versions
Posted by "Marcel Casado (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/AMQ-3388?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Marcel Casado updated AMQ-3388:
-------------------------------
Attachment: AMQ-3388.patch
In this patch a Factory for xstream is added and all the classes that need and instance uses is static method to get a new instance. The method has a flag to whether to create it with a wrapper that ignores unknown fields. All the classes needing a XStream instance ask for the ignoring fields instance giving some flexibility on changes in the commands APT with respect fields. In the future xstream could provide this in a more configurable way :http://jira.codehaus.org/browse/XSTR-30
> Http/https protocol uses Xstream for serializing commands in xml. Field additions to the commands bresks xtream serializacion between amq versions
> ---------------------------------------------------------------------------------------------------------------------------------------------------
>
> Key: AMQ-3388
> URL: https://issues.apache.org/jira/browse/AMQ-3388
> Project: ActiveMQ
> Issue Type: Improvement
> Components: Transport
> Affects Versions: 5.4.1, 5.4.2, 5.5.0
> Reporter: Marcel Casado
> Attachments: AMQ-3388.patch
>
>
> Addition of fields in commands used between clients and brokers in newer amq versions breaks easily the http transport that uses xstream for xml serialization.
> To make xstream more tolerant to this changes between versions in org.apache.activemq.transport.xstream.XStreamWireFormat we could add the code below so xstream ignores unknown fields :
> // Implementation methods
> // -------------------------------------------------------------------------
> protected XStream createXStream() {
> // return new XStream();
> return new XStream() {
> protected MapperWrapper wrapMapper(MapperWrapper next) {
> return new MapperWrapper(next) {
> public boolean shouldSerializeMember(Class definedIn, String fieldName) {
> return definedIn != Object.class ? super.shouldSerializeMember(definedIn, fieldName) : false;
> }
> };
> }
> };
> }
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Updated] (AMQ-3388) Http/https protocol uses Xstream for
serializing commands in xml. Field additions to the commands bresks xtream
serializacion between amq versions
Posted by "Marcel Casado (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/AMQ-3388?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Marcel Casado updated AMQ-3388:
-------------------------------
Attachment: (was: AMQ-3388.patch)
> Http/https protocol uses Xstream for serializing commands in xml. Field additions to the commands bresks xtream serializacion between amq versions
> ---------------------------------------------------------------------------------------------------------------------------------------------------
>
> Key: AMQ-3388
> URL: https://issues.apache.org/jira/browse/AMQ-3388
> Project: ActiveMQ
> Issue Type: Improvement
> Components: Transport
> Affects Versions: 5.4.1, 5.4.2, 5.5.0
> Reporter: Marcel Casado
>
> Addition of fields in commands used between clients and brokers in newer amq versions breaks easily the http transport that uses xstream for xml serialization.
> To make xstream more tolerant to this changes between versions in org.apache.activemq.transport.xstream.XStreamWireFormat we could add the code below so xstream ignores unknown fields :
> // Implementation methods
> // -------------------------------------------------------------------------
> protected XStream createXStream() {
> // return new XStream();
> return new XStream() {
> protected MapperWrapper wrapMapper(MapperWrapper next) {
> return new MapperWrapper(next) {
> public boolean shouldSerializeMember(Class definedIn, String fieldName) {
> return definedIn != Object.class ? super.shouldSerializeMember(definedIn, fieldName) : false;
> }
> };
> }
> };
> }
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Updated] (AMQ-3388) Http/https protocol uses Xstream for
serializing commands in xml. Field additions to the commands bresks xtream
serializacion between amq versions
Posted by "Marcel Casado (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/AMQ-3388?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Marcel Casado updated AMQ-3388:
-------------------------------
Attachment: AMQ-3388.patch
In this patch a Factory for stream is added and all the classes that need and instance uses is static method to get a new instance. The method has a flag whether to create to create it with a wrapper that ignores unknown fields. All the classes needing a XStream instance ask for the ignoring fields instance giving some flexibility on changes in the commands APT with respecto fields. In the future xstream could provide this in a more configurable way :http://jira.codehaus.org/browse/XSTR-30
> Http/https protocol uses Xstream for serializing commands in xml. Field additions to the commands bresks xtream serializacion between amq versions
> ---------------------------------------------------------------------------------------------------------------------------------------------------
>
> Key: AMQ-3388
> URL: https://issues.apache.org/jira/browse/AMQ-3388
> Project: ActiveMQ
> Issue Type: Improvement
> Components: Transport
> Affects Versions: 5.4.1, 5.4.2, 5.5.0
> Reporter: Marcel Casado
> Attachments: AMQ-3388.patch
>
>
> Addition of fields in commands used between clients and brokers in newer amq versions breaks easily the http transport that uses xstream for xml serialization.
> To make xstream more tolerant to this changes between versions in org.apache.activemq.transport.xstream.XStreamWireFormat we could add the code below so xstream ignores unknown fields :
> // Implementation methods
> // -------------------------------------------------------------------------
> protected XStream createXStream() {
> // return new XStream();
> return new XStream() {
> protected MapperWrapper wrapMapper(MapperWrapper next) {
> return new MapperWrapper(next) {
> public boolean shouldSerializeMember(Class definedIn, String fieldName) {
> return definedIn != Object.class ? super.shouldSerializeMember(definedIn, fieldName) : false;
> }
> };
> }
> };
> }
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira