[][src]Struct cfn_custom_resource::CloudformationPayload

pub struct CloudformationPayload<T> {
    pub request_id: String,
    pub response_url: String,
    pub resource_type: String,
    pub logical_resource_id: String,
    pub stack_id: String,
    pub physical_resource_id: Option<Uuid>,
    pub resource_properties: T,
}

Defines the data that encapsualtes the payload sent by cloudformation to a lambda function. This includes all data in the payload except the inner event type. This structure is encapsulated by the CustomResourceEvent that defines that event type as well.

Fields

request_id: String

A unique ID for the request.

Combining the StackId with the RequestId forms a value that you can use to uniquely identify a request on a particular custom resource.

response_url: String

The response URL identifies a presigned S3 bucket that receives responses from the custom resource provider to AWS CloudFormation.

resource_type: String

The template developer-chosen resource type of the custom resource in the AWS CloudFormation template. Custom resource type names can be up to 60 characters long and can include alphanumeric and the following characters: _@-.

logical_resource_id: String

The template developer-chosen name (logical ID) of the custom resource in the AWS CloudFormation template. This is provided to facilitate communication between the custom resource provider and the template developer.

stack_id: String

The Amazon Resource Name (ARN) that identifies the stack that contains the custom resource.

Combining the StackId with the RequestId forms a value that you can use to uniquely identify a request on a particular custom resource.

physical_resource_id: Option<Uuid>

A required custom resource provider-defined physical ID that is unique for that provider. Always sent with Update and Delete requests; never sent with Create.

resource_properties: T

This field contains the contents of the Properties object sent by the template developer. Its contents are defined by the custom resource provider (you) and therefore is generic to accomedate any data set that you might have.

Implementations

impl<T> CloudformationPayload<T>[src]

pub fn respond_with_success(self, reason: &str) -> CustomResourceResponse[src]

Creates a response that indicates a failure.

pub fn respond_with_failure(self, reason: &str) -> CustomResourceResponse[src]

Creates a response that indicates a failure.

pub fn respond_with<D, E>(self, result: Result<D, E>) -> CustomResourceResponse where
    E: Error
[src]

Creates a response based on the request in question as well as the result of some operation executed prior this. If the result is Ok(_), then the response will be a success. If the response is Err(e), the response will be a failure where the error message is the error string.

Trait Implementations

impl<T: Debug> Debug for CloudformationPayload<T>[src]

impl<'de, T> Deserialize<'de> for CloudformationPayload<T> where
    T: Deserialize<'de>, 
[src]

impl<T: PartialEq> PartialEq<CloudformationPayload<T>> for CloudformationPayload<T>[src]

impl<T> StructuralPartialEq for CloudformationPayload<T>[src]

Auto Trait Implementations

impl<T> RefUnwindSafe for CloudformationPayload<T> where
    T: RefUnwindSafe

impl<T> Send for CloudformationPayload<T> where
    T: Send

impl<T> Sync for CloudformationPayload<T> where
    T: Sync

impl<T> Unpin for CloudformationPayload<T> where
    T: Unpin

impl<T> UnwindSafe for CloudformationPayload<T> where
    T: UnwindSafe

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,