Interface HTTP2Session.LifeCycleListener

All Superinterfaces:
EventListener
Enclosing class:
HTTP2Session

public static interface HTTP2Session.LifeCycleListener extends EventListener

Listener for open/close Session events.

Applications can register instances of this class either directly on the HTTP/2 session via HTTP2Session.addEventListener(EventListener), or by adding the instances as beans to either the HTTP2Client (on the client), or the HTTP/2 ConnectionFactory (on the server).

Instances of this class must be stateless or thread-safe, since the same instance will be registered for all sessions.

  • Method Summary

    Modifier and Type
    Method
    Description
    default void
    onClose(Session session)
    Invoked when a session is closed.
    default void
    onOpen(Session session)
    Invoked when a session is opened.
  • Method Details

    • onOpen

      default void onOpen(Session session)

      Invoked when a session is opened.

      Parameters:
      session - the associated HTTP/2 session
    • onClose

      default void onClose(Session session)

      Invoked when a session is closed.

      Parameters:
      session - the associated HTTP/2 session