Inheritance: ISerializable, IDeserializationCallback
        public ProfiledSqlClientBatchingBatcher(ConnectionManager connectionManager, IInterceptor interceptor) : base(connectionManager, interceptor)
        {
            _batchSize = Factory.Settings.AdoBatchSize;
            _defaultTimeout = PropertiesHelper.GetInt32(global::NHibernate.Cfg.Environment.CommandTimeout, global::NHibernate.Cfg.Environment.Properties, -1);

            _currentBatch = CreateConfiguredBatch();
            _currentBatchCommandsLog = new StringBuilder().AppendLine("Batch commands:");
        }
		public OracleDataClientBatchingBatcher(ConnectionManager connectionManager, IInterceptor interceptor)
			: base(connectionManager, interceptor)
		{
			batchSize = Factory.Settings.AdoBatchSize;
            //we always create this, because we need to deal with a scenario in which
            //the user change the logging configuration at runtime. Trying to put this
            //behind an if(log.IsDebugEnabled) will cause a null reference exception 
            //at that point.
            currentBatchCommandsLog = new StringBuilder().AppendLine("Batch commands:");
        }
        public ProfiledSqlClientBatchingBatcher(ConnectionManager connectionManager, IInterceptor interceptor)
            : base(connectionManager, interceptor)
        {
            batchSize = Factory.Settings.AdoBatchSize;
            defaultTimeout = PropertiesHelper.GetInt32(NHibernate.Cfg.Environment.CommandTimeout, NHibernate.Cfg.Environment.Properties, -1);

            currentBatch = CreateConfiguredBatch();
            //we always create this, because we need to deal with a scenario in which
            //the user change the logging configuration at runtime. Trying to put this
            //behind an if(log.IsDebugEnabled) will cause a null reference exception 
            //at that point.
            currentBatchCommandsLog = new StringBuilder().AppendLine("Batch commands:");
        }
		/// <summary>
		/// Initializes a new instance of the <see cref="NonBatchingBatcher"/> class.
		/// </summary>
		/// <param name="connectionManager">The <see cref="ConnectionManager"/> for this batcher.</param>
		public NonBatchingBatcher(ConnectionManager connectionManager)
			: base(connectionManager)
		{
		}
		/// <summary>
		/// Initializes a new instance of the <see cref="AbstractBatcher"/> class.
		/// </summary>
		/// <param name="connectionManager">The <see cref="ConnectionManager"/> owning this batcher.</param>
		/// <param name="interceptor"></param>
		protected AbstractBatcher(ConnectionManager connectionManager, IInterceptor interceptor)
		{
			_connectionManager = connectionManager;
			_interceptor = interceptor;
			_factory = connectionManager.Factory;
		}
Beispiel #6
0
 public StopFlushingFromDtcTransaction(ConnectionManager manager)
 {
     this.manager = manager;
 }
 public override global::NHibernate.Engine.IBatcher CreateBatcher(ConnectionManager connectionManager, global::NHibernate.IInterceptor interceptor)
 {
     return new ProfiledSqlClientBatchingBatcher(connectionManager, interceptor);
 }
 public IBatcher CreateBatcher(ConnectionManager connectionManager)
 {
     return _target.CreateBatcher(connectionManager);
 }
Beispiel #9
0
		/// <summary>
		/// Initializes a new instance of the <see cref="AbstractBatcher"/> class.
		/// </summary>
		/// <param name="connectionManager">The <see cref="ConnectionManager"/> owning this batcher.</param>
		/// <param name="interceptor"></param>
		public AbstractBatcher(ConnectionManager connectionManager, IInterceptor interceptor)
		{
			this.connectionManager = connectionManager;
			this.interceptor = interceptor;
			factory = connectionManager.Factory;
		}
			public StatsBatcher(ConnectionManager connectionManager, IInterceptor interceptor)
				: base(connectionManager, interceptor) {}
			public IBatcher CreateBatcher(ConnectionManager connectionManager, IInterceptor interceptor)
			{
				return new TimeoutCatchingNonBatchingBatcher(connectionManager, interceptor);
			}
			public IBatcher CreateBatcher(ConnectionManager connectionManager, IInterceptor interceptor)
			{
				return new StatsBatcher(connectionManager, interceptor);
			}
 public override IBatcher CreateBatcher(ConnectionManager connectionManager, IInterceptor interceptor)
 {
     return new ProfiledSqlClientBatchingBatcher(connectionManager, interceptor);
 }
 public IBatcher CreateBatcher(ConnectionManager connectionManager)
 {
     var batcher = _innerDriver.CreateBatcher(connectionManager);
     return batcher;
 }
 public OracleDataClientBatchingBatcher(ConnectionManager connectionManager, IInterceptor interceptor)
     : base(connectionManager, interceptor)
 {
     batchSize = Factory.Settings.AdoBatchSize;
 }
        public OracleDataClientBatchingBatcher(ConnectionManager connectionManager)
			: base(connectionManager)
		{
			batchSize = Factory.BatchSize;
		}
		public SqlClientBatchingBatcher(ConnectionManager connectionManager, IInterceptor interceptor)
			: base(connectionManager, interceptor)
		{
			batchSize = Factory.Settings.AdoBatchSize;
			currentBatch = new SqlClientSqlCommandSet();
		}
		public virtual IBatcher CreateBatcher(ConnectionManager connectionManager, IInterceptor interceptor)
		{
			return new SqlClientBatchingBatcher(connectionManager, interceptor);
		}
 public ReliableSqlClientBatchingBatcher(ConnectionManager connectionManager, IInterceptor interceptor)
     : base(connectionManager, interceptor)
 {
     _connectionManager = connectionManager;
 }
		/// <summary>
		/// Initializes a new instance of the <see cref="BatcherImpl"/> class.
		/// </summary>
		/// <param name="connectionManager">The <see cref="ConnectionManager"/> owning this batcher.</param>
		public BatcherImpl(ConnectionManager connectionManager)
		{
			this.connectionManager = connectionManager;
			this.factory = connectionManager.Factory;
		}
		/// <summary>
		/// Initializes a new instance of the <see cref="NonBatchingBatcher"/> class.
		/// </summary>
		/// <param name="connectionManager">The <see cref="ConnectionManager"/> for this batcher.</param>
		/// <param name="interceptor"></param>
		public NonBatchingBatcher(ConnectionManager connectionManager, IInterceptor interceptor)
			: base(connectionManager, interceptor)
		{
		}
 public StopFlushingFromDtcTransaction(ConnectionManager manager)
 {
     this.manager = manager;
 }
 protected CommandSetBatchingBatcher(ConnectionManager connectionManager)
     : base(connectionManager)
 {
     batchSize = Factory.BatchSize;
 }