Options
All
  • Public
  • Public/Protected
  • All
Menu

Class RemoteServersImpl

Implementation of the RemoteServers feature

Hierarchy

  • RemoteServersImpl

Implements

Index

Constructors

constructor

  • Create a new instance of the RemoteServers feature

    Parameters

    Returns RemoteServersImpl

Properties

Private CHECK_REMOTE_SERVER

CHECK_REMOTE_SERVER: ServiceSender<string, CheckRemoteServerResult>

Command service for checking a remote server

Private CREATE_REMOTE_SERVER

Command service for creating a remote server

Private LIST_REMOTE_SERVERS

LIST_REMOTE_SERVERS: ServiceSender<null, ListRemoteServersResult>

Command service for obtaining a list of remote servers

Private REMOVE_REMOTE_SERVER

REMOVE_REMOTE_SERVER: ServiceSender<string, null>

Command service for removing a remote server

Private internal

internal: InternalSession

The internal session

Methods

checkRemoteServer

  • Check the current state of a named remote server.

    This will report back the current state of the remote server, but also can be used to forcibly retry a failed remote server connection.

    Parameters

    • name: string

    Returns Result<RemoteServerStatus>

    a Result that completes when a response is received from the server, returning details of the remote server state.

    If the task fails, the Result will resolve with an error. Common reasons for failure include:

    • the calling session does not have CONTROL_SERVER permission;
    • the session is closed.

createRemoteServer

  • Create a new remote server instance with default connection options.

    If a remote server with the same name already exists an error will be returned.

    Parameters

    Returns Result<RemoteServer>

    a Result that completes when a response is received from the server, returning the definition of the remote server created by the operation.

    If the task fails, the Result will resolve with an error. Common reasons for failure include:

    • a remote server with the given name already exists;
    • one or more connection options are invalid;
    • the cluster was repartitioning;
    • the calling session does not have CONTROL_SERVER permission;
    • the session is closed.

listRemoteServers

  • List all the remote servers that have been created.

    Returns Result<RemoteServer[]>

    a Result that resolves when a response is received from the server, returning a list of remote servers.

    If the task fails, the Result will resolve with an Error. Common reasons for failure include:

    • the calling session does not have CONTROL_SERVER permission;
    • the session is closed.

removeRemoteServer

  • removeRemoteServer(name: string): Result<void>
  • Remove a named remote server if it exists.

    When a named remote server is removed, any components that specify it would be disabled.

    If the named remote server does not exist the completable future will complete successfully.

    Parameters

    • name: string

    Returns Result<void>

    a Result that resolves when a response is received from the server.

    If the task fails, the Result will resolve with an Error. Common reasons for failure include:

    • the cluster was repartitioning;
    • the calling session does not have CONTROL_SERVER permission;
    • the session is closed.