Interface HostConnectFlow<R>

Type Parameters:
R - wire response type returned by the host-type endpoint
All Known Implementing Classes:
GameServerConnectFlow, LoginServerConnectFlow

public interface HostConnectFlow<R>
Host-type-aware handshake strategy. Performs one POST against the platform's host-type connect endpoint, captures the deserialized response, and exposes uniform accessors so adapter wiring (Kafka client bootstrap, heartbeat, module ConnectContext) is host-type-agnostic.

Two implementations ship with adapter-core:

Single-attempt strategy — retry / backoff / scheduler concerns belong to ConnectFlow. The field accessors return null before a successful connect(); after success they project the captured response.

Internal to adapter-core — not an SPI. Public visibility is required only because NxAdapter (sibling package) consumes the type. External code MUST NOT implement this interface; new abstract methods will be added without deprecation cycles when new host-types or accessor fields land.

  • Method Summary

    Modifier and Type
    Method
    Description
    Execute one handshake attempt against the platform.
    The path under platformUrl this flow POSTs to — exposed for test introspection and logging.
    @Nullable String
    Heartbeat Kafka topic from the captured response.
    @Nullable app.l2nx.gs.adapter.api.rest.KafkaCredentials
    Kafka client bootstrap credentials from the captured response.
    @Nullable R
    Captured response from the last successful connect().
    @Nullable UUID
     
    @Nullable String
     
    @Nullable String
     
    @Nullable app.l2nx.gs.adapter.api.rest.SyncTopics
    Sync-stream topic bundle (db / runtime / datapack).
    @Nullable UUID
     
    @Nullable String
     
    @Nullable app.l2nx.gs.adapter.api.rest.MessagingTopics
    Messaging topic bundle (events + commands) from the captured response.
  • Method Details

    • connect

      Execute one handshake attempt against the platform. The returned TypedConnectOutcome wraps either the parsed response or a transport / HTTP error — never throws into the caller.
    • connectPath

      String connectPath()
      The path under platformUrl this flow POSTs to — exposed for test introspection and logging.
    • response

      @Nullable R response()
      Captured response from the last successful connect(). Returns null before the first successful call.
    • heartbeatTopic

      @Nullable String heartbeatTopic()
      Heartbeat Kafka topic from the captured response.
    • topics

      @Nullable app.l2nx.gs.adapter.api.rest.MessagingTopics topics()
      Messaging topic bundle (events + commands) from the captured response.
    • syncTopics

      @Nullable app.l2nx.gs.adapter.api.rest.SyncTopics syncTopics()
      Sync-stream topic bundle (db / runtime / datapack). Always null for login-server host-type — LS deployments carry no sync streams.
    • serverId

      @Nullable UUID serverId()
    • tenantId

      @Nullable UUID tenantId()
    • tenantSlug

      @Nullable String tenantSlug()
    • serverSlug

      @Nullable String serverSlug()
    • serverName

      @Nullable String serverName()
    • kafka

      @Nullable app.l2nx.gs.adapter.api.rest.KafkaCredentials kafka()
      Kafka client bootstrap credentials from the captured response. Named kafka() rather than kafkaCredentials() to match the field accessor naming on the underlying response DTOs.