Class AbstractDiscoveryAgent
- Namespace
- Apache.NMS.ActiveMQ.Transport.Discovery
- Assembly
- Apache.NMS.ActiveMQ.dll
public abstract class AbstractDiscoveryAgent : IDiscoveryAgent, IStartable, IStoppable, IDisposable
- Inheritance
-
AbstractDiscoveryAgent
- Implements
-
IStartable
IStoppable
- Derived
-
- Inherited Members
-
Constructors
AbstractDiscoveryAgent()
protected AbstractDiscoveryAgent()
Fields
DEFAULT_BACKOFF_MULTIPLIER
public const int DEFAULT_BACKOFF_MULTIPLIER = 2
Field Value
- int
DEFAULT_INITIAL_RECONNECT_DELAY
public const int DEFAULT_INITIAL_RECONNECT_DELAY = 5000
Field Value
- int
DEFAULT_MAX_RECONNECT_DELAY
public const int DEFAULT_MAX_RECONNECT_DELAY = 30000
Field Value
- int
discoveredServices
protected Dictionary<string, DiscoveredServiceData> discoveredServices
Field Value
- Dictionary<string, DiscoveredServiceData>
discoveredServicesLock
protected readonly object discoveredServicesLock
Field Value
- object
executor
protected readonly ThreadPoolExecutor executor
Field Value
- ThreadPoolExecutor
started
protected readonly Atomic<bool> started
Field Value
- Atomic<bool>
worker
Field Value
- Thread
Properties
BackOffMultiplier
public long BackOffMultiplier { get; set; }
Property Value
- long
DiscoveryURI
public Uri DiscoveryURI { get; set; }
Property Value
- Uri
Group
public string Group { get; set; }
Property Value
- string
InitialReconnectDelay
public long InitialReconnectDelay { get; set; }
Property Value
- long
IsStarted
public bool IsStarted { get; }
Property Value
- bool
KeepAliveInterval
public abstract long KeepAliveInterval { get; set; }
Property Value
- long
MaxReconnectAttempts
public int MaxReconnectAttempts { get; set; }
Property Value
- int
MaxReconnectDelay
public long MaxReconnectDelay { get; set; }
Property Value
- long
ServiceAdd
public ServiceAddHandler ServiceAdd { get; set; }
Property Value
- ServiceAddHandler
ServiceRemove
public ServiceRemoveHandler ServiceRemove { get; set; }
Property Value
- ServiceRemoveHandler
UseExponentialBackOff
public bool UseExponentialBackOff { get; set; }
Property Value
- bool
Methods
Dispose()
DoAdvertizeSelf()
protected abstract void DoAdvertizeSelf()
DoDiscovery()
protected abstract void DoDiscovery()
DoStartAgent()
protected abstract void DoStartAgent()
DoStopAgent()
protected abstract void DoStopAgent()
FireServiceAddEvent(DiscoveryEvent)
protected void FireServiceAddEvent(DiscoveryEvent data)
Parameters
data DiscoveryEvent
FireServiceRemoveEvent(DiscoveryEvent)
protected void FireServiceRemoveEvent(DiscoveryEvent data)
Parameters
data DiscoveryEvent
IsTimeForRecovery(DiscoveredServiceData)
public bool IsTimeForRecovery(DiscoveredServiceData service)
Parameters
service DiscoveredServiceData
Returns
- bool
ProcessDeadService(string)
protected void ProcessDeadService(string service)
Parameters
service string
ProcessLiveService(string, string)
protected void ProcessLiveService(string brokerName, string service)
Parameters
brokerName string
service string
RegisterService(string)
public void RegisterService(string name)
Parameters
name string
ServiceFailed(DiscoveryEvent)
public void ServiceFailed(DiscoveryEvent failedEvent)
Parameters
failedEvent DiscoveryEvent
Start()
Stop()