class Movie::Remote::RemoteExtension

Overview

RemoteExtension is the main coordinator for the remoting system. It manages the server, connections, and provides methods for remote communication.

Usage: extension = system.enable_remoting("127.0.0.1", 9000)

or

Movie::Remote::Remoting.get(system)

Defined in:

movie/remote/extension.cr

Constant Summary

Log = ::Log.for(self)

Constructors

Instance Method Summary

Instance methods inherited from class Movie::Extension

start start, stop stop

Constructor Detail

def self.new(system : Movie::AbstractActorSystem, bind_host : String, bind_port : Int32, stripe_count : Int32 = StripedConnectionPool::DEFAULT_STRIPE_COUNT, settings : AssociationSettings = AssociationSettings.new) #

[View source]

Instance Method Detail

def actor_ref(path : ActorPath, type : T.class) : RemoteActorRef(T) forall T #

Creates a remote actor reference for the given path and type. Uses the striped connection pool for parallel sending.


[View source]
def actor_ref(path_str : String, type : T.class) : RemoteActorRef(T) forall T #

Creates a remote actor reference from a path string.


[View source]
def address : Address #

[View source]
def connect(address : Address) : Connection #

Legacy: single connection interface (uses first stripe)


[View source]
def connection_for(address : Address) : Connection | Nil #

Legacy: single connection getter


[View source]
def control_deduplication_stats : ControlDeduplicationStats #

Receiver-side reliable-control state for operational capacity alerts.


[View source]
def local_port : Int32 #

Returns the actual bound port.


[View source]
def node_uid : String #

[View source]
def path_for_actor(name : String) : ActorPath #

Generates a path for a new actor under the user guardian.


[View source]
def path_registry : Movie::PathRegistry #

Delegate to system's path registry for unified actor lookup


[View source]
def pool_for(address : Address) : StripedConnectionPool #

Gets or creates a connection pool to the given address.


[View source]
def pool_stats : Array(PoolStats) #

Returns statistics for all connection pools.


[View source]
def register_actor(ref : Movie::ActorRefBase, path : ActorPath) #

Registers a local actor with its path for remote access.


[View source]
def retire_control_node(node_uid : String) : Int32 #

Reclaims reliable-control cursors for a process incarnation that has been confirmed permanently stopped. Retiring a live node breaks its sequence continuity and is therefore deliberately never automatic.


[View source]
def settings : AssociationSettings #

[View source]
def start : Bool #

Starts the remote extension (server).


[View source]
def stop #

Stops the remote extension.


[View source]
def stripe_count : Int32 #

[View source]
def unregister_actor(ref : Movie::ActorRefBase) #

Unregisters a local actor.


[View source]