From commits-return-226404-archive-asf-public=cust-asf.ponee.io@cassandra.apache.org Thu Jan 30 21:06:03 2020 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [207.244.88.153]) by mx-eu-01.ponee.io (Postfix) with SMTP id 683AF180667 for ; Thu, 30 Jan 2020 22:06:03 +0100 (CET) Received: (qmail 30400 invoked by uid 500); 30 Jan 2020 21:06:02 -0000 Mailing-List: contact commits-help@cassandra.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cassandra.apache.org Delivered-To: mailing list commits@cassandra.apache.org Received: (qmail 30382 invoked by uid 99); 30 Jan 2020 21:06:02 -0000 Received: from mailrelay1-us-west.apache.org (HELO mailrelay1-us-west.apache.org) (209.188.14.139) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 30 Jan 2020 21:06:02 +0000 Received: from jira-he-de.apache.org (static.172.67.40.188.clients.your-server.de [188.40.67.172]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id 278BAE309A for ; Thu, 30 Jan 2020 21:06:00 +0000 (UTC) Received: from jira-he-de.apache.org (localhost.localdomain [127.0.0.1]) by jira-he-de.apache.org (ASF Mail Server at jira-he-de.apache.org) with ESMTP id 5E2B5780403 for ; Thu, 30 Jan 2020 21:06:00 +0000 (UTC) Date: Thu, 30 Jan 2020 21:06:00 +0000 (UTC) From: "Ekaterina Dimitrova (Jira)" To: commits@cassandra.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Updated] (CASSANDRA-15311) Fix flakey test_13595 - consistency_test.TestConsistency MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/CASSANDRA-15311?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Ekaterina Dimitrova updated CASSANDRA-15311: -------------------------------------------- Attachment: CASSANDRA-15311.txt > Fix flakey test_13595 - consistency_test.TestConsistency > --------------------------------------------------------- > > Key: CASSANDRA-15311 > URL: https://issues.apache.org/jira/browse/CASSANDRA-15311 > Project: Cassandra > Issue Type: Bug > Components: Test/dtest > Reporter: Joey Lynch > Assignee: Ekaterina Dimitrova > Priority: Normal > Fix For: 4.0-alpha > > Attachments: CASSANDRA-15311.txt > > > Example failure: [https://circleci.com/gh/jolynch/cassandra/559#tests/containers/29] > {noformat} > Your job ran 1007 tests with 1 failure > test_13595 - consistency_test.TestConsistencyconsistency_test.pyAssertionError: assert 9 == 4 + where 4 = >('org.apache.cassandra.metrics:type=Table,name=ShortReadProtectionRequests,keyspace=test,scope=test', 'Count') + where > = .read_attribute > self = > @since('3.0') > def test_13595(self): > """ > @jira_ticket CASSANDRA-13595 > """ > cluster = self.cluster > > # disable hinted handoff and set batch commit log so this doesn't interfere with the test > cluster.set_configuration_options(values={'hinted_handoff_enabled': False}) > cluster.set_batch_commitlog(enabled=True) > > cluster.populate(2) > node1, node2 = cluster.nodelist() > remove_perf_disable_shared_mem(node1) # necessary for jmx > cluster.start(wait_other_notice=True) > > session = self.patient_cql_connection(node1) > > query = "CREATE KEYSPACE IF NOT EXISTS test WITH replication = {'class': 'NetworkTopologyStrategy', 'datacenter1': 2};" > session.execute(query) > > query = 'CREATE TABLE IF NOT EXISTS test.test (id int PRIMARY KEY);' > session.execute(query) > > # populate the table with 10 partitions, > # then delete a bunch of them on different nodes > # until we get the following pattern: > > # token | k | 1 | 2 | > # -7509452495886106294 | 5 | n | y | > # -4069959284402364209 | 1 | y | n | > # -3799847372828181882 | 8 | n | y | > # -3485513579396041028 | 0 | y | n | > # -3248873570005575792 | 2 | n | y | > # -2729420104000364805 | 4 | y | n | > # 1634052884888577606 | 7 | n | y | > # 2705480034054113608 | 6 | y | n | > # 3728482343045213994 | 9 | n | y | > # 9010454139840013625 | 3 | y | y | > > stmt = session.prepare('INSERT INTO test.test (id) VALUES (?);') > for id in range(0, 10): > session.execute(stmt, [id], ConsistencyLevel.ALL) > > # delete every other partition on node1 while node2 is down > node2.stop(wait_other_notice=True) > session.execute('DELETE FROM test.test WHERE id IN (5, 8, 2, 7, 9);') > node2.start(wait_other_notice=True, wait_for_binary_proto=True) > > session = self.patient_cql_connection(node2) > > # delete every other alternate partition on node2 while node1 is down > node1.stop(wait_other_notice=True) > session.execute('DELETE FROM test.test WHERE id IN (1, 0, 4, 6);') > node1.start(wait_other_notice=True, wait_for_binary_proto=True) > > session = self.patient_exclusive_cql_connection(node1) > > # until #13595 the query would incorrectly return [1] > assert_all(session, > 'SELECT id FROM test.test LIMIT 1;', > [[3]], > cl=ConsistencyLevel.ALL) > > srp = make_mbean('metrics', type='Table', name='ShortReadProtectionRequests', keyspace='test', scope='test') > with JolokiaAgent(node1) as jmx: > # 4 srp requests for node1 and 5 for node2, total of 9 > > assert 9 == jmx.read_attribute(srp, 'Count') > E AssertionError: assert 9 == 4 > E + where 4 = >('org.apache.cassandra.metrics:type=Table,name=ShortReadProtectionRequests,keyspace=test,scope=test', 'Count') > E + where > = .read_attribute > consistency_test.py:1288: AssertionError {noformat} -- This message was sent by Atlassian Jira (v8.3.4#803005) --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscribe@cassandra.apache.org For additional commands, e-mail: commits-help@cassandra.apache.org