Skip to content
v2.278.0

Experimental

@aws-cdk/aws-pipes-targets-alpha is an experimental (alpha) package: its API may change in any release, without a major version bump.

SageMakerTargetParameters Struct ​

SageMaker target properties.

Example ​

ts
declare const sourceQueue: sqs.Queue;
declare const targetPipeline: sagemaker.IPipeline;

const pipelineTarget = new targets.SageMakerTarget(targetPipeline, {
  inputTransformation: pipes.InputTransformation.fromObject({ body: "👀" }),
});

const pipe = new pipes.Pipe(this, 'Pipe', {
    source: new SqsSource(sourceQueue),
    target: pipelineTarget,
});
python
# source_queue: sqs.Queue
# target_pipeline: sagemaker.IPipeline


pipeline_target = targets.SageMakerTarget(target_pipeline,
    input_transformation=pipes.InputTransformation.from_object({"body": "👀"})
)

pipe = pipes.Pipe(self, "Pipe",
    source=SqsSource(source_queue),
    target=pipeline_target
)
java
Queue sourceQueue;
IPipeline targetPipeline;


SageMakerTarget pipelineTarget = SageMakerTarget.Builder.create(targetPipeline)
        .inputTransformation(InputTransformation.fromObject(Map.of("body", "👀")))
        .build();

Pipe pipe = Pipe.Builder.create(this, "Pipe")
        .source(new SqsSource(sourceQueue))
        .target(pipelineTarget)
        .build();
csharp
// Install: dotnet add package Amazon.CDK.AWS.Pipes.Targets.Alpha
Queue sourceQueue;
IPipeline targetPipeline;


var pipelineTarget = new SageMakerTarget(targetPipeline, new SageMakerTargetParameters {
    InputTransformation = InputTransformation.FromObject(new Dictionary<string, object> { { "body", "👀" } })
});

var pipe = new Pipe(this, "Pipe", new PipeProps {
    Source = new SqsSource(sourceQueue),
    Target = pipelineTarget
});
go
// Install: go get github.com/aws/aws-cdk-go/awscdkpipestargetsalpha/v2
var sourceQueue Queue
var targetPipeline IPipeline


pipelineTarget := targets.NewSageMakerTarget(targetPipeline, &SageMakerTargetParameters{
	InputTransformation: pipes.InputTransformation_FromObject(map[string]interface{}{
		"body": jsii.String("👀"),
	}),
})

pipe := pipes.NewPipe(this, jsii.String("Pipe"), &PipeProps{
	Source: awscdkpipessourcesalpha.NewSqsSource(sourceQueue),
	Target: pipelineTarget,
})

Properties ​

inputTransformationoptionalIInputTransformationinput_transformationoptionalIInputTransformationinputTransformationoptionalIInputTransformationInputTransformationoptionalIInputTransformationInputTransformationoptionalIInputTransformation = none #
The input transformation to apply to the message before sending it to the target.
pipelineParametersoptional{ [key: string]: string }pipeline_parametersoptionaltyping.Mapping[str, str]pipelineParametersoptionalMap<String, String>PipelineParametersoptionalIDictionary<string, string>PipelineParametersoptional*map[string]*string = none #
List of parameter names and values for SageMaker Model Building Pipeline execution.

The Name/Value pairs are passed to start execution of the pipeline.