Search Results for

    Show / Hide Table of Contents

    IEchoRemoteNode Interface

    The IEchoRemoteNode interface represents a remote node. More specifically, it actually represents the link between the local node and a remote node, since the IEchoRemoteNode interface is always retrieved from an existing local node context.

    From the main TEcho class, you can retrieved the IEchoRemoteNode interface using the method GetRemoteNode. This method has two overloaded signatures, each one representing one of the two different ways of communication between nodes.

    1. Rest/Json Server

    In this case communication with the remote node will happen through a Rest/Json Echo server. To get the interface, pass the URL of the Echo server:

    var
      RemoteNode: IEchoRemoteNode;
    {...}
      RemoteNode := Echo.GetRemoteNode('http://serverhost/tms/echo/servernode');
    

    2. Direct database connection

    In this case the server database will be accessed directly. To get the interface, pass an IDBConnectionPool interface that connects with the remote database:

    var
      ServerDatabasePool: IDBConnectionPool;
    {...}
      RemoteNode := Echo.GetRemoteNode(ServerDatabasePool);
    

    Methods

    Name Description
    procedure Push; Pushes all pending batches from the local node to the remote node.
    procedure Pull; Pulls all pending batches from remote node to local node.
    procedure RegisterNode; Registers the bidirectional replication link between local node and remote node
    In This Article
    Back to top TMS Echo v1.11.3.11
    © 2002 - 2025 tmssoftware.com