You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by GitBox <gi...@apache.org> on 2021/12/30 07:37:59 UTC

[GitHub] [pulsar] 315157973 opened a new issue #13570: Flaky-test: PersistentTopicTest.setup

315157973 opened a new issue #13570:
URL: https://github.com/apache/pulsar/issues/13570


   
   PersistentTopicTest is flaky. The setup() test method fails sporadically.
   
   ```
   2021-12-30T14:52:26,643+0800 [metadata-store-772-1] ERROR org.apache.pulsar.metadata.impl.AbstractMetadataStore - Failed to process metadata store notification
   org.mockito.exceptions.misusing.WrongTypeOfReturnValue: 
   BrokerService$MockitoMock$699853984 cannot be returned by getPulsarResources()
   getPulsarResources() should return PulsarResources
   ***
   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.service.BrokerService.handleMetadataChanges(BrokerService.java:1908) ~[classes/:?]
   	at org.apache.pulsar.metadata.impl.AbstractMetadataStore.lambda$receivedNotification$0(AbstractMetadataStore.java:186) ~[classes/:?]
   	at java.util.concurrent.CopyOnWriteArrayList.forEach(CopyOnWriteArrayList.java:807) ~[?:?]
   	at org.apache.pulsar.metadata.impl.AbstractMetadataStore.lambda$receivedNotification$1(AbstractMetadataStore.java:184) ~[classes/:?]
   	at java.util.concurrent.CompletableFuture$AsyncSupply.run(CompletableFuture.java:1700) [?:?]
   	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515) [?:?]
   	at java.util.concurrent.FutureTask.run(FutureTask.java:264) [?:?]
   	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:304) [?:?]
   	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) [?:?]
   	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) [?:?]
   	at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30) [netty-common-4.1.72.Final.jar:4.1.72.Final]
   	at java.lang.Thread.run(Thread.java:834) [?:?]
   2021-12-30T14:52:26,643+0800 [metadata-store-772-1] ERROR org.apache.pulsar.metadata.impl.AbstractMetadataStore - Failed to process metadata store notification
   java.lang.ClassCastException: class org.apache.pulsar.broker.service.BrokerService$MockitoMock$699853984 cannot be cast to class org.apache.pulsar.broker.resources.PulsarResources (org.apache.pulsar.broker.service.BrokerService$MockitoMock$699853984 and org.apache.pulsar.broker.resources.PulsarResources are in unnamed module of loader 'app')
   	at org.apache.pulsar.broker.PulsarService$MockitoMock$543976714.getPulsarResources(Unknown Source) ~[classes/:?]
   	at org.apache.pulsar.broker.service.BrokerService.handleMetadataChanges(BrokerService.java:1908) ~[classes/:?]
   	at org.apache.pulsar.metadata.impl.AbstractMetadataStore.lambda$receivedNotification$0(AbstractMetadataStore.java:186) ~[classes/:?]
   	at java.util.concurrent.CopyOnWriteArrayList.forEach(CopyOnWriteArrayList.java:807) ~[?:?]
   	at org.apache.pulsar.metadata.impl.AbstractMetadataStore.lambda$receivedNotification$1(AbstractMetadataStore.java:184) ~[classes/:?]
   	at java.util.concurrent.CompletableFuture$AsyncSupply.run(CompletableFuture.java:1700) [?:?]
   	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515) [?:?]
   	at java.util.concurrent.FutureTask.run(FutureTask.java:264) [?:?]
   	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:304) [?:?]
   	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) [?:?]
   	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) [?:?]
   	at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30) [netty-common-4.1.72.Final.jar:4.1.72.Final]
   	at java.lang.Thread.run(Thread.java:834) [?:?]
   
   java.lang.NullPointerException
   	at org.apache.pulsar.broker.service.ServerCnx.<init>(ServerCnx.java:233)
   	at org.apache.pulsar.broker.service.ServerCnx.<init>(ServerCnx.java:229)
   	at org.apache.pulsar.broker.service.PersistentTopicTest.setup(PersistentTopicTest.java:209)
   	at jdk.internal.reflect.GeneratedMethodAccessor34.invoke(Unknown Source)
   	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
   	at java.base/java.lang.reflect.Method.invoke(Method.java:566)
   	at org.testng.internal.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:132)
   	at org.testng.internal.MethodInvocationHelper.invokeMethodConsideringTimeout(MethodInvocationHelper.java:61)
   	at org.testng.internal.ConfigInvoker.invokeConfigurationMethod(ConfigInvoker.java:366)
   	at org.testng.internal.ConfigInvoker.invokeConfigurations(ConfigInvoker.java:320)
   	at org.testng.internal.TestInvoker.runConfigMethods(TestInvoker.java:701)
   	at org.testng.internal.TestInvoker.invokeMethod(TestInvoker.java:527)
   	at org.testng.internal.TestInvoker.invokeTestMethod(TestInvoker.java:174)
   	at org.testng.internal.MethodRunner.runInSequence(MethodRunner.java:46)
   	at org.testng.internal.TestInvoker$MethodInvocationAgent.invoke(TestInvoker.java:822)
   	at org.testng.internal.TestInvoker.invokeTestMethods(TestInvoker.java:147)
   	at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:146)
   	at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:128)
   	at java.base/java.util.ArrayList.forEach(ArrayList.java:1541)
   	at org.testng.TestRunner.privateRun(TestRunner.java:764)
   	at org.testng.TestRunner.run(TestRunner.java:585)
   	at org.testng.SuiteRunner.runTest(SuiteRunner.java:384)
   	at org.testng.SuiteRunner.runSequentially(SuiteRunner.java:378)
   	at org.testng.SuiteRunner.privateRun(SuiteRunner.java:337)
   	at org.testng.SuiteRunner.run(SuiteRunner.java:286)
   	at org.testng.SuiteRunnerWorker.runSuite(SuiteRunnerWorker.java:53)
   	at org.testng.SuiteRunnerWorker.run(SuiteRunnerWorker.java:96)
   	at org.testng.TestNG.runSuitesSequentially(TestNG.java:1218)
   	at org.testng.TestNG.runSuitesLocally(TestNG.java:1140)
   	at org.testng.TestNG.runSuites(TestNG.java:1069)
   	at org.testng.TestNG.run(TestNG.java:1037)
   	at com.intellij.rt.testng.IDEARemoteTestNG.run(IDEARemoteTestNG.java:66)
   	at com.intellij.rt.testng.RemoteTestNGStarter.main(RemoteTestNGStarter.java:109)
   
   ```
   


-- 
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: commits-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] lhotari commented on issue #13570: Flaky-test: PersistentTopicTest.setup

Posted by GitBox <gi...@apache.org>.
lhotari commented on issue #13570:
URL: https://github.com/apache/pulsar/issues/13570#issuecomment-1004924342


   similar issue here https://github.com/apache/pulsar/runs/4702786621?check_suite_focus=true#step:9:557


-- 
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: commits-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] lhotari commented on issue #13570: Flaky-test: PersistentTopicTest.setup

Posted by GitBox <gi...@apache.org>.
lhotari commented on issue #13570:
URL: https://github.com/apache/pulsar/issues/13570#issuecomment-1004944848


   attempt to fix this issue: #13608 , @315157973  please review


-- 
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: commits-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar] lhotari closed issue #13570: Flaky-test: PersistentTopicTest.setup

Posted by GitBox <gi...@apache.org>.
lhotari closed issue #13570:
URL: https://github.com/apache/pulsar/issues/13570


   


-- 
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: commits-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org