apache / pulsar

Apache Pulsar - distributed pub-sub messaging system
https://pulsar.apache.org/
Apache License 2.0
14.23k stars 3.58k forks source link

Flaky-test: testSplitBundleForMultiTimes #16561

Closed gaozhangmin closed 2 years ago

gaozhangmin commented 2 years ago

https://github.com/apache/pulsar/runs/7313687530?check_suite_focus=true

Error:  testSplitBundleForMultiTimes(org.apache.pulsar.broker.admin.NamespacesTest)  Time elapsed: 0.076 s  <<< FAILURE!
  org.apache.pulsar.client.admin.PulsarAdminException$PreconditionFailedException: Failed to find ownership for ServiceUnit:my-tenant/namespace-f70aa263-a68f-4b45-8c13-fa1a826a6126/0x00000000_0x40000000
    at org.apache.pulsar.client.admin.PulsarAdminException.wrap(PulsarAdminException.java:252)
    at org.apache.pulsar.client.admin.internal.BaseResource.sync(BaseResource.java:302)
    at org.apache.pulsar.client.admin.internal.NamespacesImpl.splitNamespaceBundle(NamespacesImpl.java:1156)
    at org.apache.pulsar.client.admin.internal.NamespacesImpl.splitNamespaceBundle(NamespacesImpl.java:1143)
    at org.apache.pulsar.broker.admin.NamespacesTest.testSplitBundleForMultiTimes(NamespacesTest.java:1833)
    at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
    at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.base/java.lang.reflect.Method.invoke(Method.java:568)
    at org.testng.internal.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:132)
    at org.testng.internal.InvokeMethodRunnable.runOne(InvokeMethodRunnable.java:45)
    at org.testng.internal.InvokeMethodRunnable.call(InvokeMethodRunnable.java:73)
    at org.testng.internal.InvokeMethodRunnable.call(InvokeMethodRunnable.java:11)
    at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
    at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
    at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
    at java.base/java.lang.Thread.run(Thread.java:833)
    Suppressed: org.apache.pulsar.client.admin.PulsarAdminException$PreconditionFailedException: Failed to find ownership for ServiceUnit:my-tenant/namespace-f70aa263-a68f-4b45-8c13-fa1a826a6126/0x00000000_0x40000000
        at org.apache.pulsar.client.admin.internal.BaseResource.getApiException(BaseResource.java:240)
        at org.apache.pulsar.client.admin.internal.BaseResource$1.failed(BaseResource.java:134)
        at org.glassfish.jersey.client.JerseyInvocation$1.failed(JerseyInvocation.java:882)
        at org.glassfish.jersey.client.JerseyInvocation$1.completed(JerseyInvocation.java:863)
        at org.glassfish.jersey.client.ClientRuntime.processResponse(ClientRuntime.java:229)
        at org.glassfish.jersey.client.ClientRuntime.access$200(ClientRuntime.java:62)
        at org.glassfish.jersey.client.ClientRuntime$2.lambda$response$0(ClientRuntime.java:173)
        at org.glassfish.jersey.internal.Errors$1.call(Errors.java:248)
        at org.glassfish.jersey.internal.Errors$1.call(Errors.java:244)
        at org.glassfish.jersey.internal.Errors.process(Errors.java:292)
        at org.glassfish.jersey.internal.Errors.process(Errors.java:274)
        at org.glassfish.jersey.internal.Errors.process(Errors.java:244)
        at org.glassfish.jersey.process.internal.RequestScope.runInScope(RequestScope.java:288)
        at org.glassfish.jersey.client.ClientRuntime$2.response(ClientRuntime.java:173)
        at org.apache.pulsar.client.admin.internal.http.AsyncHttpConnector.lambda$apply$1(AsyncHttpConnector.java:242)
        at java.base/java.util.concurrent.CompletableFuture.uniWhenComplete(CompletableFuture.java:863)
        at java.base/java.util.concurrent.CompletableFuture$UniWhenComplete.tryFire(CompletableFuture.java:841)
        at java.base/java.util.concurrent.CompletableFuture.postComplete(CompletableFuture.java:510)
        at java.base/java.util.concurrent.CompletableFuture.complete(CompletableFuture.java:2147)
        at org.apache.pulsar.client.admin.internal.http.AsyncHttpConnector.lambda$retryOperation$4(AsyncHttpConnector.java:284)
        at java.base/java.util.concurrent.CompletableFuture.uniWhenComplete(CompletableFuture.java:863)
        at java.base/java.util.concurrent.CompletableFuture$UniWhenComplete.tryFire(CompletableFuture.java:841)
        at java.base/java.util.concurrent.CompletableFuture.postComplete(CompletableFuture.java:510)
        at java.base/java.util.concurrent.CompletableFuture.complete(CompletableFuture.java:2147)
        at org.asynchttpclient.netty.NettyResponseFuture.loadContent(NettyResponseFuture.java:222)
        at org.asynchttpclient.netty.NettyResponseFuture.done(NettyResponseFuture.java:257)
        at org.asynchttpclient.netty.handler.AsyncHttpClientHandler.finishUpdate(AsyncHttpClientHandler.java:241)
        at org.asynchttpclient.netty.handler.HttpHandler.handleChunk(HttpHandler.java:114)
        at org.asynchttpclient.netty.handler.HttpHandler.handleRead(HttpHandler.java:143)
        at org.asynchttpclient.netty.handler.AsyncHttpClientHandler.channelRead(AsyncHttpClientHandler.java:78)
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
        at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357)
        at io.netty.handler.codec.MessageToMessageDecoder.channelRead(MessageToMessageDecoder.java:103)
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
        at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357)
        at io.netty.channel.CombinedChannelDuplexHandler$DelegatingChannelHandlerContext.fireChannelRead(CombinedChannelDuplexHandler.java:436)
        at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:327)
        at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:299)
        at io.netty.channel.CombinedChannelDuplexHandler.channelRead(CombinedChannelDuplexHandler.java:251)
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
        at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357)
        at io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1410)
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379)
        at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365)
        at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:919)
        at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:166)
        at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:722)
        at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:658)
        at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:584)
        at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:496)
        at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:995)
        at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74)
        at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30)
        ... 1 more
    Caused by: javax.ws.rs.ClientErrorException: HTTP 412 Failed to find ownership for ServiceUnit:my-tenant/namespace-f70aa263-a68f-4b45-8c13-fa1a826a6126/0x00000000_0x40000000
        at org.glassfish.jersey.client.JerseyInvocation.createExceptionForFamily(JerseyInvocation.java:985)
        at org.glassfish.jersey.client.JerseyInvocation.convertToException(JerseyInvocation.java:967)
        at org.glassfish.jersey.client.JerseyInvocation.access$700(JerseyInvocation.java:82)
        ... 54 more
  Caused by: [CIRCULAR REFERENCE: javax.ws.rs.ClientErrorException: HTTP 412 Failed to find ownership for ServiceUnit:my-tenant/namespace-f70aa263-a68f-4b45-8c13-fa1a826a6126/0x00000000_0x40000000]
shibd commented 2 years ago

another: https://github.com/apache/pulsar/actions/runs/3217598688/jobs/5262602586

coderzc commented 2 years ago

another one: https://github.com/apache/pulsar/actions/runs/3223890093/jobs/5274562783#step:10:788

lhotari commented 2 years ago

again: https://github.com/lhotari/pulsar/actions/runs/3226330147/jobs/5279887104#step:10:798

@Technoboy- would you mind taking a look since this doesn't seem to be fixed.

Technoboy- commented 2 years ago

again: https://github.com/lhotari/pulsar/actions/runs/3226330147/jobs/5279887104#step:10:798

@Technoboy- would you mind taking a look since this doesn't seem to be fixed.

Fixed by https://github.com/apache/pulsar/pull/17993