[jira] [Commented] (CASSANDRA-14459) DynamicEndpointSnitch should never prefer latent nodes
[ https://issues.apache.org/jira/browse/CASSANDRA-14459?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16481741#comment-16481741 ] Joseph Lynch commented on CASSANDRA-14459: -- I didn't find a previous issue report even though I know that lots of folks know about these shortcomings. I think the way I've written it this is reasonable to merge into 3.0 / 3.11 but for now here is the trunk patch ||trunk|| |[patch|https://github.com/apache/cassandra/compare/trunk...jolynch:CASSANDRA-14459]| |[unit tests|https://github.com/apache/cassandra/compare/trunk...jolynch:CASSANDRA-14459#diff-f1baf62fd510947bf60e9a9def69810b] [!https://circleci.com/gh/jolynch/cassandra/tree/CASSANDRA-14459.png?circle-token= 1102a59698d04899ec971dd36e925928f7b521f5!|https://circleci.com/gh/jolynch/cassandra/tree/CASSANDRA-14459]| > DynamicEndpointSnitch should never prefer latent nodes > -- > > Key: CASSANDRA-14459 > URL: https://issues.apache.org/jira/browse/CASSANDRA-14459 > Project: Cassandra > Issue Type: Improvement > Components: Coordination >Reporter: Joseph Lynch >Priority: Minor > > The DynamicEndpointSnitch has two unfortunate behaviors that allow it to > provide latent hosts as replicas: > # Loses all latency information when Cassandra restarts > # Clears latency information entirely every ten minutes (by default), > allowing global queries to be routed to _other datacenters_ (and local > queries cross racks/azs) > This means that the first few queries after restart/reset could be quite slow > compared to average latencies. I propose we solve this by resetting to the > minimum observed latency instead of completely clearing the samples and > extending the {{isLatencyForSnitch}} idea to a three state variable instead > of two, in particular {{YES}}, {{NO}}, {{MAYBE}}. This extension allows > {{EchoMessages}} and {{PingMessages}} to send {{MAYBE}} indicating that the > DS should use those measurements if it only has one or fewer samples for a > host. This fixes both problems because on process restart we send out > {{PingMessages}} / {{EchoMessages}} as part of startup, and we would reset to > effectively the RTT of the hosts (also at that point normal gossip > {{EchoMessages}} have an opportunity to add an additional latency > measurement). > This strategy also nicely deals with the "a host got slow but now it's fine" > problem that the DS resets were (afaik) designed to stop because the > {{EchoMessage}} ping latency will count only after the reset for that host. > Ping latency is a more reasonable lower bound on host latency (as opposed to > status quo of zero). -- This message was sent by Atlassian JIRA (v7.6.3#76005) - To unsubscribe, e-mail: commits-unsubscr...@cassandra.apache.org For additional commands, e-mail: commits-h...@cassandra.apache.org
[jira] [Created] (CASSANDRA-14459) DynamicEndpointSnitch should never prefer latent nodes
Joseph Lynch created CASSANDRA-14459: Summary: DynamicEndpointSnitch should never prefer latent nodes Key: CASSANDRA-14459 URL: https://issues.apache.org/jira/browse/CASSANDRA-14459 Project: Cassandra Issue Type: Improvement Components: Coordination Reporter: Joseph Lynch The DynamicEndpointSnitch has two unfortunate behaviors that allow it to provide latent hosts as replicas: # Loses all latency information when Cassandra restarts # Clears latency information entirely every ten minutes (by default), allowing global queries to be routed to _other datacenters_ (and local queries cross racks/azs) This means that the first few queries after restart/reset could be quite slow compared to average latencies. I propose we solve this by resetting to the minimum observed latency instead of completely clearing the samples and extending the {{isLatencyForSnitch}} idea to a three state variable instead of two, in particular {{YES}}, {{NO}}, {{MAYBE}}. This extension allows {{EchoMessages}} and {{PingMessages}} to send {{MAYBE}} indicating that the DS should use those measurements if it only has one or fewer samples for a host. This fixes both problems because on process restart we send out {{PingMessages}} / {{EchoMessages}} as part of startup, and we would reset to effectively the RTT of the hosts (also at that point normal gossip {{EchoMessages}} have an opportunity to add an additional latency measurement). This strategy also nicely deals with the "a host got slow but now it's fine" problem that the DS resets were (afaik) designed to stop because the {{EchoMessage}} ping latency will count only after the reset for that host. Ping latency is a more reasonable lower bound on host latency (as opposed to status quo of zero). -- This message was sent by Atlassian JIRA (v7.6.3#76005) - To unsubscribe, e-mail: commits-unsubscr...@cassandra.apache.org For additional commands, e-mail: commits-h...@cassandra.apache.org
[jira] [Updated] (CASSANDRA-14458) Add virtual table to list active connections
[ https://issues.apache.org/jira/browse/CASSANDRA-14458?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Chris Lohfink updated CASSANDRA-14458: -- Status: Patch Available (was: Open) > Add virtual table to list active connections > > > Key: CASSANDRA-14458 > URL: https://issues.apache.org/jira/browse/CASSANDRA-14458 > Project: Cassandra > Issue Type: New Feature >Reporter: Chris Lohfink >Assignee: Chris Lohfink >Priority: Minor > > List all active connections in virtual table like: > {code:sql} > cqlsh:system> select * from system_views.clients ; > > client_address | cipher | driver_name | driver_version | keyspace | > protocol | requests | ssl | user | version > --+---+-++--+---+--+---+---+- > /127.0.0.1:63903 | undefined | undefined | undefined | | > undefined | 13 | False | anonymous | 4 > /127.0.0.1:63904 | undefined | undefined | undefined | system | > undefined | 16 | False | anonymous | 4 > {code} -- This message was sent by Atlassian JIRA (v7.6.3#76005) - To unsubscribe, e-mail: commits-unsubscr...@cassandra.apache.org For additional commands, e-mail: commits-h...@cassandra.apache.org
[jira] [Commented] (CASSANDRA-14458) Add virtual table to list active connections
[ https://issues.apache.org/jira/browse/CASSANDRA-14458?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16481495#comment-16481495 ] ASF GitHub Bot commented on CASSANDRA-14458: GitHub user clohfink opened a pull request: https://github.com/apache/cassandra/pull/227 Virtual table to list active connections for CASSANDRA-14458 You can merge this pull request into a Git repository by running: $ git pull https://github.com/clohfink/cassandra clientstats Alternatively you can review and apply these changes as the patch at: https://github.com/apache/cassandra/pull/227.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #227 commit 4c17bd05446254033efae745a3649a5de10d1df7 Author: Chris Lohfink Date: 2018-05-19T07:04:19Z Virtual table to list active connections for CASSANDRA-14458 > Add virtual table to list active connections > > > Key: CASSANDRA-14458 > URL: https://issues.apache.org/jira/browse/CASSANDRA-14458 > Project: Cassandra > Issue Type: New Feature >Reporter: Chris Lohfink >Assignee: Chris Lohfink >Priority: Minor > > List all active connections in virtual table like: > {code:sql} > cqlsh:system> select * from system_views.clients ; > > client_address | cipher | driver_name | driver_version | keyspace | > protocol | requests | ssl | user | version > --+---+-++--+---+--+---+---+- > /127.0.0.1:63903 | undefined | undefined | undefined | | > undefined | 13 | False | anonymous | 4 > /127.0.0.1:63904 | undefined | undefined | undefined | system | > undefined | 16 | False | anonymous | 4 > {code} -- This message was sent by Atlassian JIRA (v7.6.3#76005) - To unsubscribe, e-mail: commits-unsubscr...@cassandra.apache.org For additional commands, e-mail: commits-h...@cassandra.apache.org
[jira] [Updated] (CASSANDRA-14458) Add virtual table to list active connections
[ https://issues.apache.org/jira/browse/CASSANDRA-14458?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Chris Lohfink updated CASSANDRA-14458: -- Description: List all active connections in virtual table like: {code:sql} cqlsh:system> select * from system_views.clients ; client_address | cipher | driver_name | driver_version | keyspace | protocol | requests | ssl | user | version --+---+-++--+---+--+---+---+- /127.0.0.1:63903 | undefined | undefined | undefined | | undefined | 13 | False | anonymous | 4 /127.0.0.1:63904 | undefined | undefined | undefined | system | undefined | 16 | False | anonymous | 4 {code} was: List all active connections in virtual table like: {code:sql} cassandra_maint@cqlsh:system> select * from system_views.clients ; client_address | cipher | driver_name | driver_version | keyspace | protocol | requests | ssl | user | version --+---+-++--+---+--+---+---+- /127.0.0.1:63903 | undefined | undefined | undefined | | undefined | 13 | False | anonymous | 4 /127.0.0.1:63904 | undefined | undefined | undefined | system | undefined | 16 | False | anonymous | 4 {code} > Add virtual table to list active connections > > > Key: CASSANDRA-14458 > URL: https://issues.apache.org/jira/browse/CASSANDRA-14458 > Project: Cassandra > Issue Type: New Feature >Reporter: Chris Lohfink >Assignee: Chris Lohfink >Priority: Minor > > List all active connections in virtual table like: > {code:sql} > cqlsh:system> select * from system_views.clients ; > > client_address | cipher | driver_name | driver_version | keyspace | > protocol | requests | ssl | user | version > --+---+-++--+---+--+---+---+- > /127.0.0.1:63903 | undefined | undefined | undefined | | > undefined | 13 | False | anonymous | 4 > /127.0.0.1:63904 | undefined | undefined | undefined | system | > undefined | 16 | False | anonymous | 4 > {code} -- This message was sent by Atlassian JIRA (v7.6.3#76005) - To unsubscribe, e-mail: commits-unsubscr...@cassandra.apache.org For additional commands, e-mail: commits-h...@cassandra.apache.org
[jira] [Updated] (CASSANDRA-14458) Add virtual table to list active connections
[ https://issues.apache.org/jira/browse/CASSANDRA-14458?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Chris Lohfink updated CASSANDRA-14458: -- Description: List all active connections in virtual table like: {code:sql} cassandra_maint@cqlsh:system> select * from system_views.clients ; client_address | cipher | driver_name | driver_version | keyspace | protocol | requests | ssl | user | version --+---+-++--+---+--+---+---+- /127.0.0.1:63903 | undefined | undefined | undefined | | undefined | 13 | False | anonymous | 4 /127.0.0.1:63904 | undefined | undefined | undefined | system | undefined | 16 | False | anonymous | 4 {code} > Add virtual table to list active connections > > > Key: CASSANDRA-14458 > URL: https://issues.apache.org/jira/browse/CASSANDRA-14458 > Project: Cassandra > Issue Type: New Feature >Reporter: Chris Lohfink >Assignee: Chris Lohfink >Priority: Minor > > List all active connections in virtual table like: > {code:sql} > cassandra_maint@cqlsh:system> select * from system_views.clients ; > > client_address | cipher | driver_name | driver_version | keyspace | > protocol | requests | ssl | user | version > --+---+-++--+---+--+---+---+- > /127.0.0.1:63903 | undefined | undefined | undefined | | > undefined | 13 | False | anonymous | 4 > /127.0.0.1:63904 | undefined | undefined | undefined | system | > undefined | 16 | False | anonymous | 4 > {code} -- This message was sent by Atlassian JIRA (v7.6.3#76005) - To unsubscribe, e-mail: commits-unsubscr...@cassandra.apache.org For additional commands, e-mail: commits-h...@cassandra.apache.org
[jira] [Created] (CASSANDRA-14458) Add virtual table to list active connections
Chris Lohfink created CASSANDRA-14458: - Summary: Add virtual table to list active connections Key: CASSANDRA-14458 URL: https://issues.apache.org/jira/browse/CASSANDRA-14458 Project: Cassandra Issue Type: New Feature Reporter: Chris Lohfink Assignee: Chris Lohfink -- This message was sent by Atlassian JIRA (v7.6.3#76005) - To unsubscribe, e-mail: commits-unsubscr...@cassandra.apache.org For additional commands, e-mail: commits-h...@cassandra.apache.org