[
https://issues.apache.org/jira/browse/CASSANDRA-15796?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17101504#comment-17101504
]
maxwellguo commented on CASSANDRA-15796:
----------------------------------------
we want to get the row for per range ,but the Denominator is the number for all
cell the numerator is the regular column to request , So the data is also not
so accurate
> Cassandra get range slice got Inaccurate estimates for concurrencyFactor
> -------------------------------------------------------------------------
>
> Key: CASSANDRA-15796
> URL: https://issues.apache.org/jira/browse/CASSANDRA-15796
> Project: Cassandra
> Issue Type: Bug
> Components: Legacy/Coordination
> Reporter: maxwellguo
> Priority: Normal
>
> Cassandra version :3.11.4
> For table that do not got a regular column , when we do partition range read
> and we got to the code function :
> {code:java}
> // Some comments here
> public String getRangeSlice(PartitionRangeReadCommand command,
> ConsistencyLevel consistencyLevel, long queryStartNanoTime)
> {code}
> we will do some calculation to estimate the data per range in the function :
> {code:java}
> // Some comments here
> private static float estimateResultsPerRange(PartitionRangeReadCommand
> command, Keyspace keyspace)
> {code}
> when we got no index so we will use :
> {code:java}
> // Some comments here
> command.limits().estimateTotalResults(cfs)
> --->(for CQLlimits)
> *public float estimateTotalResults(ColumnFamilyStore cfs)
> {
> // TODO: we should start storing stats on the number of rows
> (instead of the number of cells, which
> // is what getMeanColumns returns)
> float rowsPerPartition = ((float) cfs.getMeanColumns()) /
> cfs.metadata.partitionColumns().regulars.size();
> return rowsPerPartition * (cfs.estimateKeys());
> }*
> {code}
> when the regulars is zero ,we will got an error result that is non-zero
> value divided by zero .
--
This message was sent by Atlassian Jira
(v8.3.4#803005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]