public EndpointPerformanceMetric(Address endpoint, TimeSpan averageTimeToProcess, TimeSpan averageTimeToDeliver, int totalMessagesProcessed)
     : this()
 {
     Endpoint = endpoint;
     AverageTimeToDeliver = averageTimeToDeliver;
     AverageTimeToProcess = averageTimeToProcess;
     TotalMessagesProcessed = totalMessagesProcessed;
 }
示例#2
0
 static Address()
 {
     undefined = new Address("__UNDEFINED__", String.Empty);
     local = undefined;
 }
示例#3
0
        /// <summary>
        /// Check this is equal to other Address
        /// </summary>
        /// <param name="other">reference addressed to be checked with this</param>
        /// <returns>true if this is equal to other</returns>
        private bool Equals(Address other)
        {
            if (ReferenceEquals(null, other)) return false;
            if (ReferenceEquals(this, other)) return true;

            if (!ignoreMachineName && !other.machine.Equals(machine))
                return false;

            return other.queue.Equals(queue);
        }
示例#4
0
 /// <summary>
 /// Sets the address of this endpoint.
 /// </summary>
 /// <param name="queue">The queue name.</param>
 public static void InitializeLocalAddress(string queue)
 {
     local = Parse(queue);
 }
示例#5
0
        public void Send(Address address, Guid corrolationId, ICollection<object> commands)
        {
            if (commands == null || !commands.Any())
            {
                return;
            }

            MessageEnvelope message = BuildMessageEnvelope(commands, corrolationId);
            messageTransport.Send(message, address);
        }
示例#6
0
 public void Send(Address address, Guid corrolationId, object command)
 {
     Send(address, corrolationId, new[] { command });
 }
示例#7
0
 public void Send(Address address, ICollection<object> commands)
 {
     Send(address, Guid.Empty, commands);
 }
示例#8
0
 public void Send(Address address, object command)
 {
     Send(address, Guid.Empty, new[] { command });
 }