openHAB 4.3 Release Discussion

The problems you described and the fact you are using HTTP on port 8080 clearly point in the direction that you are running into the max parallel connections limitation.

To fix this, we have to either use HTTP2 for the REST API (which however requires HTTPS), or set the Keep-Alive header for plain HTTP.

BTW: Several users have confirmed that switching to http2 on their reverse proxies has fixed the issue.

It will depend on each system I suspect. I ran with 5000 for a while and it was fine.

In the original PR I did suggest that this is configurable, but there was only a small amount of time to get this PR included.

In the longer term (possibly over the next few weeks) I have plans to change the way the logger works. It really needs some support in the core rather than doing everything in the browser, but again, this was not possible given the time I had to get this included in this release. I’ve made a start on this, and it includes things like server side filtering and buffering so that you can look at the history when the UI logger is initially opened rather than waiting for it to fill.

5 Likes

After the upgrade from OH 4.2.3 to $.3 I have problems with MQTT and ESPresense. Before it works fine and I can use the counter for the presense detection very reliable. After the upgrade the Presense counter is often NULL (but I can’t find a time series). For the first fast step I have add a wait for 5 sec into the rule - normally it’s only o for < a second. I will start debugging but is there anybody else who has simular problems with MQTT like I have ? I used a manual setup for the MQTT Channels, After I recognized the problems I switch to the ESPresense thing (what was automatically detected by OH.) and hopped it will be better but same result.

Thx, Chris

update: I have two ESP32 and both of them are going to NULL at the same time

2024-12-20 07:41:01.291 [INFO ] [g.openhab.core.model.script.logCount] - ESPCount-1 Value : 0
2024-12-20 07:41:01.292 [INFO ] [g.openhab.core.model.script.logCount] - ESPCount-2 Value : 0
2024-12-20 07:41:16.250 [INFO ] [g.openhab.core.model.script.logCount] - ESPCount-1 Value : 2
2024-12-20 07:41:16.251 [INFO ] [g.openhab.core.model.script.logCount] - ESPCount-2 Value : 2

Update: After over 1 hour hard working with 1 tab (rules) on Firefox and parallel one tab (things) on Edge - it looksthat work only with 1 tab is ok - no slowdowns, no hangups.

My other observation is that OH now is starting a little bit slowly, as I see in the log around 4 minutes (few times tested), it seems to me that the previous version of OH started faster, I’m just signaling that maybe it is related to the implementation of new functionality, maybe it is my subjective feeling, because before that I did not measure the time until when it was 100%.

1 Like

Log Viewer will only show logs that are writtten after you open log viewer. It cannot see nor show (yet) logs that occurred before you opened the log viewer.

So, given your logs shown above, if you opened log viewer after 17:33:21.895, it won’t show anyrthing until the next log statement is written.

:+1:
Of course! It’s really good already given the amount of time you had to build it. If looking into setting the buffer size (if that makes sense) is already on your list, an issue isn’t required as a reminder.

2 Likes

Hi I was about to start from scratch, so i went for the raspberry pi imager 1.8.5, but no matter what i did, i am just presented with init failure, so i never get past that

