accumulo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Keith Turner <ke...@deenlo.com>
Subject Re: Syntax Question in Mutation.java
Date Mon, 05 Mar 2012 16:37:13 GMT
Yeah, I agree I do not think there is a reason to wait.  Its just
something to be aware of.  Changes to 1.4 will drop off as it becomes
more stable.  In the past was have seen a good bit of changes between
1.X.0 and 1.X.1, as users find bugs. After that it seems to taper off.

On Mon, Mar 5, 2012 at 11:10 AM, David Medinets
<david.medinets@gmail.com> wrote:
> That is an excellent point for which I have no great answer. I can
> avoid making changes to the 1.5 code until the 1.4 code is code
> complete... but then why have a branch at all? Let's talk about how
> the merge happens - which I am ignorant of. Does it happen file by
> file or automated with conflicts called out?
>
> On Mon, Mar 5, 2012 at 10:55 AM, Keith Turner <keith@deenlo.com> wrote:
>> I am not opposed to this change, just had a comment.  One thing to
>> consider is merging bug fixes from 1.4.  The more trunk is changed,
>> the more likely bug fixes in 1.4 will not merge cleanly.  This
>> increases the chance that something will be lost in translation.
>>
>> Keith
>>
>> On Sun, Mar 4, 2012 at 10:52 PM, David Medinets
>> <david.medinets@gmail.com> wrote:
>>> In core/src/main/java/org/apache/accumulo/core/data/Mutation.java, I
>>> see the following code:
>>>
>>>
>>>    private List<byte[]> values;
>>>    private int cachedValLens = -1;
>>>
>>>  long getValueLengths() {
>>>    if (values == null)
>>>      return 0;
>>>
>>>    if (cachedValLens == -1) {
>>>      int tmpCVL = 0;
>>>      for (byte val[] : values)
>>>        tmpCVL += val.length;
>>>
>>>      cachedValLens = tmpCVL;
>>>    }
>>>
>>>    return cachedValLens;
>>>
>>>  }
>>>
>>> PMD is suggesting that the line:
>>>
>>>      for (byte val[] : values)
>>>
>>> should be
>>>
>>>      for (byte[] val : values)
>>>
>>> Is this a useful change?

Mime
View raw message