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 }}
This repository was archived by the owner on Aug 11, 2023. It is now read-only.
Repository navigation
This repository was archived by the owner on Aug 11, 2023. It is now read-only.
testRegisterPublisher and testRegisterPublisherRetries are broken #268
aa38119 (#238) has broken testRegisterPublisher and testRegisterPublisherRetries. The stacktrace in both cases is similar:
java.lang.AssertionError:
at org.junit.Assert.fail(Assert.java:91)
at org.junit.Assert.assertTrue(Assert.java:43)
at org.junit.Assert.assertTrue(Assert.java:54)
at org.ros.internal.node.MasterRegistrationTest.testRegisterPublisher(MasterRegistrationTest.java:45)
I will need to get my setup configured on my personal computer and then run the tests. Unfortunately, I did not run the gradle tests after my commit (☹️ ) so I cannot say if the tests failed or passed for me. I will do this today and try and get back with you guys.
PS. I am using my personal account instead of my work. Just a heads up.
I'm testing on Ubuntu 16.04, Kinetic, Gradle 2.14.1 and Oracle Java 1.80
I will start to look into the publisher tests and see if I can see why they are failing...I haven't looked at this code in a while so it might take a bit.
@drigz It seems as if the Master is successfully sending the unregisterPublisher xml response by looking at the network traffic. I changed the publisher to /register so I could filter the network traffic.
Here is the unregisterPublisher request triggered by publisher.shutdown() on line 44 of MasterRegistrationTest.java:
I think what is happening is the ListenerGroup in the publisher is being shutdown before the master unregister signal is caught and thus causing the timeout. It is almost like there should be a check to see if the signalOnMasterUnregistrationSuccess() function has been executed before the listeners.shutdown() is called.
File: DefaultPublisher.java
@Overridepublicvoidshutdown(longtimeout, TimeUnitunit) {
signalOnShutdown(timeout, unit);
outgoingMessageQueue.shutdown();
// Add a timer check to see if we got the unregister signal from master, then proceed to shutdown all listeners listeners.shutdown();
}
Here is where the unregister gets triggered in the DefaultPublisher.java class
Activity
dambrosio commentedon Feb 26, 2018
I will need to get my setup configured on my personal computer and then run the tests. Unfortunately, I did not run the gradle tests after my commit (☹️ ) so I cannot say if the tests failed or passed for me. I will do this today and try and get back with you guys.
PS. I am using my personal account instead of my work. Just a heads up.
drigz commentedon Feb 26, 2018
Thanks! Let us know if you make any progress!
dambrosio commentedon Feb 26, 2018
@drigz
I am also failing on the following tests:
I'm testing on Ubuntu 16.04, Kinetic, Gradle 2.14.1 and Oracle Java 1.80
I will start to look into the publisher tests and see if I can see why they are failing...I haven't looked at this code in a while so it might take a bit.
dambrosio commentedon Feb 27, 2018
@drigz It seems as if the Master is successfully sending the unregisterPublisher xml response by looking at the network traffic. I changed the publisher to /register so I could filter the network traffic.
Here is the unregisterPublisher request triggered by
publisher.shutdown()on line 44 of MasterRegistrationTest.java:And here is the response from the Master:
I think what is happening is the ListenerGroup in the publisher is being shutdown before the master unregister signal is caught and thus causing the timeout. It is almost like there should be a check to see if the
signalOnMasterUnregistrationSuccess()function has been executed before thelisteners.shutdown()is called.File: DefaultPublisher.java
Here is where the unregister gets triggered in the DefaultPublisher.java class
File: DefaultPublisher.java
Any ideas?
@jubeira adding you to this for input, let me know if you have questions.