Table of Contents

Interface ILocatorRegistryService

Namespace
IceRpc.Slice.Ice
Assembly
IceRpc.Locator.dll

A server application registers the server addresses of its indirect object adapters with the LocatorRegistry service.

[SliceTypeId("::Ice::LocatorRegistry")]
[DefaultServicePath("/Ice.LocatorRegistry")]
public interface ILocatorRegistryService

Remarks

The Slice compiler generated this server-side interface from Slice interface Ice::LocatorRegistry. Your service implementation must implement this interface.

Methods

SetAdapterDirectProxyAsync(string, ServiceAddress?, IFeatureCollection, CancellationToken)

Registers or unregisters the server addresses of an object adapter.

ValueTask SetAdapterDirectProxyAsync(string id, ServiceAddress? proxy, IFeatureCollection features, CancellationToken cancellationToken)

Parameters

id string

The adapter ID.

proxy ServiceAddress

A dummy service address created by the object adapter. proxy carries the object adapter's server addresses. The locator considers an object adapter to be active after it has registered its server addresses. When proxy is null, the server addresses are unregistered and the locator considers the object adapter inactive.

features IFeatureCollection

The dispatch features.

cancellationToken CancellationToken

A cancellation token that receives the cancellation requests.

Returns

ValueTask

A value task that completes when this implementation completes.

Exceptions

AdapterNotFoundException

Thrown if the locator only allows registered object adapters to register their active server addresses and no object adapter with this adapter ID was registered with the locator.

AdapterAlreadyActiveException

Thrown if an object adapter with the same adapter ID has already registered its server addresses.

SetReplicatedAdapterDirectProxyAsync(string, string, ServiceAddress?, IFeatureCollection, CancellationToken)

Registers or unregisters the server addresses of an object adapter. This object adapter is a member of a replica group.

ValueTask SetReplicatedAdapterDirectProxyAsync(string adapterId, string replicaGroupId, ServiceAddress? proxy, IFeatureCollection features, CancellationToken cancellationToken)

Parameters

adapterId string

The adapter ID.

replicaGroupId string

The replica group ID.

proxy ServiceAddress

A dummy service address created by the object adapter. proxy carries the object adapter's server addresses. The locator considers an object adapter to be active after it has registered its server addresses. When proxy is null, the server addresses are unregistered and the locator considers the object adapter inactive.

features IFeatureCollection

The dispatch features.

cancellationToken CancellationToken

A cancellation token that receives the cancellation requests.

Returns

ValueTask

A value task that completes when this implementation completes.

Exceptions

AdapterNotFoundException

Thrown if the locator only allows registered object adapters to register their active server addresses and no object adapter with this adapter ID was registered with the locator.

AdapterAlreadyActiveException

Thrown if an object adapter with the same adapter ID has already registered its server addresses.

InvalidReplicaGroupIdException

Thrown if the given replica group does not match the replica group associated with the adapter ID in the locator's database.

SetServerProcessProxyAsync(string, ProcessProxy, IFeatureCollection, CancellationToken)

Registers a proxy for the IProcess service of a server application.

ValueTask SetServerProcessProxyAsync(string serverId, ProcessProxy proxy, IFeatureCollection features, CancellationToken cancellationToken)

Parameters

serverId string

The server ID.

proxy ProcessProxy

A proxy for the Process service of the server application.

features IFeatureCollection

The dispatch features.

cancellationToken CancellationToken

A cancellation token that receives the cancellation requests.

Returns

ValueTask

A value task that completes when this implementation completes.

Exceptions

ServerNotFoundException

Thrown if the locator does not know a server application with this server ID.