[Failing Test]: JmsIOTest. testCheckpointMark flaky

Open Beginner friendly
#30,225 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
68/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Quiet
Tech stack
java
Domain
testing

Research direction

Start with JmsIOTest.java at testCheckpointMark around line 463, then read JmsIO.java around the consumer.receiveNoWait call at line 559. Run the focused JmsIOTest and reproduce the failure if possible. Done means the checkpoint test no longer flakes when unacked messages remain, while still verifying the intended checkpoint behavior.

Written by the indexing model from the issue text.

Description

bug failing test flake P2 pinned tests
What happened?

Example run: https://github.com/apache/beam/runs/21250090063 (an PR unrelated to Jms):

java.lang.AssertionError
	at org.junit.Assert.fail(Assert.java:87)
	at org.junit.Assert.assertTrue(Assert.java:42)
	at org.junit.Assert.assertTrue(Assert.java:53)
	at org.apache.beam.sdk.io.jms.JmsIOTest.testCheckpointMark(JmsIOTest.java:463)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

Fails at here: https://github.com/apache/beam/blob/d5aa44c9ba9eb910774d789dd4182a5d25d8f552/sdks/java/io/jms/src/test/java/org/apache/beam/sdk/io/jms/JmsIOTest.java#L463

In fact, consumer.receiveNoWait call at https://github.com/apache/beam/blob/d5aa44c9ba9eb910774d789dd4182a5d25d8f552/sdks/java/io/jms/src/main/java/org/apache/beam/sdk/io/jms/JmsIO.java#L559
never guarantees a message will be returned when there are still unacked message on the server: https://stackoverflow.com/questions/36626634/does-jms-receivenowait-guarantee-message-delivery-when-messages-are-available

So there is a chance that the call returns null and fails assert

Issue Failure

Failure: Test is flaky

Issue Priority

Priority: 2 (backlog / disabled test but we think the product is healthy)

Issue Components
  • Component: Python SDK
  • Component: Java SDK
  • Component: Go SDK
  • Component: Typescript SDK
  • Component: IO connector
  • Component: Beam YAML
  • Component: Beam examples
  • Component: Beam playground
  • Component: Beam katas
  • Component: Website
  • Component: Spark Runner
  • Component: Flink Runner
  • Component: Samza Runner
  • Component: Twister2 Runner
  • Component: Hazelcast Jet Runner
  • Component: Google Cloud Dataflow Runner
Dominant language
Java
Stars
8.7k
Forks
4.7k
Avg merge
2d 6h
Merged PRs (30d)
194

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from apache/beam

All issues in apache/beam

Similar issues

More Java issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.