Closed ghost closed 1 year ago
I cannot reproduce this problem.
According to the provided log, the test is running using the tcp-transport, therefore the setting of $DBUS_SESSION_BUS_ADDRESS
is ignored.
I found a small issue related to notify pending method calls about the disconnect.
In that case a Error
object should be created but the given exception was null, therefore the constructor of Error
failed because it tries to get the class and message from the exception.
But either with or without a patch for the issue above, I cannot reproduce the problem.
If I run the cross test on my private laptop (pretty new Ryzen 7), no issues. Running the same on my work laptop (slow as hell Core i-5) also no issue. Running the test in Github actions also shows no issues in this test. Same for the two unixsocket-based transports - no issues in any setup.
[Edit]: Running the test takes around 30 seconds to be completed, (on my slower machine using tcp-transport). It is faster when using unixsockets (~16 seconds).
$ git clone https://github.com/hypfvieh/dbus-java/
Cloning into 'dbus-java'...
remote: Enumerating objects: 12685, done.
remote: Counting objects: 100% (1066/1066), done.
remote: Compressing objects: 100% (493/493), done.
remote: Total 12685 (delta 535), reused 804 (delta 465), pack-reused 11619
Receiving objects: 100% (12685/12685), 3.57 MiB | 6.28 MiB/s, done.
Resolving deltas: 100% (6850/6850), done.
$ cd dbus-java/
$ mvn --version
Apache Maven 3.6.3 (cecedd343002696d0abb50b32b541b8a6ba2883f)
Maven home: /opt/maven
Java version: 17.0.3, vendor: Eclipse Adoptium, runtime: /opt/jdk-17.0.3+7
Default locale: en_US, platform encoding: UTF-8
OS name: "linux", version: "4.19.0-21-amd64", arch: "amd64", family: "unix"
$ java --version
openjdk 17.0.3 2022-04-19
OpenJDK Runtime Environment Temurin-17.0.3+7 (build 17.0.3+7)
OpenJDK 64-Bit Server VM Temurin-17.0.3+7 (build 17.0.3+7, mixed mode, sharing)
$ uname -a
Linux hostname 4.19.0-21-amd64 #1 SMP Debian 4.19.249-2 (2022-06-30) x86_64 GNU/Linux
$ mvn package
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary for dbus-java-parent 4.2.2-SNAPSHOT:
[INFO]
[INFO] dbus-java-parent ................................... SUCCESS [ 1.781 s]
[INFO] dbus-java-core ..................................... SUCCESS [ 15.599 s]
[INFO] dbus-java-osgi ..................................... SUCCESS [ 4.103 s]
[INFO] dbus-java-transport-jnr-unixsocket ................. SUCCESS [ 3.568 s]
[INFO] dbus-java-transport-tcp ............................ SUCCESS [ 2.623 s]
[INFO] dbus-java-utils .................................... SUCCESS [ 9.033 s]
[INFO] dbus-java-bom ...................................... SUCCESS [ 0.032 s]
[INFO] dbus-java-transport-native-unixsocket .............. SUCCESS [ 2.477 s]
[INFO] dbus-java-tests .................................... SUCCESS [06:14 min]
[INFO] dbus-java-examples ................................. SUCCESS [ 0.882 s]
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 06:56 min
[INFO] Finished at: 2023-01-13T10:12:00-08:00
[INFO] ------------------------------------------------------------------------
Cannot reproduce the timeout issue. Could be a sign of a race-condition, could have been a guest VM problem (the development environment is hosted on a Linux VM). Closing for now.
Replicate
Expected
Builds a JAR file.
Actual
The following test takes a long time to run (at least 10 minutes; I cancelled it before it finished):
Not sure if this is because of the environment variable value being set:
I disabled the following test in
org.freedesktop.dbus.test.TestCross
to allow the build/tests to proceed, then re-ranmvn package
:After disabling that test, the unit tests run to completion and a JAR file is built.