Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Flaky-Test]: A test in the java OPC-UA driver is continuously breaking builds. #1764

Open
2 of 16 tasks
chrisdutz opened this issue Sep 16, 2024 · 4 comments
Open
2 of 16 tasks
Assignees
Labels
bug flaky test Indicates this issue relates to disabled tests, that cause the build to fail at random java Pull requests that update Java code OPC-UA https://plc4x.apache.org/users/protocols/opcua.html

Comments

@chrisdutz
Copy link
Contributor

What happened?

The test OpcuaPlcDriverTest.multipleThreads in the java opc-ua driver testsuite is regularly failing the CI/CD builds ... re-runing them usually resolves the issue, however we can't have test break the builds at random.

Version

v0.13.0-SNAPSHOT

Programming Languages

  • plc4j
  • plc4go
  • plc4c
  • plc4net

Protocols

  • AB-Ethernet
  • ADS /AMS
  • BACnet/IP
  • CANopen
  • DeltaV
  • DF1
  • EtherNet/IP
  • Firmata
  • KNXnet/IP
  • Modbus
  • OPC-UA
  • S7
@chrisdutz chrisdutz added bug flaky test Indicates this issue relates to disabled tests, that cause the build to fail at random labels Sep 16, 2024
@ottlukas ottlukas added java Pull requests that update Java code OPC-UA https://plc4x.apache.org/users/protocols/opcua.html labels Sep 16, 2024
@splatch splatch self-assigned this Sep 16, 2024
@splatch
Copy link
Contributor

splatch commented Sep 16, 2024

I'll take a look on these and the end of week or early next. I hoped that testcontainers would help us a bit with this issue, but there still seem to be a problem.

@chrisdutz
Copy link
Contributor Author

Admittedly I think the issue lies with milo and it therefore doesn't really matter how you start it ... but admittedly I didn't look too deep into the issue.

@chrisdutz
Copy link
Contributor Author

org.apache.plc4x.java.opcua.protocol.chunk.ChunkFactoryTest also seems to continuously break builds (all values seem to be off by 1)

splatch added a commit that referenced this issue Sep 30, 2024
Related to #1764.

Signed-off-by: Łukasz Dywicki <[email protected]>
splatch added a commit that referenced this issue Sep 30, 2024
Related to #1764.

Signed-off-by: Łukasz Dywicki <[email protected]>
splatch added a commit that referenced this issue Oct 14, 2024
Related to #1764.

Signed-off-by: Łukasz Dywicki <[email protected]>
splatch added a commit that referenced this issue Oct 16, 2024
Related to #1764.

Signed-off-by: Łukasz Dywicki <[email protected]>
splatch added a commit that referenced this issue Oct 17, 2024
Related to #1764.

Signed-off-by: Łukasz Dywicki <[email protected]>
splatch added a commit that referenced this issue Oct 17, 2024
First and foremost - this commit switches OPC-UA tests to rely on dynamic port.

This implies also slight change to endpoint selection method and possibility to override desired endpoint port and host which might differ from host/port reported by OPC-UA server.
Because server is not aware of actual tcp port and host used by client, it is client duty to make proper decission when looking for endpoint.

Related to #1764.

Signed-off-by: Łukasz Dywicki <[email protected]>
@splatch
Copy link
Contributor

splatch commented Oct 22, 2024

For now I've changed assertion in ChunkTest to see if we have this +1 offset only for one field or for many. I am not entirely sure why it happens. I had a look and there is fairly basic math which is static.

Lets keep this issue open to track this test and others, if they keep failing randomly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug flaky test Indicates this issue relates to disabled tests, that cause the build to fail at random java Pull requests that update Java code OPC-UA https://plc4x.apache.org/users/protocols/opcua.html
Projects
None yet
Development

No branches or pull requests

3 participants