class FlowSource (construct)
| Language | Type name |
|---|---|
.NET | Amazon.CDK.AWS.MediaConnect.Alpha.FlowSource |
Go | github.com/aws/aws-cdk-go/awsmediaconnectalpha/v2#FlowSource |
Java | software.amazon.awscdk.services.mediaconnect.alpha.FlowSource |
Python | aws_cdk.aws_mediaconnect_alpha.FlowSource |
TypeScript (source) | @aws-cdk/aws-mediaconnect-alpha ยป FlowSource |
Implements
IConstruct, IDependable, IResource, IEnvironment, IFlow, IFlow
Adds source to an existing flow.
Adding an additional source requires Failover to be enabled. When you enable Failover, the additional source must use the same protocol as the existing source. A source is the external video content that includes configuration information (encryption and source type) and a network address. Each flow has at least one source. A standard source comes from a source other than another AWS Elemental MediaConnect flow, such as an on-premises encoder.
Example
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import * as mediaconnect_alpha from '@aws-cdk/aws-mediaconnect-alpha';
declare const flow: mediaconnect_alpha.Flow;
declare const sourceConfiguration: mediaconnect_alpha.SourceConfiguration;
const flowSource = new mediaconnect_alpha.FlowSource(this, 'MyFlowSource', {
flow: flow,
source: sourceConfiguration,
});
Initializer
new FlowSource(scope: Construct, id: string, props: FlowSourceProps)
Parameters
- scope
Construct - id
string - props
FlowSource Props
Construct Props
| Name | Type | Description |
|---|---|---|
| flow | IFlow | The flow this source is connected to. |
| source | Source | Additional Source Configuration. |
flow
Type:
IFlow
The flow this source is connected to.
The flow must have Failover enabled to add an additional source.
source
Type:
Source
Additional Source Configuration.
Set the source's name via name on the configuration (e.g. SourceConfiguration.rtp({ name })).
When no name is set there, one is generated from construct naming.
Properties
| Name | Type | Description |
|---|---|---|
| env | Resource | The environment this resource belongs to. |
| flow | string | The Amazon Resource Name (ARN) of the flow source. |
| flow | string | The name of the flow source. |
| flow | Flow | A reference to a FlowSource resource. |
| ingest | string | The IP address that the flow will be listening on for incoming content. |
| node | Node | The tree node. |
| source | string | The port that the flow will be listening on for incoming content. |
| stack | Stack | The stack in which this resource is defined. |
| static PROPERTY_INJECTION_ID | string | Uniquely identifies this class. |
env
Type:
Resource
The environment this resource belongs to.
For resources that are created and managed in a Stack (those created by
creating new class instances like new Role(), new Bucket(), etc.), this
is always the same as the environment of the stack they belong to.
For referenced resources (those obtained from referencing methods like
Role.fromRoleArn(), Bucket.fromBucketName(), etc.), they might be
different than the stack they were imported into.
flowSourceArn
Type:
string
The Amazon Resource Name (ARN) of the flow source.
flowSourceName
Type:
string
The name of the flow source.
flowSourceRef
Type:
Flow
A reference to a FlowSource resource.
ingestIp
Type:
string
The IP address that the flow will be listening on for incoming content.
node
Type:
Node
The tree node.
sourceIngestPort
Type:
string
The port that the flow will be listening on for incoming content.
stack
Type:
Stack
The stack in which this resource is defined.
static PROPERTY_INJECTION_ID
Type:
string
Uniquely identifies this class.
Methods
| Name | Description |
|---|---|
| apply | Override the cross-stack reference strength for this resource. |
| apply | Apply the given removal policy to this resource. |
| to | Returns a string representation of this construct. |
| with(...mixins) | Applies one or more mixins to this construct. |
| static from | Import an existing Flow Source from its ARN. |
| static from | Import an existing Flow Source from its attributes. |
applyCrossStackReferenceStrength(strength)
public applyCrossStackReferenceStrength(strength: ReferenceStrength): void
Parameters
- strength
Referenceโ - The reference strength to use for this resource.Strength
Override the cross-stack reference strength for this resource.
When set, any cross-stack reference to this resource will use the specified
mechanism instead of the global default determined by the
@aws-cdk/core:defaultCrossStackReferences context key. This is useful for
selectively weakening specific references to avoid the "deadly embrace" problem
without changing the app-wide default.
applyRemovalPolicy(policy)
public applyRemovalPolicy(policy: RemovalPolicy): void
Parameters
- policy
RemovalPolicy
Apply the given removal policy to this resource.
The Removal Policy controls what happens to this resource when it stops being managed by CloudFormation, either because you've removed it from the CDK application or because you've made a change that requires the resource to be replaced.
The resource can be deleted (RemovalPolicy.DESTROY), or left in your AWS
account for data recovery and cleanup later (RemovalPolicy.RETAIN).
toString()
public toString(): string
Returns
string
Returns a string representation of this construct.
with(...mixins)
public with(...mixins: IMixin[]): IConstruct
Parameters
- mixins
IMixin
Returns
Applies one or more mixins to this construct.
Mixins are applied in order. The list of constructs is captured at the
start of the call, so constructs added by a mixin will not be visited.
Use multiple with() calls if subsequent mixins should apply to added
constructs.
static fromFlowSourceArn(scope, id, flowSourceArn)
public static fromFlowSourceArn(scope: Construct, id: string, flowSourceArn: string): IFlowSource
Parameters
- scope
Constructโ The parent construct. - id
stringโ The construct id. - flowSourceArn
stringโ The ARN of the Flow Source.
Returns
Import an existing Flow Source from its ARN.
static fromFlowSourceAttributes(scope, id, attrs)
public static fromFlowSourceAttributes(scope: Construct, id: string, attrs: FlowSourceAttributes): IFlowSource
Parameters
- scope
Constructโ The parent construct. - id
stringโ The construct id. - attrs
Flowโ The Flow Source attributes.Source Attributes
Returns
Import an existing Flow Source from its attributes.
Provide ingestIp and/or sourceIngestPort when importing a source that was deployed
externally โ otherwise accessing those properties on the imported construct will throw.

.NET
Go
Java
Python
TypeScript (