Technoboy- opened a new issue, #16858: URL: https://github.com/apache/pulsar/issues/16858
LedgerOffloaderMetricsTest.cleanup is flaky. It fails sporadically. ### Failure CI https://github.com/apache/pulsar/runs/7562071273?check_suite_focus=true ### StackTrace ``` Error: Tests run: 6, Failures: 2, Errors: 0, Skipped: 3, Time elapsed: 10.064 s <<< FAILURE! - in org.apache.pulsar.broker.stats.LedgerOffloaderMetricsTest Error: cleanup(org.apache.pulsar.broker.stats.LedgerOffloaderMetricsTest) Time elapsed: 3.515 s <<< FAILURE! org.mockito.exceptions.misusing.WrongTypeOfReturnValue: BrokerService cannot be returned by getBrokerServiceUrl() getBrokerServiceUrl() should return String *** If you're unsure why you're getting above error read on. Due to the nature of the syntax above problem might occur because: 1. This exception *might* occur in wrongly written multi-threaded tests. Please refer to Mockito FAQ on limitations of concurrency testing. 2. A spy is stubbed using when(spy.foo()).then() syntax. It is safer to stub spies - - with doReturn|Throw() family of methods. More in javadocs for Mockito.spy() method. at org.apache.pulsar.broker.PulsarService.getBrokerServiceUrl(PulsarService.java:227) at org.apache.pulsar.broker.auth.MockedPulsarServiceBaseTest.stopBroker(MockedPulsarServiceBaseTest.java:296) at org.apache.pulsar.broker.auth.MockedPulsarServiceBaseTest.internalCleanup(MockedPulsarServiceBaseTest.java:239) at org.apache.pulsar.broker.stats.LedgerOffloaderMetricsTest.cleanup(LedgerOffloaderMetricsTest.java:57) ``` -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
