Skip to content
This repository was archived by the owner on Jul 8, 2022. It is now read-only.

Send attribute configuration event to all clients after device restart #694

Merged

Conversation

mliszcz
Copy link
Collaborator

@mliszcz mliszcz commented Mar 16, 2020

Fixes #361

mliszcz added 2 commits March 16, 2020 13:08
Add test that verifies if attribute configuration event is sent to all
subscribers after device restart (regardless if properties have changed).
@mliszcz
Copy link
Collaborator Author

mliszcz commented Mar 16, 2020

 5/93 Test  #6: CXX::cxx_dserver_misc .............***Failed   19.65 sec
Starting DevTest/test
DevTest/test PID: 5680
Starting FwdTest/test
FwdTest/test PID: 5699
Running 8 tests
Testing DServer Misc :

	State and Status commands --> OK
	DevRestart command on the dserver device --> OK
	DevRestart command on classical device --> OK
	str = The device is ON
The polling is ON
	name description state ans status CORBA attributes --> OK
	ping the device --> OK
	info call --> OK
	event subscription recovery after device restart --> OK

In DServerMiscTestSuite::test_attr_conf_change_event_after_device_restart:
/home/tango/src/cpp_test_suite/cxxtest/include/../../new_tests/cxx_dserver_misc.cpp:285: Error: Expected (2 == callback.num_of_all_events), found (2 != 1)
TEST FAILED in:
1 iteration of test case
1 iteration of test suite

@mliszcz mliszcz marked this pull request as ready for review March 16, 2020 14:45
@mliszcz mliszcz requested review from bourtemb and t-b as code owners March 16, 2020 14:45
Copy link
Member

@bourtemb bourtemb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @mliszcz for the fix and for removing some duplicated code.
This seems to work as expected.
I just propose a small improvement in a comment.

@mliszcz mliszcz force-pushed the fix-361-missing-attr_conf-after-reset branch from ee9e9a7 to 8df43cd Compare March 18, 2020 14:12
Attribute properties may have changed during the restart. Push the event
to all registered subscribers to ensure that they get updated values.
@mliszcz mliszcz force-pushed the fix-361-missing-attr_conf-after-reset branch from 8df43cd to 773abdb Compare March 18, 2020 14:15
@mliszcz mliszcz added the Candidate For Backport Requires a backport to the release branches label Mar 26, 2020
@t-b t-b merged commit 8fd3b4d into tango-controls:tango-9-lts Apr 23, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Candidate For Backport Requires a backport to the release branches
Projects
None yet
Development

Successfully merging this pull request may close these issues.

missing attr_conf event after "Reset to default value"
3 participants