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

Upgrade to Karaf 4.4.3 #1600

Merged
merged 1 commit into from
Mar 1, 2023
Merged

Upgrade to Karaf 4.4.3 #1600

merged 1 commit into from
Mar 1, 2023

Conversation

wborn
Copy link
Member

@wborn wborn commented Dec 22, 2022

  • Rework Servlets to use Http Whiteboard annotations in favor of proprietary org.openhab.core.io.http.servlet classes

Depends on openhab/openhab-core#3252

To do:

Fixes #1172

@wborn wborn changed the title Upgrade to Karaf 4 Upgrade to Karaf 4.4 Dec 22, 2022
@J-N-K J-N-K force-pushed the karaf-4 branch 2 times, most recently from 4c3ee65 to 8ed5fdf Compare January 7, 2023 22:57
@J-N-K
Copy link
Member

J-N-K commented Jan 7, 2023

There is one issue with MainUI, the openHAB logo in the upper left corner is not properly loading. I couldn't figure out why. BasicUI is fine as far as I can see.

I can't check the full build because as mentioned in #1353 it's not possible to build HaBOT on Apple Silicon.

@wborn wborn changed the title Upgrade to Karaf 4.4 Upgrade to Karaf 4.4.3 Jan 10, 2023
@J-N-K
Copy link
Member

J-N-K commented Jan 10, 2023

Did you get the openHAB logo to load?

@wborn
Copy link
Member Author

wborn commented Jan 10, 2023

Did you get the openHAB logo to load?

it's still an issue so I'll add it to the todos.

@J-N-K
Copy link
Member

J-N-K commented Jan 10, 2023

Maybe @digitaldan can help us here?

@digitaldan
Copy link
Contributor

Did you get the openHAB logo to load?

Can someone post a screenshot from the chrome developer/debug window of the network request (including headers and response) failing ?

@J-N-K
Copy link
Member

J-N-K commented Jan 11, 2023

Missing logo:

Bildschirm­foto 2023-01-11 um 22 03 19

Element:

Bildschirm­foto 2023-01-11 um 22 05 38

HTTP request:

Bildschirm­foto 2023-01-11 um 22 04 19

HTTP response:

Bildschirm­foto 2023-01-11 um 22 04 39

@digitaldan
Copy link
Contributor

Hmm, there's no content type on that like content-type: image/svg+xml, but the returned length looks right. I'm assuming that content type would be handled internally by Jetty as we don't do any custom mapping there. Do you know if SVGs are working else where ?

@digitaldan
Copy link
Contributor

Actually, that content length does not look right, way to big compared to my own system:
image

Can you curl that URL and see what the server is actually returning ?

@digitaldan
Copy link
Contributor

Actually, never mind, it does look the right size, i forgot i was going through my Caddy server which was doing some compression, here's the image directly to my OH, although it does contain a content-type which may be the missing element here.
image

@J-N-K
Copy link
Member

J-N-K commented Jan 11, 2023

Yes, two headers are missing:

Content-Type: image/svg+xml
Vary: Accept-Encoding

Requesting the file directly shows the correct file.

@J-N-K
Copy link
Member

J-N-K commented Jan 12, 2023

I found that the reason for the missing content-type is that the MIME-type map in the ContextHandler is empty. I didn’t check if that was the case before.

@wborn
Copy link
Member Author

wborn commented Jan 13, 2023

@J-N-K
Copy link
Member

J-N-K commented Jan 13, 2023

And that works? I was already there with the debugger, but _mimeTypes has an empty map in my system.

@wborn
Copy link
Member Author

wborn commented Jan 13, 2023

It looks empty but if it is empty it falls back to use __dftMimeMap which does not show in your debugger if you hover over it. 🙂

* Rework Servlets to use Http Whiteboard annotations in favor of proprietary `org.openhab.core.io.http.servlet` classes

Also-by: Jan N. Klug <[email protected]>
Signed-off-by: Wouter Born <[email protected]>
@wborn
Copy link
Member Author

wborn commented Mar 1, 2023

@openhab/webui-maintainers can you review this PR?
It's required for successful builds now that openhab/openhab-core#3252 got merged.

@kaikreuzer kaikreuzer merged commit 785bbe7 into openhab:main Mar 1, 2023
@kaikreuzer kaikreuzer added this to the 4.0 milestone Mar 1, 2023
@wborn wborn deleted the karaf-4 branch March 1, 2023 17:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

HTTP code 200 returned for invalid pages
4 participants