You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Bug] ArrayIndexOutOfBoundsException caused by optimistic locking in ConcurrentLongLongPairHashMap implementation #18388
I searched in the issues and found nothing similar.
Version
latest.
Minimal reproduce step
ConcurrentLongLongPairHashMap use optimistic locking to read data in Section, but if there is another thread that is removing data from the same Section, and trigger the shrink process, then the index calculated basing on dirty capacity exceed the array size, an ArrayIndexOut0fBoundsException will be throw, which is not handled now. Eventually the connection with client will be closed.
What did you expect to see?
,
What did you see instead?
WARN org.apache.pulsar.broker.service.Servernx-[] Got exception, cause: java.lang.ArrayIndexOut0fBoundsException: Index 6821 out of bounds for length 4
096, stackTrace: java.lang.ArrayIndexOutOfBoundsException: Index 6821 out of bounds for length 4096
atorg.apache.pulsar.common.util.collections.ConcurrentLongLongPairHashMap$Section.get(ConcurrentLongLongPairHashMap.java:331)
atorg.apache.pulsar.common.util.collections.ConcurrentLongLongPairHashMap.get(ConcurrentLongLongPairHashMap.java:204)
at org.apache.pulsar.common.util.collections.ConcurrentLongLongPairHashMap.containsKey(ConcurrentLongLongPairHashMap.java:208)
at org.apache.pulsar.broker.service.Consumer.getAckOwnerConsumer(Consumer.java:596)
at org.apache.pulsar.broker.service.Consumer.individualAckNormal(Consumer.java:408)
at org.apache.pulsar.broker.service.Consumer.messageAcked(Consumer.java:395)
at org.apache.pulsar .broker .service.ServerCnx.handleAck(Server(nx.java:1456)
at org.apache.pulsar.common.protocol.PulsarDecoder.channelRead(PulsarDecoder.java:145)
Activity
github-actions commentedon Dec 9, 2022
The issue had no activity for 30 days, mark with Stale label.
[FLINK-25530][python][connectors/pulsar] Support Pulsar source connec…