> On April 10, 2015, 4:43 p.m., Mehant Baid wrote: > > exec/java-exec/src/main/codegen/templates/NullableValueVectors.java, line 86 > > <https://reviews.apache.org/r/33035/diff/1/?file=921986#file921986line86> > > > > Why are we bubbling up the retain logic in clear to the top level > > vector from the individual vectors? In the code above the 'if' block we > > anyway drill down to the individual vectors to get the buffers, might as > > well do the retain there like we are doing currently? > > > > If some of the vectors isn't handling this correctly we should modify > > those.
We cannot do this as we need to call #clear right after invoking super.getBuffers(true), which will release buffers. - Hanifi ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/33035/#review79691 ----------------------------------------------------------- On April 13, 2015, 10:07 p.m., Hanifi Gunes wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/33035/ > ----------------------------------------------------------- > > (Updated April 13, 2015, 10:07 p.m.) > > > Review request for drill, Mehant Baid and Parth Chandra. > > > Repository: drill-git > > > Description > ------- > > DRILL-2719: ValueVector#getBuffers(clear) must consistently clear vectors & > retain buffers > > BaseDataValueVector > - getBuffers now rely on getBufferSize while determining buffers to return > - getBuffers maintains reference count to underlying buffers while clearing > the vector > - getBufferSize relies on value count reported by accessor while determining > buffer size > - replaced DeadBuf references with an empty buffer. underlying buffer now > should never be *null*. > > Templates & VV subtypes > - ensure getBuffers conforms to VV#getBuffers > > TestEmptyPopulator > - make mock allocator return an empty buffer when requested > > > Diffs > ----- > > exec/java-exec/src/main/codegen/templates/NullableValueVectors.java > 075316e4f3ac5327e7893688c5e88cfee98e50bc > exec/java-exec/src/main/codegen/templates/RepeatedValueVectors.java > c7cf8e6fe18f1b9813ae22495ac79a447f61cfff > exec/java-exec/src/main/codegen/templates/VariableLengthVectors.java > edb851eb10be43d889ce5fd98d9bde036707870a > > exec/java-exec/src/main/java/org/apache/drill/exec/vector/BaseDataValueVector.java > d48ea99237bb822cafc8b835c3af0f4789c6eb29 > > exec/java-exec/src/main/java/org/apache/drill/exec/vector/complex/AbstractMapVector.java > b0783afe57317dcd8dc7a2a8d967dcdb1f305edb > > exec/java-exec/src/main/java/org/apache/drill/exec/vector/complex/RepeatedListVector.java > c0f529961343145d67f835a95f58c4eaf2fae2a4 > > exec/java-exec/src/test/java/org/apache/drill/exec/vector/complex/TestEmptyPopulator.java > 8426a6abbf0c20be6f81bc82521f31ed7cde2557 > > Diff: https://reviews.apache.org/r/33035/diff/ > > > Testing > ------- > > unit and beyond > > > Thanks, > > Hanifi Gunes > >
