RE: Why is PayloadAttribute.clone() shallow?

2014-11-08 Thread Uwe Schindler
is PayloadAttribute.clone() shallow? Hi Someone ran into this in the context of working with TeeSinkTokenFilter - when the state is cloned for each of the sinks, if you have a PayloadAttribute on the stream, it's shallow cloned and thus all sinks share the same byte[]. At first I thought

Re: Why is PayloadAttribute.clone() shallow?

2014-11-08 Thread Shai Erera
Erera [mailto:ser...@gmail.com] *Sent:* Saturday, November 08, 2014 5:26 AM *To:* dev@lucene.apache.org *Subject:* Why is PayloadAttribute.clone() shallow? Hi Someone ran into this in the context of working with TeeSinkTokenFilter - when the state is cloned for each of the sinks, if you have

Why is PayloadAttribute.clone() shallow?

2014-11-07 Thread Shai Erera
Hi Someone ran into this in the context of working with TeeSinkTokenFilter - when the state is cloned for each of the sinks, if you have a PayloadAttribute on the stream, it's shallow cloned and thus all sinks share the same byte[]. At first I thought this is just a bug in PA.clone(), and that