[ 
https://issues.apache.org/jira/browse/CASSANDRA-4180?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13618322#comment-13618322
 ] 

Jason Brown commented on CASSANDRA-4180:
----------------------------------------

Removing the column column and row size and using an end-of-row (EOR) marker 
seems straightforward, but the devil has been in the details. The main 
challenge is reading to you read columns until the EOR marker, and you return 
false on the next hasNext(). The problem is if a higher-level iterator calls 
hasNext() again on that row, you've already moved the the file pointer past the 
EOR row (and are at the beginning of the next row). So you look for the EOR 
marker, which you've already read for that row, but the pointer reads either 
the key for the next row or EOF - either way, not so good. It took me while to 
work though that one, and I think I'm done resolving the bugs around removing 
column count.

Removing the row size has been largely easier, but I'm working through 
(hopefully) the last issue on SSTS.KeyScanningIterator. It uses row size to 
calculate the start of the next row. Without that, if you skip a row based 
solely upon key, then I need to efficiently advance the file pointer the the 
head of the next row.

Hoping to finish very soon.
                
> Single-pass compaction for LCR
> ------------------------------
>
>                 Key: CASSANDRA-4180
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-4180
>             Project: Cassandra
>          Issue Type: Improvement
>          Components: Core
>            Reporter: Sylvain Lebresne
>            Assignee: Jason Brown
>              Labels: compaction
>             Fix For: 2.0
>
>
> LazilyCompactedRow reads all data twice to compact a row which is obviously 
> inefficient. The main reason we do that is to compute the row header. 
> However, CASSANDRA-2319 have removed the main part of that row header. What 
> remains is the size in bytes and the number of columns, but it should be 
> relatively simple to remove those, which would then remove the need for the 
> two-phase compaction.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to