Hmm, can anyone else confirm this? I don’t understand how that could not be working, and i would think would be pretty widespread since thats a pretty heavily use feature? In anycase thats very likely not related to this.
So i think i found and fixed the issue in our cloud service. Its not new, and was not any recent change, so i think this has been broken for quite a while, but its also not consistent, there are several factors which can make it fail, which cloud server your client hits and frequency of updates, and it only happens on connections to home where we have no session state, every request is stateless and randomly will hit one of the 16 node processes across 4 cloud servers when initiated. This is how our mobile SSE connections would work.
In any case, i deployed the fix, my CURL client now stays connected. Would be great if other could give this a try.
First of all thanks a lot for taking the effort to look into that - that’s really appreciated.
I just tried again. On my end the situation is unchanged. Or does it take a bit to get into effect?
When the app gets loaded, my smart home items appear on the screen, but at the same time first the error “Notifications are unavailable - error connecting to remote server: Connecting to HTTPS port via HTTP?” appears on the bottom of the app.
After that the error “Event subscription failed - Widget refresh may be impaired” appears.
And after some seconds I end up on a black screen with the error
“The sitemap could not be loaded. The following error occured: Your reverse proxy got an invalid answer from the openHAB server (HTTP code 502)”
When opening Basic UI in the Firefox browser on the PC I still get the SSE-Subscription error as in the previous screenshot.
something seems very wrong with your specific setup, i would put the cloud binding in TRACE mode and see whats going on there, make sure your connection is not going up and down or something like that. I’m away from home this week, so i don’t have an android device or my usual simulator setup handy, but i do know this is working for me at least on IOS, chrome, and plain old Curl
Very strange.
What makes me a bit wondering is - I tested with 3 independent setups on 3 different locations with different internet connections. And all have the same behaviour. So I tend to exclude an unstable internet connection. I also tested on an old tablet with Android 10 - just to exclude this is caused by some recent security updates from Samsung, but also same behaviour there.
What they have in common: I updated all of the setups recently to OH 5.1.4 and I didn’t test with OH 5.2.0 RC.
I just tested also with the Chrome Browser on the PC and it’s also not working for me.
I did test with the iOS app and don’t see the error there. Also notifications work well there.
I have sent you a PM with a log file - maybe this helps, but I can’t see anything abnormal so far in the log.
Thank you a lot Dan, I tried again this morning and I can’t reproduce the problem anymore.
@Lolodomo which Openhab version are you using? Did you test with 5.1.4?
I am running 5.2 RC2.
Your problem seems to be different to the one I encountered yesterday (before it was fixed).
Do you have any possibility to test on 5.1.4 as well? I’m really a little bit clueless at the moment, what to look into next.
5.2 will be available in few hours so you can then check again
Excellent, then I’ll wait for that and re-test.
@digitaldan I was just again looking into logs of the binding and the following caught my attention:
2026-07-05 15:08:29.222 [TRACE] [io.openhabcloud.internal.CloudClient] - {"headers":{"Transfer-Encoding":"chunked","Server":"Jetty(9.4.57.v20241219)","Date":"Sun, 05 Jul 2026 13:08:29 GMT","Content-Type":"application/json"},"responseStatusCode":503,"responseStatusText":"Service Unavailable","id":56745}
2026-07-05 15:08:29.222 [DEBUG] [io.openhabcloud.internal.CloudClient] - onResponseContent: 56745, content size 79
2026-07-05 15:08:29.223 [TRACE] [io.openhabcloud.internal.CloudClient] - {"error":{"message":"Max number of subscriptions is reached.","http-code":503}}
Can it have something to do with that?
Now after a couple of days not working, things suddently started working again this evening on all 3 instances without me changing anything in my setup and the SSE errors disappeared. I really have no idea what was causing that and will continue observing it.
On the notification issue, I just recognized that notifications are only getting registered properly if you start registering a server with a blank, empty app. So after removing cache, data and re-installing the app, registering for notifications works only for the first instance you are setting up on the app, but not for additional ones for some reason.
That comes from openHAB core on your system when there are too many sitemap subscriptions registered. Its not a part of the codebase i have looked at in a very, very long time, so i’m not sure what that limit is, or what on your system is eating up those subscriptions, but this is the error messages you are seeing for sure in your clients.
I’ll keep observing it - still thanks all for your support!
I just want to report, that I have exactly the same behaviour the TO described in his initial post and my Android app is also not registering for notifications. I also see the “Max number of subscriptions is reached.” error in the log of my OH 5.2.0 setup.
So if you read my post above , something on you system is requesting too many sitemaps subscriptions. When you load a sitemap, the app requests a subscription over http from the server to be notified of item state changes so the sitemap updates in realtime. The error says there are too many of these ( > 255 i think). i would start there and see what app or browser is doing that (and what conditions may be a play).
Is there a way to see what is creating/holding SSE subscriptions? For example, is there a core bundle I can put into DEBUG or TRACE mode to see who is creating subscriptions and how often they are being created?
So I put org.openhab.core.io.rest.sitemap and org.openhab.core.io.rest.sse into DEBUG mode. Then using Firefox on my laptop I logged into openHAB cloud and opened my sitemap in the browser window.
I don’t know if I have something configured incorrectly, but I am seeing a new subscription created every few seconds.
2026-08-06 13:11:58.983 [DEBUG] [est.sitemap.internal.SitemapResource] - Received HTTP GET request from IP 127.0.0.1 at 'sitemaps'
2026-08-06 13:11:58.983 [DEBUG] [est.sitemap.internal.SitemapResource] - Received HTTP GET request at 'https://home.myopenhab.org:443/rest/sitemaps'.
2026-08-06 13:12:01.241 [DEBUG] [openhab.core.io.rest.sse.SseResource] - Sending alive event to SSE connections
2026-08-06 13:12:09.606 [DEBUG] [est.sitemap.internal.SitemapResource] - Received HTTP POST request from IP 127.0.0.1 at 'sitemaps/events/subscribe'
2026-08-06 13:12:09.607 [DEBUG] [t.sitemap.SitemapSubscriptionService] - Created new subscription with id 9375e3c1-f27a-49a2-9b45-2b7c1d7eb09f (2 active subscriptions for a max of 50)
2026-08-06 13:12:09.607 [DEBUG] [est.sitemap.internal.SitemapResource] - Client from IP 127.0.0.1 requested new subscription => got id 9375e3c1-f27a-49a2-9b45-2b7c1d7eb09f.
2026-08-06 13:12:11.242 [DEBUG] [openhab.core.io.rest.sse.SseResource] - Sending alive event to SSE connections
2026-08-06 13:12:20.407 [DEBUG] [est.sitemap.internal.SitemapResource] - Received HTTP POST request from IP 127.0.0.1 at 'sitemaps/events/subscribe'
2026-08-06 13:12:20.407 [DEBUG] [t.sitemap.SitemapSubscriptionService] - Created new subscription with id 78c36a8a-7b7c-46b5-a8cb-7713f2e1c684 (3 active subscriptions for a max of 50)
2026-08-06 13:12:20.407 [DEBUG] [est.sitemap.internal.SitemapResource] - Client from IP 127.0.0.1 requested new subscription => got id 78c36a8a-7b7c-46b5-a8cb-7713f2e1c684.
2026-08-06 13:12:20.887 [DEBUG] [t.sitemap.SitemapSubscriptionService] - Subscription 9375e3c1-f27a-49a2-9b45-2b7c1d7eb09f changed to default#default (3 active subscriptions}
2026-08-06 13:12:21.242 [DEBUG] [openhab.core.io.rest.sse.SseResource] - Sending alive event to SSE connections
2026-08-06 13:12:31.243 [DEBUG] [openhab.core.io.rest.sse.SseResource] - Sending alive event to SSE connections
2026-08-06 13:12:31.566 [DEBUG] [est.sitemap.internal.SitemapResource] - Received HTTP POST request from IP 127.0.0.1 at 'sitemaps/events/subscribe'
2026-08-06 13:12:31.567 [DEBUG] [t.sitemap.SitemapSubscriptionService] - Created new subscription with id 0b6e9b00-4747-4dd8-bcd2-81c72d955dac (4 active subscriptions for a max of 50)
2026-08-06 13:12:31.567 [DEBUG] [est.sitemap.internal.SitemapResource] - Client from IP 127.0.0.1 requested new subscription => got id 0b6e9b00-4747-4dd8-bcd2-81c72d955dac.
2026-08-06 13:12:31.953 [DEBUG] [t.sitemap.SitemapSubscriptionService] - Subscription 78c36a8a-7b7c-46b5-a8cb-7713f2e1c684 changed to default#default (4 active subscriptions}
2026-08-06 13:12:41.243 [DEBUG] [openhab.core.io.rest.sse.SseResource] - Sending alive event to SSE connections
2026-08-06 13:12:42.725 [DEBUG] [est.sitemap.internal.SitemapResource] - Received HTTP POST request from IP 127.0.0.1 at 'sitemaps/events/subscribe'
2026-08-06 13:12:42.725 [DEBUG] [t.sitemap.SitemapSubscriptionService] - Created new subscription with id e05c1a25-008e-4404-97ba-6a71d068101d (5 active subscriptions for a max of 50)
2026-08-06 13:12:42.725 [DEBUG] [est.sitemap.internal.SitemapResource] - Client from IP 127.0.0.1 requested new subscription => got id e05c1a25-008e-4404-97ba-6a71d068101d.
2026-08-06 13:12:43.103 [DEBUG] [t.sitemap.SitemapSubscriptionService] - Subscription 0b6e9b00-4747-4dd8-bcd2-81c72d955dac changed to default#default (5 active subscriptions}
2026-08-06 13:12:51.244 [DEBUG] [openhab.core.io.rest.sse.SseResource] - Sending alive event to SSE connections
2026-08-06 13:12:53.776 [DEBUG] [est.sitemap.internal.SitemapResource] - Received HTTP POST request from IP 127.0.0.1 at 'sitemaps/events/subscribe'
2026-08-06 13:12:53.777 [DEBUG] [t.sitemap.SitemapSubscriptionService] - Created new subscription with id 0a8d30eb-c91a-45cd-906e-a3ca2c2a34a2 (6 active subscriptions for a max of 50)
2026-08-06 13:12:53.777 [DEBUG] [est.sitemap.internal.SitemapResource] - Client from IP 127.0.0.1 requested new subscription => got id 0a8d30eb-c91a-45cd-906e-a3ca2c2a34a2.
2026-08-06 13:12:53.886 [DEBUG] [est.sitemap.internal.SitemapResource] - Run clean SSE subscriptions job
2026-08-06 13:12:53.887 [DEBUG] [est.sitemap.internal.SitemapResource] - Sent alive event to subscription bff48203-6bfe-4a62-9acb-8e8c7903c5b1.
2026-08-06 13:12:54.159 [DEBUG] [t.sitemap.SitemapSubscriptionService] - Subscription e05c1a25-008e-4404-97ba-6a71d068101d changed to default#default (6 active subscriptions}
Then I close the browser window containing my sitemap and the subscription creation stops. After a few more seconds I see it release only the last created subscription. None of the other subscriptions that were created ever appear to be released.
2026-08-06 13:14:53.887 [DEBUG] [t.sitemap.SitemapSubscriptionService] - Release subscription 0a8d30eb-c91a-45cd-906e-a3ca2c2a34a2 as it was not queried within PT30S seconds
2026-08-06 13:14:53.887 [DEBUG] [t.sitemap.SitemapSubscriptionService] - Removed subscription with id 0a8d30eb-c91a-45cd-906e-a3ca2c2a34a2 (5 active subscriptions)
2026-08-06 13:14:53.887 [DEBUG] [est.sitemap.internal.SitemapResource] - SSE connection for subscription 0a8d30eb-c91a-45cd-906e-a3ca2c2a34a2 has been released.
Note that I only see this behavior when I open the sitemap through openHAB cloud. Opening the sitemap using a local network connection only results in 1 subscription.
Reopening the sitemap in the browser results in the same… Subscriptions created every few seconds until I close the browser window, then only the last created subscription is cleaned up.
2026-08-06 13:27:13.855 [DEBUG] [est.sitemap.internal.SitemapResource] - Received HTTP POST request from IP 127.0.0.1 at 'sitemaps/events/subscribe'
2026-08-06 13:27:13.855 [DEBUG] [t.sitemap.SitemapSubscriptionService] - Created new subscription with id dbbfe652-12e9-4dc5-aa25-ae02fa76f14f (20 active subscriptions for a max of 50)
2026-08-06 13:27:13.855 [DEBUG] [est.sitemap.internal.SitemapResource] - Client from IP 127.0.0.1 requested new subscription => got id dbbfe652-12e9-4dc5-aa25-ae02fa76f14f.
2026-08-06 13:27:14.248 [DEBUG] [t.sitemap.SitemapSubscriptionService] - Subscription 0518bc17-8fe8-4dec-84d0-798302c8e9fc changed to default#default (20 active subscriptions}
2026-08-06 13:27:25.179 [DEBUG] [est.sitemap.internal.SitemapResource] - Received HTTP POST request from IP 127.0.0.1 at 'sitemaps/events/subscribe'
2026-08-06 13:27:25.179 [DEBUG] [t.sitemap.SitemapSubscriptionService] - Created new subscription with id b7f1e23b-6337-4bea-9b0f-50dee5130c9f (21 active subscriptions for a max of 50)
2026-08-06 13:27:25.179 [DEBUG] [est.sitemap.internal.SitemapResource] - Client from IP 127.0.0.1 requested new subscription => got id b7f1e23b-6337-4bea-9b0f-50dee5130c9f.
2026-08-06 13:27:25.568 [DEBUG] [t.sitemap.SitemapSubscriptionService] - Subscription dbbfe652-12e9-4dc5-aa25-ae02fa76f14f changed to default#default (21 active subscriptions}
2026-08-06 13:27:36.236 [DEBUG] [est.sitemap.internal.SitemapResource] - Received HTTP POST request from IP 127.0.0.1 at 'sitemaps/events/subscribe'
2026-08-06 13:27:36.236 [DEBUG] [t.sitemap.SitemapSubscriptionService] - Created new subscription with id 5f00b9fe-e7c2-485a-8b45-836a338a2aa6 (22 active subscriptions for a max of 50)
2026-08-06 13:27:36.236 [DEBUG] [est.sitemap.internal.SitemapResource] - Client from IP 127.0.0.1 requested new subscription => got id 5f00b9fe-e7c2-485a-8b45-836a338a2aa6.
2026-08-06 13:27:36.671 [DEBUG] [t.sitemap.SitemapSubscriptionService] - Subscription b7f1e23b-6337-4bea-9b0f-50dee5130c9f changed to default#default (22 active subscriptions}
2026-08-06 13:27:47.573 [DEBUG] [est.sitemap.internal.SitemapResource] - Received HTTP POST request from IP 127.0.0.1 at 'sitemaps/events/subscribe'
2026-08-06 13:27:47.573 [DEBUG] [t.sitemap.SitemapSubscriptionService] - Created new subscription with id eb2f3914-a4a7-4f4f-a8e5-6e996ce7410b (23 active subscriptions for a max of 50)
2026-08-06 13:27:47.573 [DEBUG] [est.sitemap.internal.SitemapResource] - Client from IP 127.0.0.1 requested new subscription => got id eb2f3914-a4a7-4f4f-a8e5-6e996ce7410b.
2026-08-06 13:27:47.966 [DEBUG] [t.sitemap.SitemapSubscriptionService] - Subscription 5f00b9fe-e7c2-485a-8b45-836a338a2aa6 changed to default#default (23 active subscriptions}
2026-08-06 13:27:58.645 [DEBUG] [est.sitemap.internal.SitemapResource] - Received HTTP POST request from IP 127.0.0.1 at 'sitemaps/events/subscribe'
2026-08-06 13:27:58.645 [DEBUG] [t.sitemap.SitemapSubscriptionService] - Created new subscription with id e3394b79-abba-429d-b8c5-22951494fa37 (24 active subscriptions for a max of 50)
2026-08-06 13:27:58.645 [DEBUG] [est.sitemap.internal.SitemapResource] - Client from IP 127.0.0.1 requested new subscription => got id e3394b79-abba-429d-b8c5-22951494fa37.
2026-08-06 13:27:59.036 [DEBUG] [t.sitemap.SitemapSubscriptionService] - Subscription eb2f3914-a4a7-4f4f-a8e5-6e996ce7410b changed to default#default (24 active subscriptions}
2026-08-06 13:28:09.703 [DEBUG] [est.sitemap.internal.SitemapResource] - Received HTTP POST request from IP 127.0.0.1 at 'sitemaps/events/subscribe'
2026-08-06 13:28:09.704 [DEBUG] [t.sitemap.SitemapSubscriptionService] - Created new subscription with id c01061a9-e481-44c1-ac13-6350ee1d0e02 (25 active subscriptions for a max of 50)
2026-08-06 13:28:09.704 [DEBUG] [est.sitemap.internal.SitemapResource] - Client from IP 127.0.0.1 requested new subscription => got id c01061a9-e481-44c1-ac13-6350ee1d0e02.
2026-08-06 13:28:10.136 [DEBUG] [t.sitemap.SitemapSubscriptionService] - Subscription e3394b79-abba-429d-b8c5-22951494fa37 changed to default#default (25 active subscriptions}
2026-08-06 13:28:20.810 [DEBUG] [est.sitemap.internal.SitemapResource] - Received HTTP POST request from IP 127.0.0.1 at 'sitemaps/events/subscribe'
2026-08-06 13:28:20.811 [DEBUG] [t.sitemap.SitemapSubscriptionService] - Created new subscription with id 74da7310-e0e2-4b2b-bf76-1ed9614ef438 (26 active subscriptions for a max of 50)
2026-08-06 13:28:20.811 [DEBUG] [est.sitemap.internal.SitemapResource] - Client from IP 127.0.0.1 requested new subscription => got id 74da7310-e0e2-4b2b-bf76-1ed9614ef438.
2026-08-06 13:28:21.315 [DEBUG] [t.sitemap.SitemapSubscriptionService] - Subscription c01061a9-e481-44c1-ac13-6350ee1d0e02 changed to default#default (26 active subscriptions}
2026-08-06 13:28:53.887 [DEBUG] [est.sitemap.internal.SitemapResource] - Run clean SSE subscriptions job
2026-08-06 13:28:53.887 [DEBUG] [t.sitemap.SitemapSubscriptionService] - Release subscription 74da7310-e0e2-4b2b-bf76-1ed9614ef438 as it was not queried within PT30S seconds
2026-08-06 13:28:53.887 [DEBUG] [t.sitemap.SitemapSubscriptionService] - Removed subscription with id 74da7310-e0e2-4b2b-bf76-1ed9614ef438 (25 active subscriptions)
2026-08-06 13:28:53.887 [DEBUG] [est.sitemap.internal.SitemapResource] - SSE connection for subscription 74da7310-e0e2-4b2b-bf76-1ed9614ef438 has been released.