Package com.vaadin.quarkus.graal
Class AtmosphereRecorder
java.lang.Object
com.vaadin.quarkus.graal.AtmosphereRecorder
Sets up Atmosphere for the Vaadin servlets of a native image.
STATIC_INIT runs while the native image is built, so Atmosphere, which starts thread pools when it is initialized, is initialized at RUNTIME_INIT instead, before the Vaadin servlets that use it. The push WebSocket endpoints still have to be registered at STATIC_INIT, as the WebSocket container refuses new endpoints once its request handlers are created at RUNTIME_INIT, so each endpoint looks up the Atmosphere instance of its servlet when a WebSocket connects.
This class is meant for internal use only.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidinitAtmosphere(io.undertow.servlet.api.DeploymentManager deploymentManager, List<String> servletNames) Initializes Atmosphere for each of the given servlets.voidregisterPushEndpoints(io.undertow.servlet.api.DeploymentManager deploymentManager, List<String> servletNames) Registers the push WebSocket endpoint of each of the given servlets.
-
Constructor Details
-
AtmosphereRecorder
public AtmosphereRecorder()
-
-
Method Details
-
registerPushEndpoints
public void registerPushEndpoints(io.undertow.servlet.api.DeploymentManager deploymentManager, List<String> servletNames) Registers the push WebSocket endpoint of each of the given servlets.- Parameters:
deploymentManager- the manager of the servlet deploymentservletNames- the names of the Vaadin servlets
-
initAtmosphere
public void initAtmosphere(io.undertow.servlet.api.DeploymentManager deploymentManager, List<String> servletNames) Initializes Atmosphere for each of the given servlets.- Parameters:
deploymentManager- the manager of the servlet deploymentservletNames- the names of the Vaadin servlets
-