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

Conversation

@mliszcz
Copy link
Collaborator

@mliszcz mliszcz commented Oct 29, 2019

Correction for following scenario:

  • There are two Tango Database instances, H1 and H2.
  • Device "my/test/device" is hosted in a server running in the first instance (TANGO_HOST=H1)
  • Client application is runing in tje second instance (TANGO_HOST=H2)
  • Client application creates a group using qualified wildcard names (tango://H1/my/test/*)

Bug:

  • tango://H1/my/test/* is resolved to my/test/device instead of tango://H1/my/test/device

Fixes #495

Test verifies that devices running in a remote Tango instnace
(TANGO_HOST different from client's) can be accessed via Group API
using wildcard names.
TANGO_HOST is prepended to device names resolved from wildcards if
devices are running in remote Tango instance (different than client's.
Full device names are needed to instantiate device proxies to these
devices.
@mliszcz
Copy link
Collaborator Author

mliszcz commented Oct 29, 2019

Test (04f0d49) is failing without correction (c645525). You need to check travis logs. Job exit status is not working currently in CI.

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 this great quality PR. Nice work and some good initiatives.
This seems to solve the problem reported in #495 indeed.
I have only a few small improvement suggestions.

Use string stream instead of sprintf when building full device name for
group element to prevent buffer overflow.
Specify parameter names in function declarations in Group interface to
match function definitions.
@t-b t-b self-requested a review November 5, 2019 21:40
@mliszcz
Copy link
Collaborator Author

mliszcz commented Nov 6, 2019

@bourtemb could you please check if the changes are ok for you and can be merged?

@mliszcz
Copy link
Collaborator Author

mliszcz commented Nov 14, 2019

@bourtemb is the PR ok from your POV?

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.

Looks pretty good to me. Thanks! Just a small comment about the usage of std::getenv in the new test.

@mliszcz mliszcz merged commit 617a5b2 into tango-controls:tango-9-lts Nov 15, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Incorrect getting of the list of devices from a pattern for Tango::Group if using a remote host.

3 participants