I believe the comments there are mainly about concurrency problem, not for linked list vs. array list, at least for me...
2018-03-11 4:12 GMT+08:00 Mike Drob <mad...@cloudera.com>: > Hi devs, > > I was reading through HBASE-17434 trying to understand why we have two > linked lists in compaction pipeline and I'm having trouble following the > conversation there, especially since it seems intertwined with HBASE-17379 > and jumps back and forth a few times. > > It looks like we are implementing our own copy-on-write list, and there is > a claim that addFirst is faster on a LinkedList than an array based list. I > am concerned about the LL copy in pushHead - even if addFirst is faster, a > LL copy is fairly slow and likely loses us any gains. Also, I'm a little > dubious on the use of LL given that we support a replaceAtIndex which will > be much faster in an array. > > Can we improve by using an ArrayDeque? > > Eschar, Anastasia, WDYT? > > Thanks, > Mike > > Some observations about performance - > https://stuartmarks.wordpress.com/2015/12/18/some-java-list-benchmarks/ >