internal virtual CreateDeliveryStreamResponse CreateDeliveryStream(CreateDeliveryStreamRequest request) { var marshaller = new CreateDeliveryStreamRequestMarshaller(); var unmarshaller = CreateDeliveryStreamResponseUnmarshaller.Instance; return(Invoke <CreateDeliveryStreamRequest, CreateDeliveryStreamResponse>(request, marshaller, unmarshaller)); }
/// <summary> /// Initiates the asynchronous execution of the CreateDeliveryStream operation. /// </summary> /// /// <param name="request">Container for the necessary parameters to execute the CreateDeliveryStream 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> /// <seealso href="http://docs.aws.amazon.com/goto/WebAPI/firehose-2015-08-04/CreateDeliveryStream">REST API Reference for CreateDeliveryStream Operation</seealso> public virtual Task <CreateDeliveryStreamResponse> CreateDeliveryStreamAsync(CreateDeliveryStreamRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var marshaller = new CreateDeliveryStreamRequestMarshaller(); var unmarshaller = CreateDeliveryStreamResponseUnmarshaller.Instance; return(InvokeAsync <CreateDeliveryStreamRequest, CreateDeliveryStreamResponse>(request, marshaller, unmarshaller, cancellationToken)); }
/// <summary> /// Initiates the asynchronous execution of the CreateDeliveryStream operation. /// </summary> /// /// <param name="request">Container for the necessary parameters to execute the CreateDeliveryStream operation on AmazonKinesisFirehoseClient.</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 EndCreateDeliveryStream /// operation.</returns> public IAsyncResult BeginCreateDeliveryStream(CreateDeliveryStreamRequest request, AsyncCallback callback, object state) { var marshaller = new CreateDeliveryStreamRequestMarshaller(); var unmarshaller = CreateDeliveryStreamResponseUnmarshaller.Instance; return(BeginInvoke <CreateDeliveryStreamRequest>(request, marshaller, unmarshaller, callback, state)); }
/// <summary> /// Initiates the asynchronous execution of the CreateDeliveryStream operation. /// </summary> /// /// <param name="request">Container for the necessary parameters to execute the CreateDeliveryStream operation on AmazonKinesisFirehoseClient.</param> /// <param name="callback">An Action delegate that is invoked when the operation completes.</param> /// <param name="options">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> /// <seealso href="http://docs.aws.amazon.com/goto/WebAPI/firehose-2015-08-04/CreateDeliveryStream">REST API Reference for CreateDeliveryStream Operation</seealso> public void CreateDeliveryStreamAsync(CreateDeliveryStreamRequest request, AmazonServiceCallback <CreateDeliveryStreamRequest, CreateDeliveryStreamResponse> callback, AsyncOptions options = null) { options = options == null?new AsyncOptions():options; var marshaller = new CreateDeliveryStreamRequestMarshaller(); var unmarshaller = CreateDeliveryStreamResponseUnmarshaller.Instance; Action <AmazonWebServiceRequest, AmazonWebServiceResponse, Exception, AsyncOptions> callbackHelper = null; if (callback != null) { callbackHelper = (AmazonWebServiceRequest req, AmazonWebServiceResponse res, Exception ex, AsyncOptions ao) => { AmazonServiceResult <CreateDeliveryStreamRequest, CreateDeliveryStreamResponse> responseObject = new AmazonServiceResult <CreateDeliveryStreamRequest, CreateDeliveryStreamResponse>((CreateDeliveryStreamRequest)req, (CreateDeliveryStreamResponse)res, ex, ao.State); callback(responseObject); } } ; BeginInvoke <CreateDeliveryStreamRequest>(request, marshaller, unmarshaller, options, callbackHelper); }
public void CreateDeliveryStreamMarshallTest() { var request = InstantiateClassGenerator.Execute<CreateDeliveryStreamRequest>(); var marshaller = new CreateDeliveryStreamRequestMarshaller(); var internalRequest = marshaller.Marshall(request); var jsonRequest = UTF8Encoding.UTF8.GetString(internalRequest.Content); Comparer.CompareObjectToJson<CreateDeliveryStreamRequest>(request,jsonRequest); var webResponse = new WebResponseData { Headers = { {"x-amzn-RequestId", Guid.NewGuid().ToString()}, {"x-amz-crc32","0"} } }; var jsonResponse = new JsonSampleGenerator(service_model, service_model.FindOperation("CreateDeliveryStream").ResponseStructure).Execute(); webResponse.Headers.Add("Content-Length", UTF8Encoding.UTF8.GetBytes(jsonResponse).Length.ToString()); UnmarshallerContext context = new JsonUnmarshallerContext(Utils.CreateStreamFromString(jsonResponse), false, webResponse); var response = CreateDeliveryStreamResponseUnmarshaller.Instance.Unmarshall(context) as CreateDeliveryStreamResponse; InstantiateClassGenerator.ValidateObjectFullyInstantiated(response); }
/// <summary> /// Initiates the asynchronous execution of the CreateDeliveryStream operation. /// </summary> /// /// <param name="request">Container for the necessary parameters to execute the CreateDeliveryStream 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<CreateDeliveryStreamResponse> CreateDeliveryStreamAsync(CreateDeliveryStreamRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var marshaller = new CreateDeliveryStreamRequestMarshaller(); var unmarshaller = CreateDeliveryStreamResponseUnmarshaller.Instance; return InvokeAsync<CreateDeliveryStreamRequest,CreateDeliveryStreamResponse>(request, marshaller, unmarshaller, cancellationToken); }
/// <summary> /// Creates a delivery stream. /// /// /// <para> /// <a>CreateDeliveryStream</a> is an asynchronous operation that immediately returns. /// The initial status of the delivery stream is <code>CREATING</code>. After the delivery /// stream is created, its status is <code>ACTIVE</code> and it now accepts data. Attempts /// to send data to a delivery stream that is not in the <code>ACTIVE</code> state cause /// an exception. To check the state of a delivery stream, use <a>DescribeDeliveryStream</a>. /// </para> /// /// <para> /// The name of a delivery stream identifies it. You can't have two delivery streams with /// the same name in the same region. Two delivery streams in different AWS accounts or /// different regions in the same AWS account can have the same name. /// </para> /// /// <para> /// By default, you can create up to 5 delivery streams per region. /// </para> /// /// <para> /// A delivery stream can only be configured with a single destination, Amazon S3 or Amazon /// Redshift. For correct <a>CreateDeliveryStream</a> request syntax, specify only one /// destination configuration parameter: either <code>RedshiftDestinationConfiguration</code> /// or <code>S3DestinationConfiguration</code> /// </para> /// /// <para> /// As part of <code>S3DestinationConfiguration</code>, optional values <code>BufferingHints</code>, /// <code>EncryptionConfiguration</code>, and <code>CompressionFormat</code> can be provided. /// By default, if no <code>BufferingHints</code> value is provided, Amazon Kinesis Firehose /// buffers data up to 5 MB or for 5 minutes, whichever condition is satisfied first. /// Note that <code>BufferingHints</code> is a hint, so there are some cases where the /// service cannot adhere to these conditions strictly; for example, record boundaries /// are such that the size is a little over or under the configured buffering size. By /// default, no encryption is performed. We strongly recommend that you enable encryption /// to ensure secure data storage in Amazon S3. /// </para> /// /// <para> /// A few notes about <code>RedshiftDestinationConfiguration</code>: /// </para> /// <ul> <li>An Amazon Redshift destination requires an S3 bucket as intermediate location, /// as Amazon Kinesis Firehose first delivers data to S3 and then uses <code>COPY</code> /// syntax to load data into an Amazon Redshift table. This is specified in the <code>RedshiftDestinationConfiguration.S3Configuration</code> /// parameter element.</li> <li>The compression formats <code>SNAPPY</code> or <code>ZIP</code> /// cannot be specified in <code>RedshiftDestinationConfiguration.S3Configuration</code> /// because the Amazon Redshift <code>COPY</code> operation that reads from the S3 bucket /// doesn't support these compression formats.</li> <li>We strongly recommend that the /// username and password provided is used exclusively for Amazon Kinesis Firehose purposes, /// and that the permissions for the account are restricted for Amazon Redshift <code>INSERT</code> /// permissions.</li> </ul> /// <para> /// Amazon Kinesis Firehose assumes the IAM role that is configured as part of destinations. /// The IAM role should allow the Amazon Kinesis Firehose principal to assume the role, /// and the role should have permissions that allows the service to deliver the data. /// For more information, see <a href="http://docs.aws.amazon.com/firehose/latest/dev/controlling-access.html#using-iam-s3">Amazon /// S3 Bucket Access</a> in the <i>Amazon Kinesis Firehose Developer Guide</i>. /// </para> /// </summary> /// <param name="request">Container for the necessary parameters to execute the CreateDeliveryStream service method.</param> /// /// <returns>The response from the CreateDeliveryStream service method, as returned by KinesisFirehose.</returns> /// <exception cref="Amazon.KinesisFirehose.Model.InvalidArgumentException"> /// The specified input parameter has an value that is not valid. /// </exception> /// <exception cref="Amazon.KinesisFirehose.Model.LimitExceededException"> /// You have already reached the limit for a requested resource. /// </exception> /// <exception cref="Amazon.KinesisFirehose.Model.ResourceInUseException"> /// The resource is already in use and not available for this operation. /// </exception> public CreateDeliveryStreamResponse CreateDeliveryStream(CreateDeliveryStreamRequest request) { var marshaller = new CreateDeliveryStreamRequestMarshaller(); var unmarshaller = CreateDeliveryStreamResponseUnmarshaller.Instance; return Invoke<CreateDeliveryStreamRequest,CreateDeliveryStreamResponse>(request, marshaller, unmarshaller); }
/// <summary> /// Initiates the asynchronous execution of the CreateDeliveryStream operation. /// </summary> /// /// <param name="request">Container for the necessary parameters to execute the CreateDeliveryStream operation on AmazonKinesisFirehoseClient.</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 EndCreateDeliveryStream /// operation.</returns> public IAsyncResult BeginCreateDeliveryStream(CreateDeliveryStreamRequest request, AsyncCallback callback, object state) { var marshaller = new CreateDeliveryStreamRequestMarshaller(); var unmarshaller = CreateDeliveryStreamResponseUnmarshaller.Instance; return BeginInvoke<CreateDeliveryStreamRequest>(request, marshaller, unmarshaller, callback, state); }
/// <summary> /// Initiates the asynchronous execution of the CreateDeliveryStream operation. /// </summary> /// /// <param name="request">Container for the necessary parameters to execute the CreateDeliveryStream operation on AmazonKinesisFirehoseClient.</param> /// <param name="callback">An Action delegate that is invoked when the operation completes.</param> /// <param name="options">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> public void CreateDeliveryStreamAsync(CreateDeliveryStreamRequest request, AmazonServiceCallback<CreateDeliveryStreamRequest, CreateDeliveryStreamResponse> callback, AsyncOptions options = null) { options = options == null?new AsyncOptions():options; var marshaller = new CreateDeliveryStreamRequestMarshaller(); var unmarshaller = CreateDeliveryStreamResponseUnmarshaller.Instance; Action<AmazonWebServiceRequest, AmazonWebServiceResponse, Exception, AsyncOptions> callbackHelper = null; if(callback !=null ) callbackHelper = (AmazonWebServiceRequest req, AmazonWebServiceResponse res, Exception ex, AsyncOptions ao) => { AmazonServiceResult<CreateDeliveryStreamRequest,CreateDeliveryStreamResponse> responseObject = new AmazonServiceResult<CreateDeliveryStreamRequest,CreateDeliveryStreamResponse>((CreateDeliveryStreamRequest)req, (CreateDeliveryStreamResponse)res, ex , ao.State); callback(responseObject); }; BeginInvoke<CreateDeliveryStreamRequest>(request, marshaller, unmarshaller, options, callbackHelper); }