Skip to content

Commit 1be0f9e

Browse files
committed
Add [Obsolete("Please explicitly close connections instead.")] to IConnection.AutoClose.
1 parent 07f9089 commit 1be0f9e

File tree

4 files changed

+4
-0
lines changed

4 files changed

+4
-0
lines changed

projects/client/RabbitMQ.Client/src/client/api/IConnection.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,7 @@ public interface IConnection : NetworkConnection, IDisposable
7474
/// DON'T set AutoClose to true before opening the first
7575
/// channel, because the connection will be immediately closed if you do!
7676
/// </remarks>
77+
[Obsolete("Please explicitly close connections instead.")]
7778
bool AutoClose { get; set; }
7879

7980
/// <summary>

projects/client/RabbitMQ.Client/src/client/impl/AutorecoveringConnection.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -294,6 +294,7 @@ public event EventHandler<EventArgs> Recovery
294294

295295
public string ClientProvidedName { get; private set; }
296296

297+
[Obsolete("Please explicitly close connections instead.")]
297298
public bool AutoClose
298299
{
299300
get { return m_delegate.AutoClose; }

projects/client/RabbitMQ.Client/src/client/impl/Connection.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -273,6 +273,7 @@ public event EventHandler<ConnectionRecoveryErrorEventArgs> ConnectionRecoveryEr
273273
}
274274
public string ClientProvidedName { get; private set; }
275275

276+
[Obsolete("Please explicitly close connections instead.")]
276277
public bool AutoClose
277278
{
278279
get { return m_sessionManager.AutoClose; }

projects/client/RabbitMQ.Client/src/client/impl/SessionManager.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,7 @@ public SessionManager(Connection connection, ushort channelMax)
6868
Ints = new IntAllocator(1, ChannelMax);
6969
}
7070

71+
[Obsolete("Please explicitly close connections instead.")]
7172
public bool AutoClose
7273
{
7374
get { return m_autoClose; }

0 commit comments

Comments
 (0)