Container for the parameters to the GetChangeTokenStatus operation. Returns the status of a ChangeToken that you got by calling GetChangeToken. ChangeTokenStatus is one of the following values:
  • PROVISIONED: You requested the change token by calling GetChangeToken, but you haven't used it yet in a call to create, update, or delete an AWS WAF object.

  • PENDING: AWS WAF is propagating the create, update, or delete request to all AWS WAF servers.

  • IN_SYNC: Propagation is complete.

Inheritance: AmazonWAFRequest
        public object Execute(ExecutorContext context)
        {
            var cmdletContext = context as CmdletContext;
            // create request
            var request = new Amazon.WAF.Model.GetChangeTokenStatusRequest();

            if (cmdletContext.ChangeToken != null)
            {
                request.ChangeToken = cmdletContext.ChangeToken;
            }

            CmdletOutput output;

            // issue call
            var client = Client ?? CreateClient(_CurrentCredentials, _RegionEndpoint);

            try
            {
                var    response       = CallAWSServiceOperation(client, request);
                object pipelineOutput = null;
                pipelineOutput = cmdletContext.Select(response, this);
                output         = new CmdletOutput
                {
                    PipelineOutput  = pipelineOutput,
                    ServiceResponse = response
                };
            }
            catch (Exception e)
            {
                output = new CmdletOutput {
                    ErrorResponse = e
                };
            }

            return(output);
        }
示例#2
0
        /// <summary>
        /// Initiates the asynchronous execution of the GetChangeTokenStatus operation.
        /// </summary>
        /// 
        /// <param name="request">Container for the necessary parameters to execute the GetChangeTokenStatus operation on AmazonWAFClient.</param>
        /// <param name="callback">An AsyncCallback delegate that is invoked when the operation completes.</param>
        /// <param name="state">A user-defined state object that is passed to the callback procedure. Retrieve this object from within the callback
        ///          procedure using the AsyncState property.</param>
        /// 
        /// <returns>An IAsyncResult that can be used to poll or wait for results, or both; this value is also needed when invoking EndGetChangeTokenStatus
        ///         operation.</returns>
        public IAsyncResult BeginGetChangeTokenStatus(GetChangeTokenStatusRequest request, AsyncCallback callback, object state)
        {
            var marshaller = new GetChangeTokenStatusRequestMarshaller();
            var unmarshaller = GetChangeTokenStatusResponseUnmarshaller.Instance;

            return BeginInvoke<GetChangeTokenStatusRequest>(request, marshaller, unmarshaller,
                callback, state);
        }
示例#3
0
        /// <summary>
        /// Returns the status of a <code>ChangeToken</code> that you got by calling <a>GetChangeToken</a>.
        /// <code>ChangeTokenStatus</code> is one of the following values:
        /// 
        ///  <ul> <li> <code>PROVISIONED</code>: You requested the change token by calling <code>GetChangeToken</code>,
        /// but you haven't used it yet in a call to create, update, or delete an AWS WAF object.</li>
        /// <li> <code>PENDING</code>: AWS WAF is propagating the create, update, or delete request
        /// to all AWS WAF servers.</li> <li> <code>IN_SYNC</code>: Propagation is complete.</li>
        /// </ul>
        /// </summary>
        /// <param name="request">Container for the necessary parameters to execute the GetChangeTokenStatus service method.</param>
        /// 
        /// <returns>The response from the GetChangeTokenStatus service method, as returned by WAF.</returns>
        /// <exception cref="Amazon.WAF.Model.WAFInternalErrorException">
        /// The operation failed because of a system problem, even though the request was valid.
        /// Retry your request.
        /// </exception>
        /// <exception cref="Amazon.WAF.Model.WAFNonexistentItemException">
        /// The operation failed because the referenced object doesn't exist.
        /// </exception>
        public GetChangeTokenStatusResponse GetChangeTokenStatus(GetChangeTokenStatusRequest request)
        {
            var marshaller = new GetChangeTokenStatusRequestMarshaller();
            var unmarshaller = GetChangeTokenStatusResponseUnmarshaller.Instance;

            return Invoke<GetChangeTokenStatusRequest,GetChangeTokenStatusResponse>(request, marshaller, unmarshaller);
        }
