HTTP 4xx handling in WebView
Post here questions and problems related to oXygen frameworks/document types.
-
willy_mwangi
- Posts: 4
- Joined: Thu Feb 12, 2026 12:58 pm
HTTP 4xx handling in WebView
Post by willy_mwangi »
We have a plugin that runs a webview and then loads a web-app (sidebar) inside it. We noticed that when we have responses of 200, everything works fine but when we get 400 errors, our web-app doesn’t work properly. When we enable debugging, we can see the error attached. However, our web-app is unable to process the error. We tried reproducing the issue with a standalone JFX and Swing application but everything worked fine.
The 400 error has more information in the body and it seems this information is lost and hence the reason why our web-app doesn't seem to work as expected. The error has a json payload that has error detail, type, and title along with status.
Which leaves us with the question, why does this happen in Oxygen only and not in the browser or other applications that run the web-app?
We used Oxygen Editor version 25, 26, 27, and 28 for testing.
The 400 error has more information in the body and it seems this information is lost and hence the reason why our web-app doesn't seem to work as expected. The error has a json payload that has error detail, type, and title along with status.
Which leaves us with the question, why does this happen in Oxygen only and not in the browser or other applications that run the web-app?
We used Oxygen Editor version 25, 26, 27, and 28 for testing.
Code: Select all
ro.sync.net.protocol.http.HttpExceptionWithDetails: 400 Bad Request for: https://our-service.com/api/v1/check
at ro.sync.net.protocol.http.b.s.x(Unknown Source)
at ro.sync.net.protocol.http.b.s.c(Unknown Source)
at ro.sync.net.protocol.http.abstraction.n.r(Unknown Source)
at ro.sync.net.protocol.http.abstraction.n.e(Unknown Source)
at ro.sync.net.protocol.http.WebdavHttpURLConnection$_c.close(Unknown Source)
at com.sun.webkit.network.URLLoader.sendRequest(URLLoader.java:373)
at com.sun.webkit.network.URLLoader.doRun(URLLoader.java:163)
at com.sun.webkit.network.URLLoader.lambda$run$0(URLLoader.java:130)
-
Radu
- Posts: 9649
- Joined: Fri Jul 09, 2004 5:18 pm
Re: HTTP 4xx handling in WebView
Hi,
Oxygen has its own HTTP client libraries inside and it overrides the HTTP protocol completely in the entire application to use its own HTTP URL handler instead of the HTTP URL handler provided by the default Java libraries.
So Oxygen's own HTTP URL handler may and does behave differently from the default Java libraries HTTP URL handler implementation.
We have this custom plugin extension which allows a plugin to decide that for a certain URL host to delegate to the Java base URL handler instead of using our own:
https://www.oxygenxml.com/doc/versions/ ... lugin.html
Regards,
Radu
Oxygen has its own HTTP client libraries inside and it overrides the HTTP protocol completely in the entire application to use its own HTTP URL handler instead of the HTTP URL handler provided by the default Java libraries.
So Oxygen's own HTTP URL handler may and does behave differently from the default Java libraries HTTP URL handler implementation.
We have this custom plugin extension which allows a plugin to decide that for a certain URL host to delegate to the Java base URL handler instead of using our own:
https://www.oxygenxml.com/doc/versions/ ... lugin.html
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
Return to “SDK-API, Frameworks - Document Types”
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ Artificial Intelligence (AI Positron Assistant add-on)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service