asterixdb-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From AsterixDB Code Review <>
Subject Change in asterixdb[master]: [NO ISSUE][RT] Randomized Sampling
Date Mon, 02 Dec 2019 22:49:43 GMT
>From Ali Alsuliman <>:

Ali Alsuliman has posted comments on this change. (

Change subject: [NO ISSUE][RT] Randomized Sampling

Patch Set 1:

Commit Message: 
PS1, Line 7: NO ISSUE
Let's use ASTERIXDB-2684

File asterixdb/asterix-runtime/src/main/java/org/apache/asterix/runtime/aggregates/std/

PS1, Line 102: ArrayList
minor, let's make this private final List<ArrayBackedValueStorage>

PS1, Line 103: private
minor, let's make this private final

PS1, Line 104: int
minor, private int count = 0;

PS1, Line 126: samples.clear();
Let's reset the count, here, too. count = 0;

PS1, Line 127: rangeMapBits.reset();
             :             // write a dummy integer at the beginning to be filled later with
the actual number of samples taken
             :             IntegerSerializerDeserializer.write(0, rangeMapBits.getDataOutput());
With the new changes, we don't need these lines here, I think. Let's move them down into the
finish() (in the else)

PS1, Line 141: storage
minor, let's rename this to sampleStorage (just to not confuse it with the already existing
instance variable)

PS1, Line 152: storage
same here

PS1, Line 179: IntegerPointable.setInteger(rangeMapBits.getByteArray(), rangeMapBits.getStartOffset(),
After moving the code in the init():
IntegerSerializerDeserializer.write(samples.size(), rangeMapBits.getDataOutput());

To view, visit
To unsubscribe, or for help writing mail filters, visit

Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Change-Id: I8889f49b127773d90c6ef8a9f09d8993a4da68ac
Gerrit-Change-Number: 4223
Gerrit-PatchSet: 1
Gerrit-Owner: Mikhail Lychagin <>
Gerrit-Reviewer: Anon. E. Moose #1000171
Gerrit-Reviewer: Jenkins <>
Gerrit-CC: Ali Alsuliman <>
Gerrit-Comment-Date: Mon, 02 Dec 2019 22:49:43 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Gerrit-MessageType: comment

View raw message