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

[openhabcloud] Read connection status of CloudService #16477

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

paspiz85
Copy link

@paspiz85 paspiz85 commented Mar 2, 2024

I need to know if the system is connected to cloud.
For example:

var cloudService = osgi.getService('org.openhab.io.openhabcloud.internal.CloudService');
actions.Log.logInfo('Test',`CloudService connection status: ${cloudService.isConnected()}`);

Signed-off-by: Pasquale Pizzuti <paspiz85@users.noreply.github.com>
@jlaur jlaur changed the title Read connection status of CloudService [openhabcloud] Read connection status of CloudService Mar 2, 2024
@lolodomo lolodomo added the enhancement An enhancement or new feature for an existing add-on label Mar 11, 2024
@lolodomo
Copy link
Contributor

@kaikreuzer @digitaldan : WDYT about this change ?

@kaikreuzer
Copy link
Member

This class is in an internal package, which tells me that it is not meant to be used as a public service, like e.g. from scripts.
I would prefer to see a cleanly defined interface, if we want to make it available as an API.
@digitaldan Wdyt?

@lsiepel
Copy link
Contributor

lsiepel commented Apr 13, 2024

I would also be interested in the use case. And maybe this can be easily fixed with an action method?

@digitaldan
Copy link
Contributor

Let me think on it a bit as I'm working on reviewing another cloud PR this weekend and will have a chance to go through the code.

@paspiz85
Copy link
Author

paspiz85 commented May 2, 2024

@digitaldan any news?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement An enhancement or new feature for an existing add-on
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants