Skip to content

Commit 3b73401

Browse files
committed
Merge pull request #412 from sharwell/obsolete-sync
Mark all synchronous extensions as obsolete
2 parents 1e59884 + 3b11724 commit 3b73401

9 files changed

Lines changed: 250 additions & 0 deletions

src/Documentation/Content/AsynchronousServices.aml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -228,6 +228,12 @@
228228
<section address="SynchronousExtensions">
229229
<title>Synchronous Extensions</title>
230230
<content>
231+
<alert class="warning">
232+
<para>
233+
All synchronous extension methods provided by this library are obsolete, and will be removed from a future
234+
release.
235+
</para>
236+
</alert>
231237
<para>
232238
The namespace <codeEntityReference>N:net.openstack.Core.Synchronous</codeEntityReference> contains extension
233239
methods that allow methods in an asynchronous service interface to be invoked synchronously. These extension

src/corelib/Core/Synchronous/AutoScaleServiceExtensions.cs

Lines changed: 24 additions & 0 deletions
Large diffs are not rendered by default.

src/corelib/Core/Synchronous/ClaimExtensions.cs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
/// </summary>
1414
/// <threadsafety static="true" instance="false"/>
1515
/// <preliminary/>
16+
[Obsolete("These synchronous wrappers should not be used. For more information, see http://blogs.msdn.com/b/pfxteam/archive/2012/04/13/10293638.aspx.")]
1617
public static class ClaimExtensions
1718
{
1819
/// <summary>
@@ -26,6 +27,7 @@ public static class ClaimExtensions
2627
/// <param name="claim">The claim.</param>
2728
/// <exception cref="ArgumentNullException">If <paramref name="claim"/> is <see langword="null"/>.</exception>
2829
/// <exception cref="WebException">If the REST request does not return successfully.</exception>
30+
[Obsolete("These synchronous wrappers should not be used. For more information, see http://blogs.msdn.com/b/pfxteam/archive/2012/04/13/10293638.aspx.")]
2931
public static void Refresh(this Claim claim)
3032
{
3133
if (claim == null)
@@ -61,6 +63,7 @@ public static void Refresh(this Claim claim)
6163
/// <exception cref="ArgumentOutOfRangeException">If <paramref name="timeToLive"/> is negative or <see cref="TimeSpan.Zero"/>.</exception>
6264
/// <exception cref="InvalidOperationException">If the claim is empty (i.e. <see cref="Claim.Messages"/> is empty).</exception>
6365
/// <exception cref="WebException">If the REST request does not return successfully.</exception>
66+
[Obsolete("These synchronous wrappers should not be used. For more information, see http://blogs.msdn.com/b/pfxteam/archive/2012/04/13/10293638.aspx.")]
6467
public static void Renew(this Claim claim, TimeSpan timeToLive)
6568
{
6669
if (claim == null)

src/corelib/Core/Synchronous/DatabaseServiceExtensions.cs

Lines changed: 29 additions & 0 deletions
Large diffs are not rendered by default.

src/corelib/Core/Synchronous/DnsServiceExtensions.cs

Lines changed: 26 additions & 0 deletions
Large diffs are not rendered by default.

src/corelib/Core/Synchronous/LoadBalancerServiceExtensions.cs

Lines changed: 62 additions & 0 deletions
Large diffs are not rendered by default.

src/corelib/Core/Synchronous/MonitoringServiceExtensions.cs

Lines changed: 73 additions & 0 deletions
Large diffs are not rendered by default.

src/corelib/Core/Synchronous/QueueingServiceExtensions.cs

Lines changed: 24 additions & 0 deletions
Large diffs are not rendered by default.

src/corelib/Core/Synchronous/ReadOnlyCollectionPageSynchronousExtensions.cs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
/// </summary>
1313
/// <threadsafety static="true" instance="false"/>
1414
/// <preliminary/>
15+
[Obsolete("These synchronous wrappers should not be used. For more information, see http://blogs.msdn.com/b/pfxteam/archive/2012/04/13/10293638.aspx.")]
1516
public static class ReadOnlyCollectionPageSynchronousExtensions
1617
{
1718
/// <summary>
@@ -30,6 +31,7 @@ public static class ReadOnlyCollectionPageSynchronousExtensions
3031
/// <returns>A read-only collection containing the complete set of results from the paginated collection.</returns>
3132
/// <exception cref="ArgumentNullException">If <paramref name="page"/> is <see langword="null"/>.</exception>
3233
/// <seealso cref="ReadOnlyCollectionPageExtensions.GetAllPagesAsync"/>
34+
[Obsolete("These synchronous wrappers should not be used. For more information, see http://blogs.msdn.com/b/pfxteam/archive/2012/04/13/10293638.aspx.")]
3335
public static ReadOnlyCollection<T> GetAllPages<T>(this ReadOnlyCollectionPage<T> page)
3436
{
3537
if (page == null)
@@ -58,6 +60,7 @@ public static ReadOnlyCollection<T> GetAllPages<T>(this ReadOnlyCollectionPage<T
5860
/// <exception cref="InvalidOperationException">If <see cref="ReadOnlyCollectionPage{T}.CanHaveNextPage"/> is <see langword="false"/>.</exception>
5961
/// <exception cref="WebException">If the REST request does not return successfully.</exception>
6062
/// <seealso cref="ReadOnlyCollectionPage{T}.GetNextPageAsync"/>
63+
[Obsolete("These synchronous wrappers should not be used. For more information, see http://blogs.msdn.com/b/pfxteam/archive/2012/04/13/10293638.aspx.")]
6164
public static ReadOnlyCollectionPage<T> GetNextPage<T>(this ReadOnlyCollectionPage<T> page)
6265
{
6366
if (page == null)

0 commit comments

Comments
 (0)