[jira] [Commented] (CASSANDRA-18697) Skip ColumnFamilyStore#topPartitions initialization when client or tool mode
[ https://issues.apache.org/jira/browse/CASSANDRA-18697?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17749949#comment-17749949 ] Yifan Cai commented on CASSANDRA-18697: --- Preparing to commit ||Branch||CI|| |[4.1|https://github.com/yifan-c/cassandra/tree/r/upstream/pr2535-4.1]|[CI|https://app.circleci.com/pipelines/github/yifan-c/cassandra?branch=r%2Fupstream%2Fpr2535-4.1]| |[trunk|https://github.com/yifan-c/cassandra/tree/r/upstream/pr2519-trunk]|[CI|https://app.circleci.com/pipelines/github/yifan-c/cassandra?branch=r%2Fupstream%2Fpr2519-trunk]| > Skip ColumnFamilyStore#topPartitions initialization when client or tool mode > > > Key: CASSANDRA-18697 > URL: https://issues.apache.org/jira/browse/CASSANDRA-18697 > Project: Cassandra > Issue Type: Bug > Components: Tool/bulk load >Reporter: Francisco Guerrero >Assignee: Francisco Guerrero >Priority: Normal > Time Spent: 1.5h > Remaining Estimate: 0h > > In {{org.apache.cassandra.db.ColumnFamilyStore}} the {{topPartitions}} is > initialized when the keyspace is not a system keyspace. However, when running > the cassandra library as client mode or tool mode, the initialization also > happens. However, {{TopPartitionTracker}} performs queries to the {{system}} > keyspace, which might not be available in most of the cases. For that reason, > we should skip initialization of {{topPartitions}} when running on client > mode or tool mode. > In utilities and external libraries, this can produce a warning that is > displayed with a stack trace. This warning can be misleading for end users, > and can cause confusion. But more importantly, the initialization of > {{topPartitions}} is not required in this mode. > The warning is similar to this: > {code:java} > WARN org.apache.cassandra.db.SystemKeyspace: Could not load stored top > SIZES partitions for ... > org.apache.cassandra.db.KeyspaceNotDefinedException: keyspace system does > not exist > at > org.apache.cassandra.schema.Schema.validateTable(Schema.java:xxx) ~[?:?] > at > org.apache.cassandra.cql3.statements.SelectStatement$RawStatement.prepare(SelectStatement.java:xxx) > ~[?:?] > at > org.apache.cassandra.cql3.statements.SelectStatement$RawStatement.prepare(SelectStatement.java:xxx) > ~[?:?] > at > org.apache.cassandra.cql3.statements.SelectStatement$RawStatement.prepare(SelectStatement.java:xxx) > ~[?:?] > at > org.apache.cassandra.cql3.QueryProcessor.parseAndPrepare(QueryProcessor.java:xxx) > ~[?:?] > ... {code} -- This message was sent by Atlassian Jira (v8.20.10#820010) - To unsubscribe, e-mail: commits-unsubscr...@cassandra.apache.org For additional commands, e-mail: commits-h...@cassandra.apache.org
[jira] [Commented] (CASSANDRA-18697) Skip ColumnFamilyStore#topPartitions initialization when client or tool mode
[ https://issues.apache.org/jira/browse/CASSANDRA-18697?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17748721#comment-17748721 ] Dinesh Joshi commented on CASSANDRA-18697: -- +1, thanks for the patch. > Skip ColumnFamilyStore#topPartitions initialization when client or tool mode > > > Key: CASSANDRA-18697 > URL: https://issues.apache.org/jira/browse/CASSANDRA-18697 > Project: Cassandra > Issue Type: Bug > Components: Tool/bulk load >Reporter: Francisco Guerrero >Assignee: Francisco Guerrero >Priority: Normal > Time Spent: 1.5h > Remaining Estimate: 0h > > In {{org.apache.cassandra.db.ColumnFamilyStore}} the {{topPartitions}} is > initialized when the keyspace is not a system keyspace. However, when running > the cassandra library as client mode or tool mode, the initialization also > happens. However, {{TopPartitionTracker}} performs queries to the {{system}} > keyspace, which might not be available in most of the cases. For that reason, > we should skip initialization of {{topPartitions}} when running on client > mode or tool mode. > In utilities and external libraries, this can produce a warning that is > displayed with a stack trace. This warning can be misleading for end users, > and can cause confusion. But more importantly, the initialization of > {{topPartitions}} is not required in this mode. > The warning is similar to this: > {code:java} > WARN org.apache.cassandra.db.SystemKeyspace: Could not load stored top > SIZES partitions for ... > org.apache.cassandra.db.KeyspaceNotDefinedException: keyspace system does > not exist > at > org.apache.cassandra.schema.Schema.validateTable(Schema.java:xxx) ~[?:?] > at > org.apache.cassandra.cql3.statements.SelectStatement$RawStatement.prepare(SelectStatement.java:xxx) > ~[?:?] > at > org.apache.cassandra.cql3.statements.SelectStatement$RawStatement.prepare(SelectStatement.java:xxx) > ~[?:?] > at > org.apache.cassandra.cql3.statements.SelectStatement$RawStatement.prepare(SelectStatement.java:xxx) > ~[?:?] > at > org.apache.cassandra.cql3.QueryProcessor.parseAndPrepare(QueryProcessor.java:xxx) > ~[?:?] > ... {code} -- This message was sent by Atlassian Jira (v8.20.10#820010) - To unsubscribe, e-mail: commits-unsubscr...@cassandra.apache.org For additional commands, e-mail: commits-h...@cassandra.apache.org
[jira] [Commented] (CASSANDRA-18697) Skip ColumnFamilyStore#topPartitions initialization when client or tool mode
[ https://issues.apache.org/jira/browse/CASSANDRA-18697?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17748680#comment-17748680 ] Francisco Guerrero commented on CASSANDRA-18697: 4.1 PR: [https://github.com/apache/cassandra/pull/2535] > Skip ColumnFamilyStore#topPartitions initialization when client or tool mode > > > Key: CASSANDRA-18697 > URL: https://issues.apache.org/jira/browse/CASSANDRA-18697 > Project: Cassandra > Issue Type: Bug > Components: Tool/bulk load >Reporter: Francisco Guerrero >Assignee: Francisco Guerrero >Priority: Normal > Time Spent: 1.5h > Remaining Estimate: 0h > > In {{org.apache.cassandra.db.ColumnFamilyStore}} the {{topPartitions}} is > initialized when the keyspace is not a system keyspace. However, when running > the cassandra library as client mode or tool mode, the initialization also > happens. However, {{TopPartitionTracker}} performs queries to the {{system}} > keyspace, which might not be available in most of the cases. For that reason, > we should skip initialization of {{topPartitions}} when running on client > mode or tool mode. > In utilities and external libraries, this can produce a warning that is > displayed with a stack trace. This warning can be misleading for end users, > and can cause confusion. But more importantly, the initialization of > {{topPartitions}} is not required in this mode. > The warning is similar to this: > {code:java} > WARN org.apache.cassandra.db.SystemKeyspace: Could not load stored top > SIZES partitions for ... > org.apache.cassandra.db.KeyspaceNotDefinedException: keyspace system does > not exist > at > org.apache.cassandra.schema.Schema.validateTable(Schema.java:xxx) ~[?:?] > at > org.apache.cassandra.cql3.statements.SelectStatement$RawStatement.prepare(SelectStatement.java:xxx) > ~[?:?] > at > org.apache.cassandra.cql3.statements.SelectStatement$RawStatement.prepare(SelectStatement.java:xxx) > ~[?:?] > at > org.apache.cassandra.cql3.statements.SelectStatement$RawStatement.prepare(SelectStatement.java:xxx) > ~[?:?] > at > org.apache.cassandra.cql3.QueryProcessor.parseAndPrepare(QueryProcessor.java:xxx) > ~[?:?] > ... {code} -- This message was sent by Atlassian Jira (v8.20.10#820010) - To unsubscribe, e-mail: commits-unsubscr...@cassandra.apache.org For additional commands, e-mail: commits-h...@cassandra.apache.org
[jira] [Commented] (CASSANDRA-18697) Skip ColumnFamilyStore#topPartitions initialization when client or tool mode
[ https://issues.apache.org/jira/browse/CASSANDRA-18697?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=17747685#comment-17747685 ] Yifan Cai commented on CASSANDRA-18697: --- +1 on the patch. > Skip ColumnFamilyStore#topPartitions initialization when client or tool mode > > > Key: CASSANDRA-18697 > URL: https://issues.apache.org/jira/browse/CASSANDRA-18697 > Project: Cassandra > Issue Type: Bug > Components: Tool/bulk load >Reporter: Francisco Guerrero >Assignee: Francisco Guerrero >Priority: Normal > Time Spent: 10m > Remaining Estimate: 0h > > In {{org.apache.cassandra.db.ColumnFamilyStore}} the {{topPartitions}} is > initialized when the keyspace is not a system keyspace. However, when running > the cassandra library as client mode or tool mode, the initialization also > happens. However, {{TopPartitionTracker}} performs queries to the {{system}} > keyspace, which might not be available in most of the cases. For that reason, > we should skip initialization of {{topPartitions}} when running on client > mode or tool mode. > In utilities and external libraries, this can produce a warning that is > displayed with a stack trace. This warning can be misleading for end users, > and can cause confusion. But more importantly, the initialization of > {{topPartitions}} is not required in this mode. > The warning is similar to this: > {code:java} > WARN org.apache.cassandra.db.SystemKeyspace: Could not load stored top > SIZES partitions for ... > org.apache.cassandra.db.KeyspaceNotDefinedException: keyspace system does > not exist > at > org.apache.cassandra.schema.Schema.validateTable(Schema.java:xxx) ~[?:?] > at > org.apache.cassandra.cql3.statements.SelectStatement$RawStatement.prepare(SelectStatement.java:xxx) > ~[?:?] > at > org.apache.cassandra.cql3.statements.SelectStatement$RawStatement.prepare(SelectStatement.java:xxx) > ~[?:?] > at > org.apache.cassandra.cql3.statements.SelectStatement$RawStatement.prepare(SelectStatement.java:xxx) > ~[?:?] > at > org.apache.cassandra.cql3.QueryProcessor.parseAndPrepare(QueryProcessor.java:xxx) > ~[?:?] > ... {code} -- This message was sent by Atlassian Jira (v8.20.10#820010) - To unsubscribe, e-mail: commits-unsubscr...@cassandra.apache.org For additional commands, e-mail: commits-h...@cassandra.apache.org