Communication error: Invalid JSON from server: 1|X

Getting this error on my JMIX Application:
image

From chrome browser console:

Tue Aug 29 12:24:31 GMT-500 2023 com.vaadin.client.ApplicationConnection
SEVERE: Communication error: Invalid JSON from server: 1|X
RSb @ com.etcc.roadway.widgets.CustomWidgetSet-0.js:9265

I am running
id 'io.jmix' version '1.3.1'

I personally didn’t encounter it lately, but this was already a thing with CUBA, see Communication Problem - Pay attention to any unsaved data etc. Invalid JSON from server: 1/x - CUBA.Platform

I have the same problem.
It happens only in PROD on AWS EC2 instance… So there is a proxy 8080:5000, it might be related.

See this for details:

IMHO it is all related:

  1. Invalid JSON from server: 1|X
  2. Websocket closed, reason: Connection was closed abnormally (that is, with no close frame being sent). - wasClean: false
  3. org.atmosphere.util.IOUtils : More than one Servlet Mapping defined. WebSocket may not work org.apache.catalina.core.ApplicationServletRegistration

I think they should not suppress the warning in GitHub issue .

Thank you.
T

I encountered it with CUBA 7.2 uberJar deployed on Elastic Beanstalk, a month ago, had a load balancer.
My quick fix was to use war deployment on manually installed Tomcat on EC2 instance without a load balancer. For now it will hold.
I tried to experiment with sticky sessions, enforcing HTTP/1.0 and such as described here, but it didn’t work

Did not have time to figure out yet about "configuration directive “proxy_http_version 1.0;” into the server-domain-specific configuration located in the “vhost.d” so if somebody knows where this setting is, please share.

Did you deploy your application as bootjar? Then it would look like there is relation (uberJar)
I’m also curious if this error shows up if deployed inside a container.

Kind regards,
Mladen

Thanks Mladen,
Yes, I use bootJar.
Single instance not balanced ElasticBeanstalk env.
Containers not tested yet.

Regards,
Tomas