[ 
https://issues.apache.org/jira/browse/CASSANDRA-17302?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17726378#comment-17726378
 ] 

Brandon Williams commented on CASSANDRA-17302:
----------------------------------------------

This is actually a timeout (which explains why both instances were on jenkins) 
but the code is trying to be helpful and already catches timeouts, trying to 
improve the error returned later, but sometimes there is no error, it's just a 
timeout, and that results in the assertion above.  I have reworked this to 
catch the case of a timeout and nothing else to rethrow a timeout error 
explaining what happened 
[here|https://github.com/driftx/cassandra-dtest/commit/aeed07944cad3070b515395ca7560c333623aab5]
 and multiplexed the test 
[here|https://app.circleci.com/pipelines/github/driftx/cassandra/1028/workflows/2c56fe0f-37e7-48f2-b563-73772275b6dd/jobs/26975]
 but unfortunately never hit a timeout.



> Test Failure: 
> dtest-offheap.topology_test.TestTopology.test_decommissioned_node_cant_rejoin
> -------------------------------------------------------------------------------------------
>
>                 Key: CASSANDRA-17302
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-17302
>             Project: Cassandra
>          Issue Type: Bug
>          Components: Test/dtest/python
>            Reporter: Josh McKenzie
>            Assignee: Brandon Williams
>            Priority: Normal
>             Fix For: 5.x
>
>
> https://ci-cassandra.apache.org/job/Cassandra-4.0/317/testReport/dtest-offheap.topology_test/TestTopology/test_decommissioned_node_cant_rejoin/
> Failed 1 times in the last 20 runs. Flakiness: 5%, Stability: 95%
> Error Message
> AssertionError: assert None  +  where None = <function search at 
> 0x7f0de9492c10>('This node was decommissioned and will not rejoin the ring', 
> '', re.MULTILINE)  +    where <function search at 0x7f0de9492c10> = re.search 
>  +    and   '' = <built-in method join of str object at 0x7f0de963b4b0>([])  
> +      where <built-in method join of str object at 0x7f0de963b4b0> = 
> '\n'.join  +    and   re.MULTILINE = re.MULTILINE
> {code}
> Stacktrace
> self = <topology_test.TestTopology object at 0x7f0de5899430>
>     @since('3.0')
>     def test_decommissioned_node_cant_rejoin(self):
>         """
>             @jira_ticket CASSANDRA-8801
>     
>             Test that a decommissioned node can't rejoin the cluster by:
>     
>             - creating a cluster,
>             - decommissioning a node, and
>             - asserting that the "decommissioned node won't rejoin" error is 
> in the
>             logs for that node and
>             - asserting that the node is not running.
>             """
>         rejoin_err = 'This node was decommissioned and will not rejoin the 
> ring'
>         self.fixture_dtest_setup.ignore_log_patterns = 
> list(self.fixture_dtest_setup.ignore_log_patterns) + [
>             rejoin_err]
>     
>         self.cluster.populate(3).start()
>         node1, node2, node3 = self.cluster.nodelist()
>     
>         logger.debug('decommissioning...')
>         node3.decommission(force=self.cluster.version() >= '4.0')
>         logger.debug('stopping...')
>         node3.stop()
>         logger.debug('attempting restart...')
>         node3.start(wait_other_notice=False)
>         try:
>             # usually takes 3 seconds, so give it a generous 15
>             node3.watch_log_for(rejoin_err, timeout=15)
>         except TimeoutError:
>             # TimeoutError is not very helpful to the reader of the test 
> output;
>             # let that pass and move on to string assertion below
>             pass
>     
> >       assert re.search(rejoin_err,
>                          '\n'.join(['\n'.join(err_list) for err_list in 
> node3.grep_log_for_errors()]), re.MULTILINE)
> E       AssertionError: assert None
> E        +  where None = <function search at 0x7f0de9492c10>('This node was 
> decommissioned and will not rejoin the ring', '', re.MULTILINE)
> E        +    where <function search at 0x7f0de9492c10> = re.search
> E        +    and   '' = <built-in method join of str object at 
> 0x7f0de963b4b0>([])
> E        +      where <built-in method join of str object at 0x7f0de963b4b0> 
> = '\n'.join
> E        +    and   re.MULTILINE = re.MULTILINE
> topology_test.py:416: AssertionError
> {code}



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to