[No init found. Try passing init=bootargā€

I tried the same sd card with a diffrent distro, and it works flawlesly, so i am unsure what is wrong, but it is not working.

This confirms that it is very likely the max parallel connections issue. We really need to look into this soon.

After a few days I can report that for me simply using http2 for the proxy did not solve this issue. I still experience times when the openHAB app is no longer able to load resources properly. When I switch to the browser it usually works there. Therefore I now also added a keepalive for the upstream connection to see how this works out.

However I had the impression that this might also be caused by a session that is no longer valid. If I experience this problem and try to log out in the app I get an error message. After closing/reopening the app and logging back in everything works fine.

I can confirm this behaviour too.
I see this problem only when linking Item to dimmer channel of Generic MQTT Thing, when I link the same item via MQTT HomeAssistant integration the slider is working properly.

2 Likes

@ra_dzik , @florian-h05 : My solution in the meantime is to use two different browsers: Firefox shows the operating UI and Chrome with several tabs for rules, items, logs…
This way I never exceed the limitation of http-connections.
And yes: I didn’t manage to setup the reverse proxy correctly: It’s redirecting http but not https. I’ve got to dig a little deeper but in the meantime I’m fine with the above solution.

1 Like

Enclosed my code and what I get as a result.

component: oh-clock-card
 config:
  stylesheet: |
   .col > div {
    color: white;
    background-color: rgba(6,25,36)
   }            
  timeFormat: dddd, DD.MM.YYYY

That’s the field looking like in edit mode:

and here, on once active:

Now, given the suggestions from @florian-h05 I changed the code to the following,

- component: oh-clock-card
    config:
      timeFormat: dddd, DD.MM.YYYY
      style:
        background: rgba(6,25,36)
        color: white

This fixed the layout:

Thank you!

1 Like

Good morning,

The upgrade works perfectly for me apart from two minor issues with the new iOS-theme.
I use a wall-mounted iPad with the openhab-app.
I’ll open two threads for the issues as they are separate topics.

First is: F7-Lists look like zoomed in. I use F7-Lists in a fixed grid for my iPad because I want to put as many widgets as I can on one page (yes I know, this is a lot of information on one page :smile: ) But I like it that way. On the pictures below you see what’s happening.
This only happens to my F7-List widgets. If helpful, I could upload my YAML too.

What I’ve tried so far:

  • using stylesheets, but I either I didn’t find the right place to inject or it isn’t working
  • changing font-size manually which didn’t resize the block
  • Reducing margin and padding of each component which didn’t show any effect
  • Moving away from the fixed grid. Then the list renders perfectly but consumes almost half of the screen :slight_smile:

Any idea how I could fix it? I have to admit, that css is not really my passion :rofl:

Thank you very much!
Jan


Hello again,

The second issue with the upgrade I have is with pop-ups I use. If I open it with the browser on my computer, it renders perfectly into the whole window.
If I open it on the iPad, it only shows a segment of the page. Of course I can move the page to see the content, but that’s not the idea. On the iPhone it opens perfectly full screen as it should.

Do you have an idea how to solve this? The code below shows the link which is used to open the popup. On the pictures you can see the different appearance.

Thank you very much for your help.
Jan


    - component: oh-link
      config:
        action: popup
        actionModal: page:Test_Pumpenstarts
        actionModalConfig:
          bigCard: true
        style:
          height: 50%
          left: 0
          position: absolute
          top: 0
          width: 100%```

Got an automated? update to OH4.3 and have problems with MQTT and sendCommand since. The log shows the error:

ERROR org.openhab.core.internal.common.AbstractInvocationHandler An error occurred while calling method 'ThingHandler.handleCommand()' on 'org.openhab.binding.mqtt.generic.internal.handler.GenericMQTTThingHandler@47b30a0e': class org.openhab.core.library.types.OnOffType cannot be cast to class org.openhab.core.library.types.PercentType (org.openhab.core.library.types.OnOffType and org.openhab.core.library.types.PercentType are in unnamed module of loader org.eclipse.osgi.internal.loader.EquinoxClassLoader @3adc9310)

I sort of nailed it down to two problems:

Problem 1:

val convertedNumber = Integer::parseInt(light.label)
sendCommand(s, new PercentType(convertedNumber))

This can work multiple times, but at some point there is the error mentioned above. It is unclear why there it sometimes works and why it doesn’t the other time. There is a link with Problem 2 it seems:

Problem 2:
Every time i send an update using the MQTT state (python script is doing this), i get this error now. After this error, typically Problem 1 starts acting up.

WARN	org.openhab.core.io.transport.mqtt.internal.Subscription	A subscriber of type 'class org.openhab.binding.mqtt.generic.ChannelState' failed to process message '4F4E' to topic 'house/light/Tuya_Doorgang/state'.

Weird temp solution is to press ā€˜Save’ in the Generic MQTT Thing which contains the channels bound to these MQTT topics and then both Problem 1 and 2 are gone…?

All this started after the latest update. What is happening here…?

You normally only need to proxy http, for the reverse proxy the upstream is normally always http. HTTPS is handled by the reverse proxy itself:
reverse proxy → upstream
HTTP → HTTP
HTTPS → HTTP

You would need to check the DOM and its CSS from the browser developer tools … which is difficult on iOS unless you have a Mac.
Can you share your widget code, so I can check how it looks for me and also have a look at the CSS? We UI maintainers have free access to BrowserStack, so we can indeed have a look at the dev tools on iOS devices as well.

Sure! Find the widget code below. Well, I did check the CSS from the developer code, but as I’m not really skilled in CSS I didn’t really figure out how to fix it :rofl:

Indeed I work with a MAC, how could I check it for iOS then? Do I need special developer tools which emulates an iOS? Or is this built in in Safari?

The code I uploaded already includes some minor changes with --f7-list-item-padding and manually adapting the font-size. It slightly improves how the widget looks but I think there are better ways to solve it. And maybe there are better ways of distributing content into list-items. But this did the trick to me :slight_smile:

uid: Raumtemperatur
tags: []
props:
  parameters: []
  parameterGroups: []
timestamp: Dec 19, 2024, 2:18:34 PM
component: f7-card
config:
  class:
    - text-align-left
  title: Raumtemperatur
slots:
  default:
    - component: f7-list
      slots:
        default:
          - component: f7-list-item
            config:
              style:
                --f7-list-item-padding-horizontal: 4px
                --f7-list-item-padding-vertical: 0px
                background: '=(Number.parseFloat(items.ShellyHTSauna_Luftfeuchtigkeit.state) >
                  60 ) ? "#FF8585" : ""'
            slots:
              inner:
                - component: f7-row
                  slots:
                    default:
                      - component: f7-icon
                        config:
                          f7: drop
                      - component: Label
                        config:
                          text: =Math.round(Number.parseFloat(items.ShellyHTSauna_Luftfeuchtigkeit.state))
                            + " %"
              inner-start:
                - component: Label
                  config:
                    text: Schlafzimmer
                    style:
                      font-size: 14px
              title:
                - component: f7-row
                  slots:
                    default:
                      - component: f7-icon
                        config:
                          f7: thermometer
                      - component: Label
                        config:
                          text: =items.ShellyHTSauna_Temperatur.state
          - component: f7-list-item
            config:
              style:
                --f7-list-item-padding-horizontal: 4px
                --f7-list-item-padding-vertical: 0px
                background: '=(Number.parseFloat(items.ShellyHTBad_Luftfeuchtigkeit.state) > 60
                  ) ? "#FF8585" : ""'
            slots:
              inner:
                - component: f7-row
                  slots:
                    default:
                      - component: f7-icon
                        config:
                          f7: drop
                      - component: Label
                        config:
                          text: =Math.round(Number.parseFloat(items.ShellyHTBad_Luftfeuchtigkeit.state)) +
                            " %"
              inner-start:
                - component: Label
                  config:
                    style:
                      font-size: 14px
                    text: Badezimmer
              title:
                - component: f7-row
                  slots:
                    default:
                      - component: f7-icon
                        config:
                          f7: thermometer
                      - component: Label
                        config:
                          text: =items.ShellyHTBad_Temperatur.state
          - component: f7-list-item
            config:
              style:
                --f7-list-item-padding-horizontal: 4px
                --f7-list-item-padding-vertical: 0px
                background: '=(Number.parseFloat(items.Shelly_HT_HWR_Luftfeuchtigkeit.state) >
                  60 ) ? "#FF8585" : ""'
            slots:
              inner:
                - component: f7-row
                  slots:
                    default:
                      - component: f7-icon
                        config:
                          f7: drop
                      - component: Label
                        config:
                          text: =Math.round(Number.parseFloat(items.Shelly_HT_HWR_Luftfeuchtigkeit.state))
                            + " %"
              inner-start:
                - component: Label
                  config:
                    style:
                      font-size: 14px
                    text: HWR
              title:
                - component: f7-row
                  slots:
                    default:
                      - component: f7-icon
                        config:
                          f7: thermometer
                      - component: Label
                        config:
                          text: =items.Shelly_HT_HWR_Temperatur.state

1 Like

What do you mean with automated update.
openHAB does not have such.
What did you do before the update?

ah sorry about that. I can downgrade through a docker downgrade to previous release. Let’s see if that works! Still, these are weird errors…and OH5 is coming.

And now having downgraded tot 4.2.3 solved these problems. Super stable, no errors…