googleapis / googleapis/google-cloud-java
[java-pubsub] PublisherImplTest.testResumePublish hangs
- Lingua principale
- Java
- Stelle
- 2.1k
- Fork
- 1.2k
- Merge medio
- 1g 23h
- PR unite (30g)
- 154
Descrizione
In the release PR run https://github.com/googleapis/google-cloud-java/actions/runs/27152757144/job/80148008212?pr=13373, the unit test `PublisherImplTest` in `google-cloud-pubsub` module got stuck and caused the GHA run to timeout after 6 hours.
Analyzing the job logs of previous timed-out release runs (e.g. https://github.com/googleapis/google-cloud-java/actions/runs/27024407145), the hang consistently occurs inside `com.google.cloud.pubsub.v1.PublisherImplTest` when running on Java 8 runtime.
Specifically, the `testResumePublish` test case invokes `sendTestMessageWithOrderingKey` which triggers a publish call to the mock server `FakePublisherServiceImpl`. Inside `FakePublisherServiceImpl.publish()`, it calls `publishResponses.take()`, which is a blocking queue call. In Java 8 runtime, this blocks the main thread, resulting in a deadlock before `testPublisherServiceImpl.addPublishResponse(...)` can be called.
This test was previously disabled due to similar timeout issues (Issue #13051) but was recently re-enabled. We need to investigate why it deadlocks under Java 8 and prevent it from hanging.
Guida per i contributori
Apri la guida per i contributori
Valutazione
Questa issue non è ancora stata valutata.