Skip to content

Connections to openHAB

vbier edited this page Aug 30, 2020 · 2 revisions

There are several connections from HPV to openHAB:

  1. the Habanel page opens an SSE connection in the browser component (webview)
    this connection is responsible for showing updated values in the webview. it is controlled by HabPanel code and HPV does not do anything with this connection.
  2. HPV opens an SSE connection
    this connection is responsible for getting value updates needed by HPV, e.g. the command item and reporting items. It is also used to derive the app connection status. In contrast to 1, the Server URL preference is used for this connection.
  3. HPV sends value updates to openHAB using REST calls
    As the SSE connection can not be used to update values, HPV makes a separate REST call to openHAB's REST API every time it submits a value to openHAB. It uses the Server URL preference to construct the correct URL for the updates.

So it is possible that the webview shows openHAB and also all values are updated, but HPV still shows the red border indicating a missing SSE connection.