Feature

class Feature : KotlinCustomResource

Provides a CloudWatch Evidently Feature resource.

Example Usage

Basic

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.evidently.Feature;
import com.pulumi.aws.evidently.FeatureArgs;
import com.pulumi.aws.evidently.inputs.FeatureVariationArgs;
import com.pulumi.aws.evidently.inputs.FeatureVariationValueArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var example = new Feature("example", FeatureArgs.builder()
.project(aws_evidently_project.example().name())
.description("example description")
.variations(FeatureVariationArgs.builder()
.name("Variation1")
.value(FeatureVariationValueArgs.builder()
.stringValue("example")
.build())
.build())
.tags(Map.of("Key1", "example Feature"))
.build());
}
}

With default variation

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.evidently.Feature;
import com.pulumi.aws.evidently.FeatureArgs;
import com.pulumi.aws.evidently.inputs.FeatureVariationArgs;
import com.pulumi.aws.evidently.inputs.FeatureVariationValueArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var example = new Feature("example", FeatureArgs.builder()
.project(aws_evidently_project.example().name())
.defaultVariation("Variation2")
.variations(
FeatureVariationArgs.builder()
.name("Variation1")
.value(FeatureVariationValueArgs.builder()
.stringValue("exampleval1")
.build())
.build(),
FeatureVariationArgs.builder()
.name("Variation2")
.value(FeatureVariationValueArgs.builder()
.stringValue("exampleval2")
.build())
.build())
.build());
}
}

With entity overrides

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.evidently.Feature;
import com.pulumi.aws.evidently.FeatureArgs;
import com.pulumi.aws.evidently.inputs.FeatureVariationArgs;
import com.pulumi.aws.evidently.inputs.FeatureVariationValueArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var example = new Feature("example", FeatureArgs.builder()
.project(aws_evidently_project.example().name())
.entityOverrides(Map.of("test1", "Variation1"))
.variations(
FeatureVariationArgs.builder()
.name("Variation1")
.value(FeatureVariationValueArgs.builder()
.stringValue("exampleval1")
.build())
.build(),
FeatureVariationArgs.builder()
.name("Variation2")
.value(FeatureVariationValueArgs.builder()
.stringValue("exampleval2")
.build())
.build())
.build());
}
}

With evaluation strategy

package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.evidently.Feature;
import com.pulumi.aws.evidently.FeatureArgs;
import com.pulumi.aws.evidently.inputs.FeatureVariationArgs;
import com.pulumi.aws.evidently.inputs.FeatureVariationValueArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var example = new Feature("example", FeatureArgs.builder()
.project(aws_evidently_project.example().name())
.evaluationStrategy("ALL_RULES")
.entityOverrides(Map.of("test1", "Variation1"))
.variations(FeatureVariationArgs.builder()
.name("Variation1")
.value(FeatureVariationValueArgs.builder()
.stringValue("exampleval1")
.build())
.build())
.build());
}
}

Import

CloudWatch Evidently Feature can be imported using the feature name and name or arn of the hosting CloudWatch Evidently Project separated by a :, e.g.,

$ pulumi import aws:evidently/feature:Feature example exampleFeatureName:arn:aws:evidently:us-east-1:123456789012:project/example

Properties

Link copied to clipboard
val arn: Output<String>

The ARN of the feature.

Link copied to clipboard
val createdTime: Output<String>

The date and time that the feature is created.

Link copied to clipboard

The name of the variation to use as the default variation. The default variation is served to users who are not allocated to any ongoing launches or experiments of this feature. This variation must also be listed in the variations structure. If you omit default_variation, the first variation listed in the variations structure is used as the default variation.

Link copied to clipboard
val description: Output<String>?

Specifies the description of the feature.

Link copied to clipboard

Specify users that should always be served a specific variation of a feature. Each user is specified by a key-value pair . For each key, specify a user by entering their user ID, account ID, or some other identifier. For the value, specify the name of the variation that they are to be served.

Link copied to clipboard

One or more blocks that define the evaluation rules for the feature. Detailed below

Link copied to clipboard

Specify ALL_RULES to activate the traffic allocation specified by any ongoing launches or experiments. Specify DEFAULT_VARIATION to serve the default variation to all users instead.

Link copied to clipboard
val id: Output<String>
Link copied to clipboard
val lastUpdatedTime: Output<String>

The date and time that the feature was most recently updated.

Link copied to clipboard
val name: Output<String>

The name for the new feature. Minimum length of 1. Maximum length of 127.

Link copied to clipboard
val project: Output<String>

The name or ARN of the project that is to contain the new feature.

Link copied to clipboard
val pulumiChildResources: Set<KotlinResource>
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
val status: Output<String>

The current state of the feature. Valid values are AVAILABLE and UPDATING.

Link copied to clipboard
val tags: Output<Map<String, String>>?

Tags to apply to the feature. If configured with a provider default_tags configuration block present, tags with matching keys will overwrite those defined at the provider-level.

Link copied to clipboard
val tagsAll: Output<Map<String, String>>

A map of tags assigned to the resource, including those inherited from the provider default_tags configuration block.

Link copied to clipboard
val urn: Output<String>
Link copied to clipboard
val valueType: Output<String>

Defines the type of value used to define the different feature variations. Valid Values: STRING, LONG, DOUBLE, BOOLEAN.

Link copied to clipboard

One or more blocks that contain the configuration of the feature's different variations. Detailed below