cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Stefania (JIRA)" <>
Subject [jira] [Commented] (CASSANDRA-10750) Minor code improvements
Date Tue, 15 Dec 2015 09:22:46 GMT


Stefania commented on CASSANDRA-10750:

Well spotted.

I've finished the review, I've put my changes in [this commit|]
of [this branch|]. I've only changed slightly
{{PasswordAuthenticator}} and {{MerkleTree}}, the rest should be nits. 

The replacement of recursive code with iterative code, whilst it's true that it is more efficient,
it is also true that the recursive code is more elegant. I am thinking of the 2 changes in
the stress tool specifically, they don't seem to recurse much and the original code was more
elegant. I leave that to your decision however.

If we can get one clean CI run without timeouts and with my changes cross reviewed by you
and applied, then this can be committed.

> Minor code improvements
> -----------------------
>                 Key: CASSANDRA-10750
>                 URL:
>             Project: Cassandra
>          Issue Type: Improvement
>            Reporter: Robert Stupp
>            Assignee: Robert Stupp
>            Priority: Minor
> Went though several IDE inspections and found some places in the code that could be improved.
These are just minor improvements and no bug fixes (except one minor "theoretical" thing).
> The [branch on github against trunk|]
contains a series of commits:
> * simplify Mutation.apply to remove the casts
> * "minor code improvements" just replaces some expressions that are effectively constant
> * remove unused assignments (probably just cosmetic)
> * collapse identical if-branches (probably just cosmetic)
> * empty array constants
> * fix printf usage (could potentially raise an exception in printf)
> * replace tail-recursion in some critical sections (as the JVM cannot optimize that AFAIK)
> * remove methods identical to their super methods (probably just cosmetic)
> [cassci results here|]

This message was sent by Atlassian JIRA

View raw message