Class CfnExperiment
java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
software.amazon.awscdk.CfnElement
software.amazon.awscdk.CfnRefElement
software.amazon.awscdk.CfnResource
software.amazon.awscdk.services.evidently.CfnExperiment
- All Implemented Interfaces:
IInspectable
,ITaggable
,software.amazon.jsii.JsiiSerializable
,software.constructs.IConstruct
,software.constructs.IDependable
@Generated(value="jsii-pacmak/1.103.1 (build bef2dea)",
date="2024-10-11T15:55:59.293Z")
@Stability(Stable)
public class CfnExperiment
extends CfnResource
implements IInspectable, ITaggable
Creates or updates an Evidently experiment .
Before you create an experiment, you must create the feature to use for the experiment.
An experiment helps you make feature design decisions based on evidence and data. An experiment can test as many as five variations at once. Evidently collects experiment data and analyzes it by statistical methods, and provides clear recommendations about which variations perform better.
Example:
// The code below shows an example of how to instantiate this type. // The values are placeholders you should change. import software.amazon.awscdk.services.evidently.*; CfnExperiment cfnExperiment = CfnExperiment.Builder.create(this, "MyCfnExperiment") .metricGoals(List.of(MetricGoalObjectProperty.builder() .desiredChange("desiredChange") .entityIdKey("entityIdKey") .metricName("metricName") .valueKey("valueKey") // the properties below are optional .eventPattern("eventPattern") .unitLabel("unitLabel") .build())) .name("name") .onlineAbConfig(OnlineAbConfigObjectProperty.builder() .controlTreatmentName("controlTreatmentName") .treatmentWeights(List.of(TreatmentToWeightProperty.builder() .splitWeight(123) .treatment("treatment") .build())) .build()) .project("project") .treatments(List.of(TreatmentObjectProperty.builder() .feature("feature") .treatmentName("treatmentName") .variation("variation") // the properties below are optional .description("description") .build())) // the properties below are optional .description("description") .randomizationSalt("randomizationSalt") .removeSegment(false) .runningStatus(RunningStatusObjectProperty.builder() .status("status") // the properties below are optional .analysisCompleteTime("analysisCompleteTime") .desiredState("desiredState") .reason("reason") .build()) .samplingRate(123) .segment("segment") .tags(List.of(CfnTag.builder() .key("key") .value("value") .build())) .build();
- See Also:
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic final class
A fluent builder forCfnExperiment
.static interface
Use this structure to tell Evidently whether higher or lower values are desired for a metric that is used in an experiment.static interface
A structure that contains the configuration of which variation to use as the "control" version.static interface
Use this structure to start and stop the experiment.static interface
A structure that defines one treatment in an experiment.static interface
This structure defines how much experiment traffic to allocate to one treatment used in the experiment.Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationMode
Nested classes/interfaces inherited from interface software.constructs.IConstruct
software.constructs.IConstruct.Jsii$Default
Nested classes/interfaces inherited from interface software.amazon.awscdk.IInspectable
IInspectable.Jsii$Default, IInspectable.Jsii$Proxy
Nested classes/interfaces inherited from interface software.amazon.awscdk.ITaggable
ITaggable.Jsii$Default, ITaggable.Jsii$Proxy
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
The CloudFormation resource type name for this resource class. -
Constructor Summary
ModifierConstructorDescriptionprotected
CfnExperiment
(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protected
CfnExperiment
(software.amazon.jsii.JsiiObjectRef objRef) CfnExperiment
(software.constructs.Construct scope, String id, CfnExperimentProps props) -
Method Summary
Modifier and TypeMethodDescriptionThe ARN of the experiment.An optional description of the experiment.An array of structures that defines the metrics used for the experiment, and whether a higher or lower value for each metric is the goal.getName()
A name for the new experiment.A structure that contains the configuration of which variation to use as the "control" version.The name or the ARN of the project where this experiment is to be created.When Evidently assigns a particular user session to an experiment, it must use a randomization ID to determine which variation the user session is served.Set this totrue
to remove the segment that is associated with this experiment.A structure that you can use to start and stop the experiment.The portion of the available audience that you want to allocate to this experiment, in thousandths of a percent.Specifies an audience segment to use in the experiment.getTags()
Tag Manager which manages the tags for this resource.Assigns one or more tags (key-value pairs) to the experiment.An array of structures that describe the configuration of each feature variation used in the experiment.void
inspect
(TreeInspector inspector) Examines the CloudFormation resource and discloses attributes.renderProperties
(Map<String, Object> props) void
setDescription
(String value) An optional description of the experiment.void
setMetricGoals
(List<Object> value) An array of structures that defines the metrics used for the experiment, and whether a higher or lower value for each metric is the goal.void
setMetricGoals
(IResolvable value) An array of structures that defines the metrics used for the experiment, and whether a higher or lower value for each metric is the goal.void
A name for the new experiment.void
setOnlineAbConfig
(IResolvable value) A structure that contains the configuration of which variation to use as the "control" version.void
A structure that contains the configuration of which variation to use as the "control" version.void
setProject
(String value) The name or the ARN of the project where this experiment is to be created.void
setRandomizationSalt
(String value) When Evidently assigns a particular user session to an experiment, it must use a randomization ID to determine which variation the user session is served.void
setRemoveSegment
(Boolean value) Set this totrue
to remove the segment that is associated with this experiment.void
setRemoveSegment
(IResolvable value) Set this totrue
to remove the segment that is associated with this experiment.void
setRunningStatus
(IResolvable value) A structure that you can use to start and stop the experiment.void
A structure that you can use to start and stop the experiment.void
setSamplingRate
(Number value) The portion of the available audience that you want to allocate to this experiment, in thousandths of a percent.void
setSegment
(String value) Specifies an audience segment to use in the experiment.void
setTagsRaw
(List<CfnTag> value) Assigns one or more tags (key-value pairs) to the experiment.void
setTreatments
(List<Object> value) An array of structures that describe the configuration of each feature variation used in the experiment.void
setTreatments
(IResolvable value) An array of structures that describe the configuration of each feature variation used in the experiment.Methods inherited from class software.amazon.awscdk.CfnResource
addDeletionOverride, addDependency, addDependsOn, addMetadata, addOverride, addPropertyDeletionOverride, addPropertyOverride, applyRemovalPolicy, applyRemovalPolicy, applyRemovalPolicy, getAtt, getAtt, getCfnOptions, getCfnResourceType, getMetadata, getUpdatedProperites, getUpdatedProperties, isCfnResource, obtainDependencies, obtainResourceDependencies, removeDependency, replaceDependency, shouldSynthesize, toString, validateProperties
Methods inherited from class software.amazon.awscdk.CfnRefElement
getRef
Methods inherited from class software.amazon.awscdk.CfnElement
getCreationStack, getLogicalId, getStack, isCfnElement, overrideLogicalId
Methods inherited from class software.constructs.Construct
getNode, isConstruct
Methods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSet
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Field Details
-
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
-
-
Constructor Details
-
CfnExperiment
protected CfnExperiment(software.amazon.jsii.JsiiObjectRef objRef) -
CfnExperiment
protected CfnExperiment(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
CfnExperiment
@Stability(Stable) public CfnExperiment(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull CfnExperimentProps props) - Parameters:
scope
- Scope in which this resource is defined. This parameter is required.id
- Construct identifier for this resource (unique in its scope). This parameter is required.props
- Resource properties. This parameter is required.
-
-
Method Details
-
inspect
Examines the CloudFormation resource and discloses attributes.- Specified by:
inspect
in interfaceIInspectable
- Parameters:
inspector
- tree inspector to collect and process attributes. This parameter is required.
-
renderProperties
@Stability(Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String, Object> props) - Overrides:
renderProperties
in classCfnResource
- Parameters:
props
- This parameter is required.
-
getAttrArn
The ARN of the experiment.For example,
arn:aws:evidently:us-west-2:0123455678912:project/myProject/experiment/myExperiment
-
getCfnProperties
- Overrides:
getCfnProperties
in classCfnResource
-
getTags
Tag Manager which manages the tags for this resource. -
getMetricGoals
An array of structures that defines the metrics used for the experiment, and whether a higher or lower value for each metric is the goal. -
setMetricGoals
An array of structures that defines the metrics used for the experiment, and whether a higher or lower value for each metric is the goal. -
setMetricGoals
An array of structures that defines the metrics used for the experiment, and whether a higher or lower value for each metric is the goal. -
getName
A name for the new experiment. -
setName
A name for the new experiment. -
getOnlineAbConfig
A structure that contains the configuration of which variation to use as the "control" version. -
setOnlineAbConfig
A structure that contains the configuration of which variation to use as the "control" version. -
setOnlineAbConfig
@Stability(Stable) public void setOnlineAbConfig(@NotNull CfnExperiment.OnlineAbConfigObjectProperty value) A structure that contains the configuration of which variation to use as the "control" version. -
getProject
The name or the ARN of the project where this experiment is to be created. -
setProject
The name or the ARN of the project where this experiment is to be created. -
getTreatments
An array of structures that describe the configuration of each feature variation used in the experiment. -
setTreatments
An array of structures that describe the configuration of each feature variation used in the experiment. -
setTreatments
An array of structures that describe the configuration of each feature variation used in the experiment. -
getDescription
An optional description of the experiment. -
setDescription
An optional description of the experiment. -
getRandomizationSalt
When Evidently assigns a particular user session to an experiment, it must use a randomization ID to determine which variation the user session is served. -
setRandomizationSalt
When Evidently assigns a particular user session to an experiment, it must use a randomization ID to determine which variation the user session is served. -
getRemoveSegment
Set this totrue
to remove the segment that is associated with this experiment. -
setRemoveSegment
Set this totrue
to remove the segment that is associated with this experiment. -
setRemoveSegment
Set this totrue
to remove the segment that is associated with this experiment. -
getRunningStatus
A structure that you can use to start and stop the experiment. -
setRunningStatus
A structure that you can use to start and stop the experiment. -
setRunningStatus
@Stability(Stable) public void setRunningStatus(@Nullable CfnExperiment.RunningStatusObjectProperty value) A structure that you can use to start and stop the experiment. -
getSamplingRate
The portion of the available audience that you want to allocate to this experiment, in thousandths of a percent. -
setSamplingRate
The portion of the available audience that you want to allocate to this experiment, in thousandths of a percent. -
getSegment
Specifies an audience segment to use in the experiment. -
setSegment
Specifies an audience segment to use in the experiment. -
getTagsRaw
Assigns one or more tags (key-value pairs) to the experiment. -
setTagsRaw
Assigns one or more tags (key-value pairs) to the experiment.
-