Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Co-authored-by: Momo Kornher <[email protected]>
  • Loading branch information
WtfJoke and mrgrain committed May 14, 2024
1 parent 71acc78 commit fc63265
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
8 changes: 4 additions & 4 deletions packages/@aws-cdk/aws-pipes-targets-alpha/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ Pipe targets are the end point of a EventBridge Pipe.
The following targets are supported:

1. `targets.SqsTarget`: [Send event source to a Queue](#amazon-sqs)
2. `targets.StateMachineTarget`: [Start a State Machine from an event source](#aws-step-functions)
2. `targets.SfnStateMachine`: [Invoke a State Machine from an event source](#aws-step-functions)

### Amazon SQS

Expand Down Expand Up @@ -69,7 +69,7 @@ const pipe = new pipes.Pipe(this, 'Pipe', {
});
```

### AWS Step Functions
### AWS Step Functions State Machine

A State Machine can be used as a target for a pipe. The State Machine will be invoked with the (enriched/filtered) source payload.

Expand All @@ -85,7 +85,7 @@ const pipe = new pipes.Pipe(this, 'Pipe', {
});
```

Specifying the Invocation Type of the State Machine.
Specifying the Invocation Type when the target State Machine is invoked:

```ts
declare const sourceQueue: sqs.Queue;
Expand All @@ -104,7 +104,7 @@ const pipe = new pipes.Pipe(this, 'Pipe', {
});
```

The target input can be transformed:
The input to the target State Machine can be transformed:

```ts
declare const sourceQueue: sqs.Queue;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import * as sfn from 'aws-cdk-lib/aws-stepfunctions';
import { StateMachine, StateMachineType } from 'aws-cdk-lib/aws-stepfunctions';

/**
* StateMachine StepFunction target properties.
* Parameters for the SfnStateMachine target
*/
export interface StateMachineTargetParameters {
/**
Expand All @@ -16,7 +16,7 @@ export interface StateMachineTargetParameters {
readonly inputTransformation?: IInputTransformation;

/**
* Specify whether to invoke the Step Functions state machine synchronously (`REQUEST_RESPONSE`) or asynchronously (`FIRE_AND_FORGET`).
* Specify whether to invoke the State Machine synchronously (`REQUEST_RESPONSE`) or asynchronously (`FIRE_AND_FORGET`).
*
* @see http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-pipes-pipe-pipetargetsqsqueueparameters.html#cfn-pipes-pipe-pipetargetsqsqueueparameters-messagededuplicationid
* @default StateMachineInvocationType.FIRE_AND_FORGET
Expand All @@ -25,7 +25,7 @@ export interface StateMachineTargetParameters {
}

/**
* InvocationType for invoking StepFunction.
* InvocationType for invoking the State Machine.
* @see https://docs.aws.amazon.com/eventbridge/latest/pipes-reference/API_PipeTargetStateMachineParameters.html
*/
export enum StateMachineInvocationType {
Expand All @@ -41,7 +41,7 @@ export enum StateMachineInvocationType {
}

/**
* An EventBridge Pipes target that sends messages to a StepFunction.
* An EventBridge Pipes target that sends messages to an AWS Step Functions State Machine.
*/
export class StateMachineTarget implements ITarget {
public readonly targetArn: string;
Expand Down

0 comments on commit fc63265

Please sign in to comment.