@Generated(value="jsii-pacmak/1.30.0 (build adae23f)", date="2021-06-30T10:00:55.958Z") @Stability(value=Experimental) public interface IProject extends software.amazon.jsii.JsiiSerializable, IResource, IGrantable, IConnectable
| Modifier and Type | Interface and Description |
|---|---|
static interface |
IProject.Jsii$Default
Internal default implementation for
IProject. |
static class |
IProject.Jsii$Proxy
A proxy class which represents a concrete javascript instance of this type.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addToRolePolicy(PolicyStatement policyStatement) |
BatchBuildConfig |
enableBatchBuilds()
(experimental) Enable batch builds.
|
String |
getProjectArn()
(experimental) The ARN of this Project.
|
String |
getProjectName()
(experimental) The human-visible name of this Project.
|
default IRole |
getRole()
(experimental) The IAM service Role of this Project.
|
Metric |
metric(String metricName) |
Metric |
metric(String metricName,
MetricOptions props) |
Metric |
metricBuilds()
(experimental) Measures the number of builds triggered.
|
Metric |
metricBuilds(MetricOptions props)
(experimental) Measures the number of builds triggered.
|
Metric |
metricDuration()
(experimental) Measures the duration of all builds over time.
|
Metric |
metricDuration(MetricOptions props)
(experimental) Measures the duration of all builds over time.
|
Metric |
metricFailedBuilds()
(experimental) Measures the number of builds that failed because of client error or because of a timeout.
|
Metric |
metricFailedBuilds(MetricOptions props)
(experimental) Measures the number of builds that failed because of client error or because of a timeout.
|
Metric |
metricSucceededBuilds()
(experimental) Measures the number of successful builds.
|
Metric |
metricSucceededBuilds(MetricOptions props)
(experimental) Measures the number of successful builds.
|
Rule |
onBuildFailed(String id)
(experimental) Defines an event rule which triggers when a build fails.
|
Rule |
onBuildFailed(String id,
OnEventOptions options)
(experimental) Defines an event rule which triggers when a build fails.
|
Rule |
onBuildStarted(String id)
(experimental) Defines an event rule which triggers when a build starts.
|
Rule |
onBuildStarted(String id,
OnEventOptions options)
(experimental) Defines an event rule which triggers when a build starts.
|
Rule |
onBuildSucceeded(String id)
(experimental) Defines an event rule which triggers when a build completes successfully.
|
Rule |
onBuildSucceeded(String id,
OnEventOptions options)
(experimental) Defines an event rule which triggers when a build completes successfully.
|
Rule |
onEvent(String id)
(experimental) Defines a CloudWatch event rule triggered when something happens with this project.
|
Rule |
onEvent(String id,
OnEventOptions options)
(experimental) Defines a CloudWatch event rule triggered when something happens with this project.
|
Rule |
onPhaseChange(String id)
(experimental) Defines a CloudWatch event rule that triggers upon phase change of this build project.
|
Rule |
onPhaseChange(String id,
OnEventOptions options)
(experimental) Defines a CloudWatch event rule that triggers upon phase change of this build project.
|
Rule |
onStateChange(String id)
(experimental) Defines a CloudWatch event rule triggered when the build project state changes.
|
Rule |
onStateChange(String id,
OnEventOptions options)
(experimental) Defines a CloudWatch event rule triggered when the build project state changes.
|
getGrantPrincipalgetConnections@Stability(value=Experimental) @NotNull String getProjectArn()
@Stability(value=Experimental) @NotNull String getProjectName()
@Stability(value=Experimental) @Nullable default IRole getRole()
Undefined for imported Projects.
@Stability(value=Experimental)
void addToRolePolicy(@NotNull
PolicyStatement policyStatement)
policyStatement - This parameter is required.@Stability(value=Experimental) @Nullable BatchBuildConfig enableBatchBuilds()
Returns an object contining the batch service role if batch builds could be enabled.
@Stability(value=Experimental) @NotNull Metric metric(@NotNull String metricName, @Nullable MetricOptions props)
metricName - The name of the metric. This parameter is required.props - Customization properties.@Stability(value=Experimental) @NotNull Metric metric(@NotNull String metricName)
metricName - The name of the metric. This parameter is required.@Stability(value=Experimental) @NotNull Metric metricBuilds(@Nullable MetricOptions props)
Units: Count
Valid CloudWatch statistics: Sum
Default: sum over 5 minutes
props - @Stability(value=Experimental) @NotNull Metric metricBuilds()
Units: Count
Valid CloudWatch statistics: Sum
Default: sum over 5 minutes
@Stability(value=Experimental) @NotNull Metric metricDuration(@Nullable MetricOptions props)
Units: Seconds
Valid CloudWatch statistics: Average (recommended), Maximum, Minimum
Default: average over 5 minutes
props - @Stability(value=Experimental) @NotNull Metric metricDuration()
Units: Seconds
Valid CloudWatch statistics: Average (recommended), Maximum, Minimum
Default: average over 5 minutes
@Stability(value=Experimental) @NotNull Metric metricFailedBuilds(@Nullable MetricOptions props)
Units: Count
Valid CloudWatch statistics: Sum
Default: sum over 5 minutes
props - @Stability(value=Experimental) @NotNull Metric metricFailedBuilds()
Units: Count
Valid CloudWatch statistics: Sum
Default: sum over 5 minutes
@Stability(value=Experimental) @NotNull Metric metricSucceededBuilds(@Nullable MetricOptions props)
Units: Count
Valid CloudWatch statistics: Sum
Default: sum over 5 minutes
props - @Stability(value=Experimental) @NotNull Metric metricSucceededBuilds()
Units: Count
Valid CloudWatch statistics: Sum
Default: sum over 5 minutes
@Stability(value=Experimental) @NotNull Rule onBuildFailed(@NotNull String id, @Nullable OnEventOptions options)
id - This parameter is required.options - @Stability(value=Experimental) @NotNull Rule onBuildFailed(@NotNull String id)
id - This parameter is required.@Stability(value=Experimental) @NotNull Rule onBuildStarted(@NotNull String id, @Nullable OnEventOptions options)
id - This parameter is required.options - @Stability(value=Experimental) @NotNull Rule onBuildStarted(@NotNull String id)
id - This parameter is required.@Stability(value=Experimental) @NotNull Rule onBuildSucceeded(@NotNull String id, @Nullable OnEventOptions options)
id - This parameter is required.options - @Stability(value=Experimental) @NotNull Rule onBuildSucceeded(@NotNull String id)
id - This parameter is required.@Stability(value=Experimental) @NotNull Rule onEvent(@NotNull String id, @Nullable OnEventOptions options)
id - This parameter is required.options - https://docs.aws.amazon.com/codebuild/latest/userguide/sample-build-notifications.html@Stability(value=Experimental) @NotNull Rule onEvent(@NotNull String id)
id - This parameter is required.https://docs.aws.amazon.com/codebuild/latest/userguide/sample-build-notifications.html@Stability(value=Experimental) @NotNull Rule onPhaseChange(@NotNull String id, @Nullable OnEventOptions options)
id - This parameter is required.options - https://docs.aws.amazon.com/codebuild/latest/userguide/sample-build-notifications.html@Stability(value=Experimental) @NotNull Rule onPhaseChange(@NotNull String id)
id - This parameter is required.https://docs.aws.amazon.com/codebuild/latest/userguide/sample-build-notifications.html@Stability(value=Experimental) @NotNull Rule onStateChange(@NotNull String id, @Nullable OnEventOptions options)
You can filter specific build status events using an event
pattern filter on the build-status detail field:
const rule = project.onStateChange('OnBuildStarted', { target });
rule.addEventPattern({
detail: {
'build-status': [
"IN_PROGRESS",
"SUCCEEDED",
"FAILED",
"STOPPED"
]
}
});
You can also use the methods onBuildFailed and onBuildSucceeded to define rules for
these specific state changes.
To access fields from the event in the event target input,
use the static fields on the StateChangeEvent class.
id - This parameter is required.options - https://docs.aws.amazon.com/codebuild/latest/userguide/sample-build-notifications.html@Stability(value=Experimental) @NotNull Rule onStateChange(@NotNull String id)
You can filter specific build status events using an event
pattern filter on the build-status detail field:
const rule = project.onStateChange('OnBuildStarted', { target });
rule.addEventPattern({
detail: {
'build-status': [
"IN_PROGRESS",
"SUCCEEDED",
"FAILED",
"STOPPED"
]
}
});
You can also use the methods onBuildFailed and onBuildSucceeded to define rules for
these specific state changes.
To access fields from the event in the event target input,
use the static fields on the StateChangeEvent class.
id - This parameter is required.https://docs.aws.amazon.com/codebuild/latest/userguide/sample-build-notifications.htmlCopyright © 2021. All rights reserved.