Beispiel #1
0
 /// <summary>
 /// Get a SQL pool's blob auditing policy
 /// </summary>
 /// <remarks>
 /// Get a SQL pool's blob auditing policy.
 /// </remarks>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group. The name is case insensitive.
 /// </param>
 /// <param name='workspaceName'>
 /// The name of the workspace
 /// </param>
 /// <param name='sqlPoolName'>
 /// SQL pool name
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <SqlPoolBlobAuditingPolicy> GetAsync(this ISqlPoolBlobAuditingPoliciesOperations operations, string resourceGroupName, string workspaceName, string sqlPoolName, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.GetWithHttpMessagesAsync(resourceGroupName, workspaceName, sqlPoolName, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Beispiel #2
0
 public bool SetAuditingPolicy(string resourceGroupName, string workspaceName,
                               string sqlPoolName, SqlPoolBlobAuditingPolicy policy)
 {
     return(SetAuditingPolicyInternal(() =>
     {
         ISqlPoolBlobAuditingPoliciesOperations operations = GetCurrentSynapseManagementClient().SqlPoolBlobAuditingPolicies;
         return operations.CreateOrUpdateWithHttpMessagesAsync(resourceGroupName,
                                                               workspaceName, sqlPoolName, policy).Result.Response.IsSuccessStatusCode;
     }));
 }
Beispiel #3
0
 /// <summary>
 /// Creates or updates a SQL pool's blob auditing policy
 /// </summary>
 /// <remarks>
 /// Creates or updates a SQL pool's blob auditing policy.
 /// </remarks>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group. The name is case insensitive.
 /// </param>
 /// <param name='workspaceName'>
 /// The name of the workspace
 /// </param>
 /// <param name='sqlPoolName'>
 /// SQL pool name
 /// </param>
 /// <param name='parameters'>
 /// The database blob auditing policy.
 /// </param>
 public static SqlPoolBlobAuditingPolicy CreateOrUpdate(this ISqlPoolBlobAuditingPoliciesOperations operations, string resourceGroupName, string workspaceName, string sqlPoolName, SqlPoolBlobAuditingPolicy parameters)
 {
     return(operations.CreateOrUpdateAsync(resourceGroupName, workspaceName, sqlPoolName, parameters).GetAwaiter().GetResult());
 }
Beispiel #4
0
 /// <summary>
 /// Get a SQL pool's blob auditing policy
 /// </summary>
 /// <remarks>
 /// Get a SQL pool's blob auditing policy.
 /// </remarks>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The name of the resource group. The name is case insensitive.
 /// </param>
 /// <param name='workspaceName'>
 /// The name of the workspace
 /// </param>
 /// <param name='sqlPoolName'>
 /// SQL pool name
 /// </param>
 public static SqlPoolBlobAuditingPolicy Get(this ISqlPoolBlobAuditingPoliciesOperations operations, string resourceGroupName, string workspaceName, string sqlPoolName)
 {
     return(operations.GetAsync(resourceGroupName, workspaceName, sqlPoolName).GetAwaiter().GetResult());
 }
Beispiel #5
0
 /// <summary>
 /// Lists auditing settings of a Sql pool.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='nextPageLink'>
 /// The NextLink from the previous successful call to List operation.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <IPage <SqlPoolBlobAuditingPolicy> > ListBySqlPoolNextAsync(this ISqlPoolBlobAuditingPoliciesOperations operations, string nextPageLink, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.ListBySqlPoolNextWithHttpMessagesAsync(nextPageLink, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Beispiel #6
0
 /// <summary>
 /// Lists auditing settings of a Sql pool.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='nextPageLink'>
 /// The NextLink from the previous successful call to List operation.
 /// </param>
 public static IPage <SqlPoolBlobAuditingPolicy> ListBySqlPoolNext(this ISqlPoolBlobAuditingPoliciesOperations operations, string nextPageLink)
 {
     return(operations.ListBySqlPoolNextAsync(nextPageLink).GetAwaiter().GetResult());
 }