incubator-cassandra-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Boris Shulman <>
Subject cassandra index implementation
Date Thu, 13 May 2010 11:22:13 GMT
I see that the following code is used in order to create an index:

      for (Iterator<IColumn> it = columns.iterator(); it.hasNext();)
            column =;
            if (firstColumn == null)
                firstColumn = column;
                startPosition = endPosition;
            endPosition += column.serializedSize();
            /* if we hit the column index size that we have to index
after, go ahead and index it. */
            if (endPosition - startPosition >=
                IndexHelper.IndexInfo cIndexInfo = new
startPosition, endPosition - startPosition);
                indexSizeInBytes += cIndexInfo.serializedSize();
                firstColumn = null;

According to this code the name of the first column is stored numerous
times which can be very expensive in a large rows. I think that a
better implementation is to have an Index Header that in turn will
contain the name of the first column.
Are there any plans to change this implementation? Is anyone aware of
an open issue for it?

View raw message