PolicyValidationPluginReportBeta1 Struct
The report emitted by the plugin after evaluation.
Example
ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import * as cdk from 'aws-cdk-lib';
const policyValidationPluginReportBeta1: cdk.PolicyValidationPluginReportBeta1 = {
success: false,
violations: [{
description: 'description',
ruleName: 'ruleName',
violatingResources: [{
locations: ['locations'],
resourceLogicalId: 'resourceLogicalId',
templatePath: 'templatePath',
}],
// the properties below are optional
fix: 'fix',
ruleMetadata: {
ruleMetadataKey: 'ruleMetadata',
},
severity: 'severity',
}],
// the properties below are optional
metadata: {
metadataKey: 'metadata',
},
pluginVersion: 'pluginVersion',
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
import aws_cdk as cdk
policy_validation_plugin_report_beta1 = cdk.PolicyValidationPluginReportBeta1(
success=False,
violations=[cdk.PolicyViolationBeta1(
description="description",
rule_name="ruleName",
violating_resources=[cdk.PolicyViolatingResourceBeta1(
locations=["locations"],
resource_logical_id="resourceLogicalId",
template_path="templatePath"
)],
# the properties below are optional
fix="fix",
rule_metadata={
"rule_metadata_key": "ruleMetadata"
},
severity="severity"
)],
# the properties below are optional
metadata={
"metadata_key": "metadata"
},
plugin_version="pluginVersion"
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.*;
PolicyValidationPluginReportBeta1 policyValidationPluginReportBeta1 = PolicyValidationPluginReportBeta1.builder()
.success(false)
.violations(List.of(PolicyViolationBeta1.builder()
.description("description")
.ruleName("ruleName")
.violatingResources(List.of(PolicyViolatingResourceBeta1.builder()
.locations(List.of("locations"))
.resourceLogicalId("resourceLogicalId")
.templatePath("templatePath")
.build()))
// the properties below are optional
.fix("fix")
.ruleMetadata(Map.of(
"ruleMetadataKey", "ruleMetadata"))
.severity("severity")
.build()))
// the properties below are optional
.metadata(Map.of(
"metadataKey", "metadata"))
.pluginVersion("pluginVersion")
.build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK;
var policyValidationPluginReportBeta1 = new PolicyValidationPluginReportBeta1 {
Success = false,
Violations = new [] { new PolicyViolationBeta1 {
Description = "description",
RuleName = "ruleName",
ViolatingResources = new [] { new PolicyViolatingResourceBeta1 {
Locations = new [] { "locations" },
ResourceLogicalId = "resourceLogicalId",
TemplatePath = "templatePath"
} },
// the properties below are optional
Fix = "fix",
RuleMetadata = new Dictionary<string, string> {
{ "ruleMetadataKey", "ruleMetadata" }
},
Severity = "severity"
} },
// the properties below are optional
Metadata = new Dictionary<string, string> {
{ "metadataKey", "metadata" }
},
PluginVersion = "pluginVersion"
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import cdk "github.com/aws/aws-cdk-go/awscdk"
policyValidationPluginReportBeta1 := &PolicyValidationPluginReportBeta1{
Success: jsii.Boolean(false),
Violations: []PolicyViolationBeta1{
&PolicyViolationBeta1{
Description: jsii.String("description"),
RuleName: jsii.String("ruleName"),
ViolatingResources: []PolicyViolatingResourceBeta1{
&PolicyViolatingResourceBeta1{
Locations: []*string{
jsii.String("locations"),
},
ResourceLogicalId: jsii.String("resourceLogicalId"),
TemplatePath: jsii.String("templatePath"),
},
},
// the properties below are optional
Fix: jsii.String("fix"),
RuleMetadata: map[string]*string{
"ruleMetadataKey": jsii.String("ruleMetadata"),
},
Severity: jsii.String("severity"),
},
},
// the properties below are optional
Metadata: map[string]*string{
"metadataKey": jsii.String("metadata"),
},
PluginVersion: jsii.String("pluginVersion"),
}
Properties
metadataoptional{ [key: string]: string }metadataoptionaltyping.Mapping[str, str]metadataoptionalMap<String, String>MetadataoptionalIDictionary<string, string>Metadataoptional*map[string]*string#Arbitrary information about the report.
Default: no metadata
pluginVersionoptionalstringplugin_versionoptionalstrpluginVersionoptionalStringPluginVersionoptionalstringPluginVersionoptional*string#The version of the plugin that created the report.
Default: no version
Whether or not the report was successful.
violationsPolicyViolationBeta1[]violationstyping.List[PolicyViolationBeta1]violationsList<PolicyViolationBeta1>ViolationsPolicyViolationBeta1[]Violations*[]PolicyViolationBeta1required#List of violations in the report.