Class ConnectionFactory
  
  Represents a connection with a message broker
    Inheritance
    System.Object
    ConnectionFactory
      
   
  
    Implements
    Apache.NMS.IConnectionFactory
   
  
    Inherited Members
    
      System.Object.Equals(System.Object)
    
    
      System.Object.Equals(System.Object, System.Object)
    
    
      System.Object.GetHashCode()
    
    
      System.Object.GetType()
    
    
      System.Object.MemberwiseClone()
    
    
      System.Object.ReferenceEquals(System.Object, System.Object)
    
    
      System.Object.ToString()
    
   
  
  Assembly: Apache.NMS.ActiveMQ.dll
  Syntax
  
    public class ConnectionFactory : IConnectionFactory
   
  Constructors
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  ConnectionFactory()
  
  
  Declaration
  
    public ConnectionFactory()
   
  
    |
    Improve this Doc
  
  
    View Source
  
  
  ConnectionFactory(String)
  
  
  Declaration
  
    public ConnectionFactory(string brokerUri)
   
  Parameters
  
    
      
        | Type | Name | Description | 
    
    
      
        | System.String | brokerUri |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  ConnectionFactory(String, String)
  
  
  Declaration
  
    public ConnectionFactory(string brokerUri, string clientID)
   
  Parameters
  
    
      
        | Type | Name | Description | 
    
    
      
        | System.String | brokerUri |  | 
      
        | System.String | clientID |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  ConnectionFactory(Uri)
  
  
  Declaration
  
    public ConnectionFactory(Uri brokerUri)
   
  Parameters
  
    
      
        | Type | Name | Description | 
    
    
      
        | System.Uri | brokerUri |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  ConnectionFactory(Uri, String)
  
  
  Declaration
  
    public ConnectionFactory(Uri brokerUri, string clientID)
   
  Parameters
  
    
      
        | Type | Name | Description | 
    
    
      
        | System.Uri | brokerUri |  | 
      
        | System.String | clientID |  | 
    
  
  Fields
  
  
    |
    Improve this Doc
  
  
    View Source
  
  DEFAULT_BROKER_URL
  
  
  Declaration
  
    public const string DEFAULT_BROKER_URL = "failover:tcp://localhost:61616"
   
  Field Value
  
    
      
        | Type | Description | 
    
    
      
        | System.String |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  ENV_BROKER_URL
  
  
  Declaration
  
    public const string ENV_BROKER_URL = "ACTIVEMQ_BROKER_URL"
   
  Field Value
  
    
      
        | Type | Description | 
    
    
      
        | System.String |  | 
    
  
  Properties
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  AckMode
  
  
  Declaration
  
    public string AckMode { set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | System.String |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  AcknowledgementMode
  
  
  Declaration
  
    public AcknowledgementMode AcknowledgementMode { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | Apache.NMS.AcknowledgementMode |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  AlwaysSyncSend
  
  
  Declaration
  
    public bool AlwaysSyncSend { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | System.Boolean |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  AsyncClose
  
  
  Declaration
  
    public bool AsyncClose { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | System.Boolean |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  AsyncSend
  
  
  Declaration
  
    public bool AsyncSend { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | System.Boolean |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  AuditDepth
  
  
  Declaration
  
    public int AuditDepth { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | System.Int32 |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  AuditMaximumProducerNumber
  
  
  Declaration
  
    public int AuditMaximumProducerNumber { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | System.Int32 |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  BrokerUri
  Get/or set the broker Uri.
Declaration
  
    public Uri BrokerUri { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | System.Uri |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  CheckForDuplicates
  
  
  Declaration
  
    public bool CheckForDuplicates { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | System.Boolean |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  ClientId
  
  
  Declaration
  
    public string ClientId { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | System.String |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  ClientIdGenerator
  
  
  Declaration
  
    public IdGenerator ClientIdGenerator { get; set; }
   
  Property Value
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  ClientIdPrefix
  
  
  Declaration
  
    public string ClientIdPrefix { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | System.String |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  CompressionPolicy
  
  
  Declaration
  
    public ICompressionPolicy CompressionPolicy { get; set; }
   
  Property Value
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  ConsumerFailoverRedeliveryWaitPeriod
  
  
  Declaration
  
    public long ConsumerFailoverRedeliveryWaitPeriod { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | System.Int64 |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  
  A Delegate that is called each time a Message is dispatched to allow the client to do
any necessary transformations on the received message before it is delivered.  The
ConnectionFactory sets the provided delegate instance on each Connection instance that
is created from this factory, each connection in turn passes the delegate along to each
Session it creates which then passes that along to the Consumers it creates.
Declaration
  
    public ConsumerTransformerDelegate ConsumerTransformer { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | Apache.NMS.ConsumerTransformerDelegate |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  CopyMessageOnSend
  
  
  Declaration
  
    public bool CopyMessageOnSend { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | System.Boolean |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  DispatchAsync
  
  
  Declaration
  
    public bool DispatchAsync { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | System.Boolean |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  ExclusiveConsumer
  
  
  Declaration
  
    public bool ExclusiveConsumer { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | System.Boolean |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  MessagePrioritySupported
  
  
  Declaration
  
    public bool MessagePrioritySupported { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | System.Boolean |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  NonBlockingRedelivery
  
  
  Declaration
  
    public bool NonBlockingRedelivery { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | System.Boolean |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  OptimizeAcknowledge
  
  
  Declaration
  
    public bool OptimizeAcknowledge { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | System.Boolean |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  OptimizeAcknowledgeTimeOut
  
  
  Declaration
  
    public long OptimizeAcknowledgeTimeOut { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | System.Int64 |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  OptimizedAckScheduledAckInterval
  
  
  Declaration
  
    public long OptimizedAckScheduledAckInterval { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | System.Int64 |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  Password
  
  
  Declaration
  
    public string Password { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | System.String |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  PrefetchPolicy
  
  
  Declaration
  
    public PrefetchPolicy PrefetchPolicy { get; set; }
   
  Property Value
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  
  A delegate that is called each time a Message is sent from this Producer which allows
the application to perform any needed transformations on the Message before it is sent.
The ConnectionFactory sets the provided delegate instance on each Connection instance that
is created from this factory, each connection in turn passes the delegate along to each
Session it creates which then passes that along to the Producers it creates.
Declaration
  
    public ProducerTransformerDelegate ProducerTransformer { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | Apache.NMS.ProducerTransformerDelegate |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  ProducerWindowSize
  
  
  Declaration
  
    public int ProducerWindowSize { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | System.Int32 |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  RedeliveryPolicy
  
  
  Declaration
  
    public IRedeliveryPolicy RedeliveryPolicy { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | Apache.NMS.IRedeliveryPolicy |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  RequestTimeout
  
  
  Declaration
  
    public int RequestTimeout { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | System.Int32 |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  SendAcksAsync
  
  
  Declaration
  
    public bool SendAcksAsync { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | System.Boolean |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  TransactedIndividualAck
  
  
  Declaration
  
    public bool TransactedIndividualAck { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | System.Boolean |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  UseCompression
  
  
  Declaration
  
    public bool UseCompression { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | System.Boolean |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  UseRetroactiveConsumer
  
  
  Declaration
  
    public bool UseRetroactiveConsumer { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | System.Boolean |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  UserName
  
  
  Declaration
  
    public string UserName { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | System.String |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  WatchTopicAdvisories
  
  
  Declaration
  
    public bool WatchTopicAdvisories { get; set; }
   
  Property Value
  
    
      
        | Type | Description | 
    
    
      
        | System.Boolean |  | 
    
  
  Methods
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  
  
  
  Declaration
  
    protected virtual void ConfigureConnection(Connection connection)
   
  Parameters
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  CreateActiveMQConnection()
  
  
  Declaration
  
    protected virtual Connection CreateActiveMQConnection()
   
  Returns
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  CreateActiveMQConnection(ITransport)
  
  
  Declaration
  
    protected virtual Connection CreateActiveMQConnection(ITransport transport)
   
  Parameters
  
  Returns
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  CreateActiveMQConnection(String, String)
  
  
  Declaration
  
    protected virtual Connection CreateActiveMQConnection(string userName, string password)
   
  Parameters
  
    
      
        | Type | Name | Description | 
    
    
      
        | System.String | userName |  | 
      
        | System.String | password |  | 
    
  
  Returns
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  CreateConnection()
  
  
  Declaration
  
    public IConnection CreateConnection()
   
  Returns
  
    
      
        | Type | Description | 
    
    
      
        | Apache.NMS.IConnection |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  CreateConnection(String, String)
  
  
  Declaration
  
    public IConnection CreateConnection(string userName, string password)
   
  Parameters
  
    
      
        | Type | Name | Description | 
    
    
      
        | System.String | userName |  | 
      
        | System.String | password |  | 
    
  
  Returns
  
    
      
        | Type | Description | 
    
    
      
        | Apache.NMS.IConnection |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  ExceptionHandler(Exception)
  
  
  Declaration
  
    protected static void ExceptionHandler(Exception ex)
   
  Parameters
  
    
      
        | Type | Name | Description | 
    
    
      
        | System.Exception | ex |  | 
    
  
  
    |
    Improve this Doc
  
  
    View Source
  
  
  GetDefaultBrokerUrl()
  
  
  Declaration
  
    public static string GetDefaultBrokerUrl()
   
  Returns
  
    
      
        | Type | Description | 
    
    
      
        | System.String |  | 
    
  
  Events
  
  
    |
    Improve this Doc
  
  
    View Source
  
  OnException
  
  
  Declaration
  
    public event ExceptionListener OnException
   
  Event Type
  
    
      
        | Type | Description | 
    
    
      
        | Apache.NMS.ExceptionListener |  | 
    
  
  Implements
  
      Apache.NMS.IConnectionFactory