@Generated(value="jsii-pacmak/1.58.0 (build f8ba112)", date="2022-05-13T01:13:36.702Z") public class Domain extends Resource implements IDomain, IConnectable
Example:
Domain domain = Domain.Builder.create(this, "Domain") .version(EngineVersion.OPENSEARCH_1_0) .ebs(EbsOptions.builder() .volumeSize(100) .volumeType(EbsDeviceVolumeType.GENERAL_PURPOSE_SSD) .build()) .nodeToNodeEncryption(true) .encryptionAtRest(EncryptionAtRestOptions.builder() .enabled(true) .build()) .build();
Modifier and Type | Class and Description |
---|---|
static class |
Domain.Builder
A fluent builder for
Domain . |
IDomain.Jsii$Default, IDomain.Jsii$Proxy
IConnectable.Jsii$Default, IConnectable.Jsii$Proxy
Modifier | Constructor and Description |
---|---|
protected |
Domain(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) |
protected |
Domain(software.amazon.jsii.JsiiObjectRef objRef) |
|
Domain(software.constructs.Construct scope,
java.lang.String id,
DomainProps props) |
Modifier and Type | Method and Description |
---|---|
void |
addAccessPolicies(PolicyStatement... accessPolicyStatements)
Add policy statements to the domain access policy.
|
static IDomain |
fromDomainAttributes(software.constructs.Construct scope,
java.lang.String id,
DomainAttributes attrs)
Creates a domain construct that represents an external domain.
|
static IDomain |
fromDomainEndpoint(software.constructs.Construct scope,
java.lang.String id,
java.lang.String domainEndpoint)
Creates a domain construct that represents an external domain via domain endpoint.
|
ILogGroup |
getAppLogGroup()
Log group that application logs are logged to.
|
ILogGroup |
getAuditLogGroup()
Log group that audit logs are logged to.
|
Connections |
getConnections()
Manages network connections to the domain.
|
java.lang.String |
getDomainArn()
Arn of the Amazon OpenSearch Service domain.
|
java.lang.String |
getDomainEndpoint()
Endpoint of the Amazon OpenSearch Service domain.
|
java.lang.String |
getDomainId()
Identifier of the Amazon OpenSearch Service domain.
|
java.lang.String |
getDomainName()
Domain name of the Amazon OpenSearch Service domain.
|
SecretValue |
getMasterUserPassword()
Master user password if fine grained access control is configured.
|
ILogGroup |
getSlowIndexLogGroup()
Log group that slow indices are logged to.
|
ILogGroup |
getSlowSearchLogGroup()
Log group that slow searches are logged to.
|
Grant |
grantIndexRead(java.lang.String index,
IGrantable identity)
Grant read permissions for an index in this domain to an IAM principal (Role/Group/User).
|
Grant |
grantIndexReadWrite(java.lang.String index,
IGrantable identity)
Grant read/write permissions for an index in this domain to an IAM principal (Role/Group/User).
|
Grant |
grantIndexWrite(java.lang.String index,
IGrantable identity)
Grant write permissions for an index in this domain to an IAM principal (Role/Group/User).
|
Grant |
grantPathRead(java.lang.String path,
IGrantable identity)
Grant read permissions for a specific path in this domain to an IAM principal (Role/Group/User).
|
Grant |
grantPathReadWrite(java.lang.String path,
IGrantable identity)
Grant read/write permissions for a specific path in this domain to an IAM principal (Role/Group/User).
|
Grant |
grantPathWrite(java.lang.String path,
IGrantable identity)
Grant write permissions for a specific path in this domain to an IAM principal (Role/Group/User).
|
Grant |
grantRead(IGrantable identity)
Grant read permissions for this domain and its contents to an IAM principal (Role/Group/User).
|
Grant |
grantReadWrite(IGrantable identity)
Grant read/write permissions for this domain and its contents to an IAM principal (Role/Group/User).
|
Grant |
grantWrite(IGrantable identity)
Grant write permissions for this domain and its contents to an IAM principal (Role/Group/User).
|
Metric |
metric(java.lang.String metricName)
Return the given named metric for this domain.
|
Metric |
metric(java.lang.String metricName,
MetricOptions props)
Return the given named metric for this domain.
|
Metric |
metricAutomatedSnapshotFailure()
Metric for automated snapshot failures.
|
Metric |
metricAutomatedSnapshotFailure(MetricOptions props)
Metric for automated snapshot failures.
|
Metric |
metricClusterIndexWritesBlocked()
Metric for the cluster blocking index writes.
|
Metric |
metricClusterIndexWritesBlocked(MetricOptions props)
Metric for the cluster blocking index writes.
|
Metric |
metricClusterStatusRed()
Metric for the time the cluster status is red.
|
Metric |
metricClusterStatusRed(MetricOptions props)
Metric for the time the cluster status is red.
|
Metric |
metricClusterStatusYellow()
Metric for the time the cluster status is yellow.
|
Metric |
metricClusterStatusYellow(MetricOptions props)
Metric for the time the cluster status is yellow.
|
Metric |
metricCPUUtilization()
Metric for CPU utilization.
|
Metric |
metricCPUUtilization(MetricOptions props)
Metric for CPU utilization.
|
Metric |
metricFreeStorageSpace()
Metric for the storage space of nodes in the cluster.
|
Metric |
metricFreeStorageSpace(MetricOptions props)
Metric for the storage space of nodes in the cluster.
|
Metric |
metricIndexingLatency()
Metric for indexing latency.
|
Metric |
metricIndexingLatency(MetricOptions props)
Metric for indexing latency.
|
Metric |
metricJVMMemoryPressure()
Metric for JVM memory pressure.
|
Metric |
metricJVMMemoryPressure(MetricOptions props)
Metric for JVM memory pressure.
|
Metric |
metricKMSKeyError()
Metric for KMS key errors.
|
Metric |
metricKMSKeyError(MetricOptions props)
Metric for KMS key errors.
|
Metric |
metricKMSKeyInaccessible()
Metric for KMS key being inaccessible.
|
Metric |
metricKMSKeyInaccessible(MetricOptions props)
Metric for KMS key being inaccessible.
|
Metric |
metricMasterCPUUtilization()
Metric for master CPU utilization.
|
Metric |
metricMasterCPUUtilization(MetricOptions props)
Metric for master CPU utilization.
|
Metric |
metricMasterJVMMemoryPressure()
Metric for master JVM memory pressure.
|
Metric |
metricMasterJVMMemoryPressure(MetricOptions props)
Metric for master JVM memory pressure.
|
Metric |
metricNodes()
Metric for the number of nodes.
|
Metric |
metricNodes(MetricOptions props)
Metric for the number of nodes.
|
Metric |
metricSearchableDocuments()
Metric for number of searchable documents.
|
Metric |
metricSearchableDocuments(MetricOptions props)
Metric for number of searchable documents.
|
Metric |
metricSearchLatency()
Metric for search latency.
|
Metric |
metricSearchLatency(MetricOptions props)
Metric for search latency.
|
applyRemovalPolicy, generatePhysicalName, getEnv, getPhysicalName, getResourceArnAttribute, getResourceNameAttribute, getStack, isResource
getNode, isConstruct, onPrepare, onSynthesize, onValidate, prepare, synthesize, validate
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
applyRemovalPolicy, getEnv, getStack
getNode
protected Domain(software.amazon.jsii.JsiiObjectRef objRef)
protected Domain(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
public Domain(software.constructs.Construct scope, java.lang.String id, DomainProps props)
scope
- This parameter is required.id
- This parameter is required.props
- This parameter is required.public static IDomain fromDomainAttributes(software.constructs.Construct scope, java.lang.String id, DomainAttributes attrs)
scope
- The parent creating construct (usually `this`). This parameter is required.id
- The construct's name. This parameter is required.attrs
- A `DomainAttributes` object. This parameter is required.public static IDomain fromDomainEndpoint(software.constructs.Construct scope, java.lang.String id, java.lang.String domainEndpoint)
scope
- The parent creating construct (usually `this`). This parameter is required.id
- The construct's name. This parameter is required.domainEndpoint
- The domain's endpoint. This parameter is required.public void addAccessPolicies(PolicyStatement... accessPolicyStatements)
accessPolicyStatements
- This parameter is required.public Grant grantIndexRead(java.lang.String index, IGrantable identity)
grantIndexRead
in interface IDomain
index
- The index to grant permissions for. This parameter is required.identity
- The principal. This parameter is required.public Grant grantIndexReadWrite(java.lang.String index, IGrantable identity)
grantIndexReadWrite
in interface IDomain
index
- The index to grant permissions for. This parameter is required.identity
- The principal. This parameter is required.public Grant grantIndexWrite(java.lang.String index, IGrantable identity)
grantIndexWrite
in interface IDomain
index
- The index to grant permissions for. This parameter is required.identity
- The principal. This parameter is required.public Grant grantPathRead(java.lang.String path, IGrantable identity)
grantPathRead
in interface IDomain
path
- The path to grant permissions for. This parameter is required.identity
- The principal. This parameter is required.public Grant grantPathReadWrite(java.lang.String path, IGrantable identity)
grantPathReadWrite
in interface IDomain
path
- The path to grant permissions for. This parameter is required.identity
- The principal. This parameter is required.public Grant grantPathWrite(java.lang.String path, IGrantable identity)
grantPathWrite
in interface IDomain
path
- The path to grant permissions for. This parameter is required.identity
- The principal. This parameter is required.public Grant grantRead(IGrantable identity)
public Grant grantReadWrite(IGrantable identity)
grantReadWrite
in interface IDomain
identity
- The principal. This parameter is required.public Grant grantWrite(IGrantable identity)
grantWrite
in interface IDomain
identity
- The principal. This parameter is required.public Metric metric(java.lang.String metricName, MetricOptions props)
public Metric metric(java.lang.String metricName)
public Metric metricAutomatedSnapshotFailure(MetricOptions props)
Default: maximum over 5 minutes
metricAutomatedSnapshotFailure
in interface IDomain
props
- public Metric metricAutomatedSnapshotFailure()
Default: maximum over 5 minutes
metricAutomatedSnapshotFailure
in interface IDomain
public Metric metricClusterIndexWritesBlocked(MetricOptions props)
Default: maximum over 1 minute
metricClusterIndexWritesBlocked
in interface IDomain
props
- public Metric metricClusterIndexWritesBlocked()
Default: maximum over 1 minute
metricClusterIndexWritesBlocked
in interface IDomain
public Metric metricClusterStatusRed(MetricOptions props)
Default: maximum over 5 minutes
metricClusterStatusRed
in interface IDomain
props
- public Metric metricClusterStatusRed()
Default: maximum over 5 minutes
metricClusterStatusRed
in interface IDomain
public Metric metricClusterStatusYellow(MetricOptions props)
Default: maximum over 5 minutes
metricClusterStatusYellow
in interface IDomain
props
- public Metric metricClusterStatusYellow()
Default: maximum over 5 minutes
metricClusterStatusYellow
in interface IDomain
public Metric metricCPUUtilization(MetricOptions props)
Default: maximum over 5 minutes
metricCPUUtilization
in interface IDomain
props
- public Metric metricCPUUtilization()
Default: maximum over 5 minutes
metricCPUUtilization
in interface IDomain
public Metric metricFreeStorageSpace(MetricOptions props)
Default: minimum over 5 minutes
metricFreeStorageSpace
in interface IDomain
props
- public Metric metricFreeStorageSpace()
Default: minimum over 5 minutes
metricFreeStorageSpace
in interface IDomain
public Metric metricIndexingLatency(MetricOptions props)
Default: p99 over 5 minutes
metricIndexingLatency
in interface IDomain
props
- public Metric metricIndexingLatency()
Default: p99 over 5 minutes
metricIndexingLatency
in interface IDomain
public Metric metricJVMMemoryPressure(MetricOptions props)
Default: maximum over 5 minutes
metricJVMMemoryPressure
in interface IDomain
props
- public Metric metricJVMMemoryPressure()
Default: maximum over 5 minutes
metricJVMMemoryPressure
in interface IDomain
public Metric metricKMSKeyError(MetricOptions props)
Default: maximum over 5 minutes
metricKMSKeyError
in interface IDomain
props
- public Metric metricKMSKeyError()
Default: maximum over 5 minutes
metricKMSKeyError
in interface IDomain
public Metric metricKMSKeyInaccessible(MetricOptions props)
Default: maximum over 5 minutes
metricKMSKeyInaccessible
in interface IDomain
props
- public Metric metricKMSKeyInaccessible()
Default: maximum over 5 minutes
metricKMSKeyInaccessible
in interface IDomain
public Metric metricMasterCPUUtilization(MetricOptions props)
Default: maximum over 5 minutes
metricMasterCPUUtilization
in interface IDomain
props
- public Metric metricMasterCPUUtilization()
Default: maximum over 5 minutes
metricMasterCPUUtilization
in interface IDomain
public Metric metricMasterJVMMemoryPressure(MetricOptions props)
Default: maximum over 5 minutes
metricMasterJVMMemoryPressure
in interface IDomain
props
- public Metric metricMasterJVMMemoryPressure()
Default: maximum over 5 minutes
metricMasterJVMMemoryPressure
in interface IDomain
public Metric metricNodes(MetricOptions props)
Default: minimum over 1 hour
metricNodes
in interface IDomain
props
- public Metric metricNodes()
Default: minimum over 1 hour
metricNodes
in interface IDomain
public Metric metricSearchableDocuments(MetricOptions props)
Default: maximum over 5 minutes
metricSearchableDocuments
in interface IDomain
props
- public Metric metricSearchableDocuments()
Default: maximum over 5 minutes
metricSearchableDocuments
in interface IDomain
public Metric metricSearchLatency(MetricOptions props)
Default: p99 over 5 minutes
metricSearchLatency
in interface IDomain
props
- public Metric metricSearchLatency()
Default: p99 over 5 minutes
metricSearchLatency
in interface IDomain
public Connections getConnections()
This will throw an error in case the domain is not placed inside a VPC.
getConnections
in interface IConnectable
public java.lang.String getDomainArn()
getDomainArn
in interface IDomain
public java.lang.String getDomainEndpoint()
getDomainEndpoint
in interface IDomain
public java.lang.String getDomainId()
getDomainId
in interface IDomain
public java.lang.String getDomainName()
getDomainName
in interface IDomain
public ILogGroup getAppLogGroup()
public ILogGroup getAuditLogGroup()
public SecretValue getMasterUserPassword()
public ILogGroup getSlowIndexLogGroup()
public ILogGroup getSlowSearchLogGroup()