示例#4
0
 /// <summary>
 /// Returns the status of a <code>ChangeToken</code> that you got by calling <a>GetChangeToken</a>.
 /// <code>ChangeTokenStatus</code> is one of the following values:
 /// 
 ///  <ul> <li> <code>PROVISIONED</code>: You requested the change token by calling <code>GetChangeToken</code>,
 /// but you haven't used it yet in a call to create, update, or delete an AWS WAF object.</li>
 /// <li> <code>PENDING</code>: AWS WAF is propagating the create, update, or delete request
 /// to all AWS WAF servers.</li> <li> <code>IN_SYNC</code>: Propagation is complete.</li>
 /// </ul>
 /// </summary>
 /// <param name="changeToken">The change token for which you want to get the status. This change token was previously returned in the <code>GetChangeToken</code> response.</param>
 /// 
 /// <returns>The response from the GetChangeTokenStatus service method, as returned by WAF.</returns>
 /// <exception cref="Amazon.WAF.Model.WAFInternalErrorException">
 /// The operation failed because of a system problem, even though the request was valid.
 /// Retry your request.
 /// </exception>
 /// <exception cref="Amazon.WAF.Model.WAFNonexistentItemException">
 /// The operation failed because the referenced object doesn't exist.
 /// </exception>
 public GetChangeTokenStatusResponse GetChangeTokenStatus(string changeToken)
 {
     var request = new GetChangeTokenStatusRequest();
     request.ChangeToken = changeToken;
     return GetChangeTokenStatus(request);
 }
示例#5
0
        /// <summary>
        /// Initiates the asynchronous execution of the GetChangeTokenStatus operation.
        /// </summary>
        /// 
        /// <param name="request">Container for the necessary parameters to execute the GetChangeTokenStatus operation.</param>
        /// <param name="cancellationToken">
        ///     A cancellation token that can be used by other objects or threads to receive notice of cancellation.
        /// </param>
        /// <returns>The task object representing the asynchronous operation.</returns>
        public Task<GetChangeTokenStatusResponse> GetChangeTokenStatusAsync(GetChangeTokenStatusRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken))
        {
            var marshaller = new GetChangeTokenStatusRequestMarshaller();
            var unmarshaller = GetChangeTokenStatusResponseUnmarshaller.Instance;

            return InvokeAsync<GetChangeTokenStatusRequest,GetChangeTokenStatusResponse>(request, marshaller,
                unmarshaller, cancellationToken);
        }
示例#6
0
 /// <summary>
 /// Returns the status of a <code>ChangeToken</code> that you got by calling <a>GetChangeToken</a>.
 /// <code>ChangeTokenStatus</code> is one of the following values:
 /// 
 ///  <ul> <li><code>PROVISIONED</code>: You requested the change token by calling <code>GetChangeToken</code>,
 /// but you haven't used it yet in a call to create, update, or delete an AWS WAF object.</li>
 /// <li><code>PENDING</code>: AWS WAF is propagating the create, update, or delete request
 /// to all AWS WAF servers.</li> <li><code>IN_SYNC</code>: Propagation is complete.</li>
 /// </ul>
 /// </summary>
 /// <param name="changeToken">The change token for which you want to get the status. This change token was previously returned in the <code>GetChangeToken</code> response.</param>
 /// <param name="cancellationToken">
 ///     A cancellation token that can be used by other objects or threads to receive notice of cancellation.
 /// </param>
 /// 
 /// <returns>The response from the GetChangeTokenStatus service method, as returned by WAF.</returns>
 /// <exception cref="Amazon.WAF.Model.WAFInternalErrorException">
 /// The operation failed because of a system problem, even though the request was valid.
 /// Retry your request.
 /// </exception>
 /// <exception cref="Amazon.WAF.Model.WAFNonexistentItemException">
 /// The operation failed because the referenced object doesn't exist.
 /// </exception>
 public Task<GetChangeTokenStatusResponse> GetChangeTokenStatusAsync(string changeToken, System.Threading.CancellationToken cancellationToken = default(CancellationToken))
 {
     var request = new GetChangeTokenStatusRequest();
     request.ChangeToken = changeToken;
     return GetChangeTokenStatusAsync(request, cancellationToken);
 }
 private Amazon.WAF.Model.GetChangeTokenStatusResponse CallAWSServiceOperation(IAmazonWAF client, Amazon.WAF.Model.GetChangeTokenStatusRequest request)
 {
     Utils.Common.WriteVerboseEndpointMessage(this, client.Config, "AWS WAF", "GetChangeTokenStatus");
     try
     {
         #if DESKTOP
         return(client.GetChangeTokenStatus(request));
         #elif CORECLR
         return(client.GetChangeTokenStatusAsync(request).GetAwaiter().GetResult());
         #else
                 #error "Unknown build edition"
         #endif
     }
     catch (AmazonServiceException exc)
     {
         var webException = exc.InnerException as System.Net.WebException;
         if (webException != null)
         {
             throw new Exception(Utils.Common.FormatNameResolutionFailureMessage(client.Config, webException.Message), webException);
         }
         throw;
     }
 }