/// <summary> /// Exports optimization recommendations for Amazon EC2 instances. /// /// /// <para> /// Recommendations are exported in a comma-separated values (.csv) file, and its metadata /// in a JavaScript Object Notation (.json) file, to an existing Amazon Simple Storage /// Service (Amazon S3) bucket that you specify. For more information, see <a href="https://docs.aws.amazon.com/compute-optimizer/latest/ug/exporting-recommendations.html">Exporting /// Recommendations</a> in the <i>Compute Optimizer User Guide</i>. /// </para> /// /// <para> /// You can have only one Amazon EC2 instance export job in progress per AWS Region. /// </para> /// </summary> /// <param name="request">Container for the necessary parameters to execute the ExportEC2InstanceRecommendations service method.</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 ExportEC2InstanceRecommendations service method, as returned by ComputeOptimizer.</returns> /// <exception cref="Amazon.ComputeOptimizer.Model.AccessDeniedException"> /// You do not have sufficient access to perform this action. /// </exception> /// <exception cref="Amazon.ComputeOptimizer.Model.InternalServerException"> /// An internal error has occurred. Try your call again. /// </exception> /// <exception cref="Amazon.ComputeOptimizer.Model.InvalidParameterValueException"> /// An invalid or out-of-range value was supplied for the input parameter. /// </exception> /// <exception cref="Amazon.ComputeOptimizer.Model.LimitExceededException"> /// The request exceeds a limit of the service. /// </exception> /// <exception cref="Amazon.ComputeOptimizer.Model.MissingAuthenticationTokenException"> /// The request must contain either a valid (registered) AWS access key ID or X.509 certificate. /// </exception> /// <exception cref="Amazon.ComputeOptimizer.Model.OptInRequiredException"> /// The account is not opted in to AWS Compute Optimizer. /// </exception> /// <exception cref="Amazon.ComputeOptimizer.Model.ServiceUnavailableException"> /// The request has failed due to a temporary failure of the server. /// </exception> /// <exception cref="Amazon.ComputeOptimizer.Model.ThrottlingException"> /// The request was denied due to request throttling. /// </exception> /// <seealso href="http://docs.aws.amazon.com/goto/WebAPI/compute-optimizer-2019-11-01/ExportEC2InstanceRecommendations">REST API Reference for ExportEC2InstanceRecommendations Operation</seealso> public virtual Task <ExportEC2InstanceRecommendationsResponse> ExportEC2InstanceRecommendationsAsync(ExportEC2InstanceRecommendationsRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = ExportEC2InstanceRecommendationsRequestMarshaller.Instance; options.ResponseUnmarshaller = ExportEC2InstanceRecommendationsResponseUnmarshaller.Instance; return(InvokeAsync <ExportEC2InstanceRecommendationsResponse>(request, options, cancellationToken)); }
internal virtual ExportEC2InstanceRecommendationsResponse ExportEC2InstanceRecommendations(ExportEC2InstanceRecommendationsRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = ExportEC2InstanceRecommendationsRequestMarshaller.Instance; options.ResponseUnmarshaller = ExportEC2InstanceRecommendationsResponseUnmarshaller.Instance; return(Invoke <ExportEC2InstanceRecommendationsResponse>(request, options)); }