Alibaba Cloud v3.66.0 published on Friday, Nov 15, 2024 by Pulumi
alicloud.opensearch.getAppGroups
Explore with Pulumi AI
This data source provides the Open Search App Groups of the current Alibaba Cloud user.
NOTE: Available in v1.136.0+.
Example Usage
Basic Usage
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";
const config = new pulumi.Config();
const name = config.get("name") || "tf_testacc";
const defaultAppGroup = new alicloud.opensearch.AppGroup("default", {
appGroupName: name,
paymentType: "PayAsYouGo",
type: "standard",
quota: {
docSize: 1,
computeResource: 20,
spec: "opensearch.share.common",
},
});
const default = alicloud.opensearch.getAppGroupsOutput({
ids: [defaultAppGroup.id],
});
export const appGroups = _default.apply(_default => _default.groups);
import pulumi
import pulumi_alicloud as alicloud
config = pulumi.Config()
name = config.get("name")
if name is None:
name = "tf_testacc"
default_app_group = alicloud.opensearch.AppGroup("default",
app_group_name=name,
payment_type="PayAsYouGo",
type="standard",
quota={
"doc_size": 1,
"compute_resource": 20,
"spec": "opensearch.share.common",
})
default = alicloud.opensearch.get_app_groups_output(ids=[default_app_group.id])
pulumi.export("appGroups", default.groups)
package main
import (
"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/opensearch"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi/config"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
cfg := config.New(ctx, "")
name := "tf_testacc"
if param := cfg.Get("name"); param != "" {
name = param
}
defaultAppGroup, err := opensearch.NewAppGroup(ctx, "default", &opensearch.AppGroupArgs{
AppGroupName: pulumi.String(name),
PaymentType: pulumi.String("PayAsYouGo"),
Type: pulumi.String("standard"),
Quota: &opensearch.AppGroupQuotaArgs{
DocSize: pulumi.Int(1),
ComputeResource: pulumi.Int(20),
Spec: pulumi.String("opensearch.share.common"),
},
})
if err != nil {
return err
}
_default := opensearch.GetAppGroupsOutput(ctx, opensearch.GetAppGroupsOutputArgs{
Ids: pulumi.StringArray{
defaultAppGroup.ID(),
},
}, nil)
ctx.Export("appGroups", _default.ApplyT(func(_default opensearch.GetAppGroupsResult) ([]opensearch.GetAppGroupsGroup, error) {
return []opensearch.GetAppGroupsGroup(_default.Groups), nil
}).([]opensearch.GetAppGroupsGroupOutput))
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using AliCloud = Pulumi.AliCloud;
return await Deployment.RunAsync(() =>
{
var config = new Config();
var name = config.Get("name") ?? "tf_testacc";
var defaultAppGroup = new AliCloud.OpenSearch.AppGroup("default", new()
{
AppGroupName = name,
PaymentType = "PayAsYouGo",
Type = "standard",
Quota = new AliCloud.OpenSearch.Inputs.AppGroupQuotaArgs
{
DocSize = 1,
ComputeResource = 20,
Spec = "opensearch.share.common",
},
});
var @default = AliCloud.OpenSearch.GetAppGroups.Invoke(new()
{
Ids = new[]
{
defaultAppGroup.Id,
},
});
return new Dictionary<string, object?>
{
["appGroups"] = @default.Apply(@default => @default.Apply(getAppGroupsResult => getAppGroupsResult.Groups)),
};
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.opensearch.AppGroup;
import com.pulumi.alicloud.opensearch.AppGroupArgs;
import com.pulumi.alicloud.opensearch.inputs.AppGroupQuotaArgs;
import com.pulumi.alicloud.opensearch.OpensearchFunctions;
import com.pulumi.alicloud.opensearch.inputs.GetAppGroupsArgs;
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) {
final var config = ctx.config();
final var name = config.get("name").orElse("tf_testacc");
var defaultAppGroup = new AppGroup("defaultAppGroup", AppGroupArgs.builder()
.appGroupName(name)
.paymentType("PayAsYouGo")
.type("standard")
.quota(AppGroupQuotaArgs.builder()
.docSize(1)
.computeResource(20)
.spec("opensearch.share.common")
.build())
.build());
final var default = OpensearchFunctions.getAppGroups(GetAppGroupsArgs.builder()
.ids(defaultAppGroup.id())
.build());
ctx.export("appGroups", default_.applyValue(default_ -> default_.groups()));
}
}
configuration:
name:
type: string
default: tf_testacc
resources:
defaultAppGroup:
type: alicloud:opensearch:AppGroup
name: default
properties:
appGroupName: ${name}
paymentType: PayAsYouGo
type: standard
quota:
docSize: 1
computeResource: 20
spec: opensearch.share.common
variables:
default:
fn::invoke:
Function: alicloud:opensearch:getAppGroups
Arguments:
ids:
- ${defaultAppGroup.id}
outputs:
appGroups: ${default.groups}
Using getAppGroups
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getAppGroups(args: GetAppGroupsArgs, opts?: InvokeOptions): Promise<GetAppGroupsResult>
function getAppGroupsOutput(args: GetAppGroupsOutputArgs, opts?: InvokeOptions): Output<GetAppGroupsResult>
def get_app_groups(enable_details: Optional[bool] = None,
ids: Optional[Sequence[str]] = None,
instance_id: Optional[str] = None,
name: Optional[str] = None,
name_regex: Optional[str] = None,
output_file: Optional[str] = None,
resource_group_id: Optional[str] = None,
type: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetAppGroupsResult
def get_app_groups_output(enable_details: Optional[pulumi.Input[bool]] = None,
ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
instance_id: Optional[pulumi.Input[str]] = None,
name: Optional[pulumi.Input[str]] = None,
name_regex: Optional[pulumi.Input[str]] = None,
output_file: Optional[pulumi.Input[str]] = None,
resource_group_id: Optional[pulumi.Input[str]] = None,
type: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetAppGroupsResult]
func GetAppGroups(ctx *Context, args *GetAppGroupsArgs, opts ...InvokeOption) (*GetAppGroupsResult, error)
func GetAppGroupsOutput(ctx *Context, args *GetAppGroupsOutputArgs, opts ...InvokeOption) GetAppGroupsResultOutput
> Note: This function is named GetAppGroups
in the Go SDK.
public static class GetAppGroups
{
public static Task<GetAppGroupsResult> InvokeAsync(GetAppGroupsArgs args, InvokeOptions? opts = null)
public static Output<GetAppGroupsResult> Invoke(GetAppGroupsInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetAppGroupsResult> getAppGroups(GetAppGroupsArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: alicloud:opensearch/getAppGroups:getAppGroups
arguments:
# arguments dictionary
The following arguments are supported:
- Enable
Details bool - Default to
false
. Set it totrue
can output more details about resource attributes. - Ids List<string>
- A list of App Group IDs. Its element value is same as App Group Name.
- Instance
Id string - The Instance ID.
- Name string
- Name
Regex string - A regex string to filter results by App Group name.
- Output
File string - File name where to save data source results (after running
pulumi preview
). - Resource
Group stringId - The Resource Group ID.
- Type string
- Application type. Valid Values:
standard
,enhanced
.
- Enable
Details bool - Default to
false
. Set it totrue
can output more details about resource attributes. - Ids []string
- A list of App Group IDs. Its element value is same as App Group Name.
- Instance
Id string - The Instance ID.
- Name string
- Name
Regex string - A regex string to filter results by App Group name.
- Output
File string - File name where to save data source results (after running
pulumi preview
). - Resource
Group stringId - The Resource Group ID.
- Type string
- Application type. Valid Values:
standard
,enhanced
.
- enable
Details Boolean - Default to
false
. Set it totrue
can output more details about resource attributes. - ids List<String>
- A list of App Group IDs. Its element value is same as App Group Name.
- instance
Id String - The Instance ID.
- name String
- name
Regex String - A regex string to filter results by App Group name.
- output
File String - File name where to save data source results (after running
pulumi preview
). - resource
Group StringId - The Resource Group ID.
- type String
- Application type. Valid Values:
standard
,enhanced
.
- enable
Details boolean - Default to
false
. Set it totrue
can output more details about resource attributes. - ids string[]
- A list of App Group IDs. Its element value is same as App Group Name.
- instance
Id string - The Instance ID.
- name string
- name
Regex string - A regex string to filter results by App Group name.
- output
File string - File name where to save data source results (after running
pulumi preview
). - resource
Group stringId - The Resource Group ID.
- type string
- Application type. Valid Values:
standard
,enhanced
.
- enable_
details bool - Default to
false
. Set it totrue
can output more details about resource attributes. - ids Sequence[str]
- A list of App Group IDs. Its element value is same as App Group Name.
- instance_
id str - The Instance ID.
- name str
- name_
regex str - A regex string to filter results by App Group name.
- output_
file str - File name where to save data source results (after running
pulumi preview
). - resource_
group_ strid - The Resource Group ID.
- type str
- Application type. Valid Values:
standard
,enhanced
.
- enable
Details Boolean - Default to
false
. Set it totrue
can output more details about resource attributes. - ids List<String>
- A list of App Group IDs. Its element value is same as App Group Name.
- instance
Id String - The Instance ID.
- name String
- name
Regex String - A regex string to filter results by App Group name.
- output
File String - File name where to save data source results (after running
pulumi preview
). - resource
Group StringId - The Resource Group ID.
- type String
- Application type. Valid Values:
standard
,enhanced
.
getAppGroups Result
The following output properties are available:
- Groups
List<Pulumi.
Ali Cloud. Open Search. Outputs. Get App Groups Group> - Id string
- The provider-assigned unique ID for this managed resource.
- Ids List<string>
- Names List<string>
- Enable
Details bool - Instance
Id string - Name string
- Name
Regex string - Output
File string - Resource
Group stringId - Type string
- Groups
[]Get
App Groups Group - Id string
- The provider-assigned unique ID for this managed resource.
- Ids []string
- Names []string
- Enable
Details bool - Instance
Id string - Name string
- Name
Regex string - Output
File string - Resource
Group stringId - Type string
- groups
List<Get
App Groups Group> - id String
- The provider-assigned unique ID for this managed resource.
- ids List<String>
- names List<String>
- enable
Details Boolean - instance
Id String - name String
- name
Regex String - output
File String - resource
Group StringId - type String
- groups
Get
App Groups Group[] - id string
- The provider-assigned unique ID for this managed resource.
- ids string[]
- names string[]
- enable
Details boolean - instance
Id string - name string
- name
Regex string - output
File string - resource
Group stringId - type string
- groups
Sequence[Get
App Groups Group] - id str
- The provider-assigned unique ID for this managed resource.
- ids Sequence[str]
- names Sequence[str]
- enable_
details bool - instance_
id str - name str
- name_
regex str - output_
file str - resource_
group_ strid - type str
- groups List<Property Map>
- id String
- The provider-assigned unique ID for this managed resource.
- ids List<String>
- names List<String>
- enable
Details Boolean - instance
Id String - name String
- name
Regex String - output
File String - resource
Group StringId - type String
Supporting Types
GetAppGroupsGroup
- App
Group stringId - The ID of the App Group.
- App
Group stringName - Application Group Name.
- Charge
Way int - Billing model. Valid values:
compute_resource
andqps
. - Commodity
Code string - The commodity code.
- Create
Time int - The time of creation.
- Current
Version string - The version of Application Group Name.
- Description string
- The description of the resource.
- Domain string
- Domain name.
- Expire
On string - Expiration Time.
- First
Rank intAlgo Deployment Id - Coarse deployment ID.
- Has
Pending intQuota Review Task - Whether the quota status is under approval. Valid status:
- Id string
- Instance
Id string - The Instance ID.
- Lock
Mode string - Locked state. Valid status:
Unlock
,LockByExpiration
,ManualLock
. - Locked
By intExpiration - Instance is automatically locked after expiration.
- Payment
Type string - The billing method of the resource. Valid values:
Subscription
andPayAsYouGo
. - Pending
Second intRank Algo Deployment Id - Refine deployment ID in deployment.
- Processing
Order stringId - Unfinished order number.
- Produced int
- Whether the production is completed. Valid values:
- Project
Id string - The Project ID.
- Quotas
List<Pulumi.
Ali Cloud. Open Search. Inputs. Get App Groups Group Quota> - Quota information.
- Resource
Group stringId - The Resource Group ID.
- Second
Rank intAlgo Deployment Id - Refine deployment ID.
- Status string
- The status of the resource. Valid values:
producing
,review_pending
,config_pending
,normal
,frozen
. - Switched
Time int - The Switched time.
- Type string
- Application type. Valid Values:
standard
,enhanced
.
- App
Group stringId - The ID of the App Group.
- App
Group stringName - Application Group Name.
- Charge
Way int - Billing model. Valid values:
compute_resource
andqps
. - Commodity
Code string - The commodity code.
- Create
Time int - The time of creation.
- Current
Version string - The version of Application Group Name.
- Description string
- The description of the resource.
- Domain string
- Domain name.
- Expire
On string - Expiration Time.
- First
Rank intAlgo Deployment Id - Coarse deployment ID.
- Has
Pending intQuota Review Task - Whether the quota status is under approval. Valid status:
- Id string
- Instance
Id string - The Instance ID.
- Lock
Mode string - Locked state. Valid status:
Unlock
,LockByExpiration
,ManualLock
. - Locked
By intExpiration - Instance is automatically locked after expiration.
- Payment
Type string - The billing method of the resource. Valid values:
Subscription
andPayAsYouGo
. - Pending
Second intRank Algo Deployment Id - Refine deployment ID in deployment.
- Processing
Order stringId - Unfinished order number.
- Produced int
- Whether the production is completed. Valid values:
- Project
Id string - The Project ID.
- Quotas
[]Get
App Groups Group Quota - Quota information.
- Resource
Group stringId - The Resource Group ID.
- Second
Rank intAlgo Deployment Id - Refine deployment ID.
- Status string
- The status of the resource. Valid values:
producing
,review_pending
,config_pending
,normal
,frozen
. - Switched
Time int - The Switched time.
- Type string
- Application type. Valid Values:
standard
,enhanced
.
- app
Group StringId - The ID of the App Group.
- app
Group StringName - Application Group Name.
- charge
Way Integer - Billing model. Valid values:
compute_resource
andqps
. - commodity
Code String - The commodity code.
- create
Time Integer - The time of creation.
- current
Version String - The version of Application Group Name.
- description String
- The description of the resource.
- domain String
- Domain name.
- expire
On String - Expiration Time.
- first
Rank IntegerAlgo Deployment Id - Coarse deployment ID.
- has
Pending IntegerQuota Review Task - Whether the quota status is under approval. Valid status:
- id String
- instance
Id String - The Instance ID.
- lock
Mode String - Locked state. Valid status:
Unlock
,LockByExpiration
,ManualLock
. - locked
By IntegerExpiration - Instance is automatically locked after expiration.
- payment
Type String - The billing method of the resource. Valid values:
Subscription
andPayAsYouGo
. - pending
Second IntegerRank Algo Deployment Id - Refine deployment ID in deployment.
- processing
Order StringId - Unfinished order number.
- produced Integer
- Whether the production is completed. Valid values:
- project
Id String - The Project ID.
- quotas
List<Get
App Groups Group Quota> - Quota information.
- resource
Group StringId - The Resource Group ID.
- second
Rank IntegerAlgo Deployment Id - Refine deployment ID.
- status String
- The status of the resource. Valid values:
producing
,review_pending
,config_pending
,normal
,frozen
. - switched
Time Integer - The Switched time.
- type String
- Application type. Valid Values:
standard
,enhanced
.
- app
Group stringId - The ID of the App Group.
- app
Group stringName - Application Group Name.
- charge
Way number - Billing model. Valid values:
compute_resource
andqps
. - commodity
Code string - The commodity code.
- create
Time number - The time of creation.
- current
Version string - The version of Application Group Name.
- description string
- The description of the resource.
- domain string
- Domain name.
- expire
On string - Expiration Time.
- first
Rank numberAlgo Deployment Id - Coarse deployment ID.
- has
Pending numberQuota Review Task - Whether the quota status is under approval. Valid status:
- id string
- instance
Id string - The Instance ID.
- lock
Mode string - Locked state. Valid status:
Unlock
,LockByExpiration
,ManualLock
. - locked
By numberExpiration - Instance is automatically locked after expiration.
- payment
Type string - The billing method of the resource. Valid values:
Subscription
andPayAsYouGo
. - pending
Second numberRank Algo Deployment Id - Refine deployment ID in deployment.
- processing
Order stringId - Unfinished order number.
- produced number
- Whether the production is completed. Valid values:
- project
Id string - The Project ID.
- quotas
Get
App Groups Group Quota[] - Quota information.
- resource
Group stringId - The Resource Group ID.
- second
Rank numberAlgo Deployment Id - Refine deployment ID.
- status string
- The status of the resource. Valid values:
producing
,review_pending
,config_pending
,normal
,frozen
. - switched
Time number - The Switched time.
- type string
- Application type. Valid Values:
standard
,enhanced
.
- app_
group_ strid - The ID of the App Group.
- app_
group_ strname - Application Group Name.
- charge_
way int - Billing model. Valid values:
compute_resource
andqps
. - commodity_
code str - The commodity code.
- create_
time int - The time of creation.
- current_
version str - The version of Application Group Name.
- description str
- The description of the resource.
- domain str
- Domain name.
- expire_
on str - Expiration Time.
- first_
rank_ intalgo_ deployment_ id - Coarse deployment ID.
- has_
pending_ intquota_ review_ task - Whether the quota status is under approval. Valid status:
- id str
- instance_
id str - The Instance ID.
- lock_
mode str - Locked state. Valid status:
Unlock
,LockByExpiration
,ManualLock
. - locked_
by_ intexpiration - Instance is automatically locked after expiration.
- payment_
type str - The billing method of the resource. Valid values:
Subscription
andPayAsYouGo
. - pending_
second_ intrank_ algo_ deployment_ id - Refine deployment ID in deployment.
- processing_
order_ strid - Unfinished order number.
- produced int
- Whether the production is completed. Valid values:
- project_
id str - The Project ID.
- quotas
Sequence[Get
App Groups Group Quota] - Quota information.
- resource_
group_ strid - The Resource Group ID.
- second_
rank_ intalgo_ deployment_ id - Refine deployment ID.
- status str
- The status of the resource. Valid values:
producing
,review_pending
,config_pending
,normal
,frozen
. - switched_
time int - The Switched time.
- type str
- Application type. Valid Values:
standard
,enhanced
.
- app
Group StringId - The ID of the App Group.
- app
Group StringName - Application Group Name.
- charge
Way Number - Billing model. Valid values:
compute_resource
andqps
. - commodity
Code String - The commodity code.
- create
Time Number - The time of creation.
- current
Version String - The version of Application Group Name.
- description String
- The description of the resource.
- domain String
- Domain name.
- expire
On String - Expiration Time.
- first
Rank NumberAlgo Deployment Id - Coarse deployment ID.
- has
Pending NumberQuota Review Task - Whether the quota status is under approval. Valid status:
- id String
- instance
Id String - The Instance ID.
- lock
Mode String - Locked state. Valid status:
Unlock
,LockByExpiration
,ManualLock
. - locked
By NumberExpiration - Instance is automatically locked after expiration.
- payment
Type String - The billing method of the resource. Valid values:
Subscription
andPayAsYouGo
. - pending
Second NumberRank Algo Deployment Id - Refine deployment ID in deployment.
- processing
Order StringId - Unfinished order number.
- produced Number
- Whether the production is completed. Valid values:
- project
Id String - The Project ID.
- quotas List<Property Map>
- Quota information.
- resource
Group StringId - The Resource Group ID.
- second
Rank NumberAlgo Deployment Id - Refine deployment ID.
- status String
- The status of the resource. Valid values:
producing
,review_pending
,config_pending
,normal
,frozen
. - switched
Time Number - The Switched time.
- type String
- Application type. Valid Values:
standard
,enhanced
.
GetAppGroupsGroupQuota
- Compute
Resource string - Computing resources. Unit: LCU.
- Doc
Size string - Storage Size. Unit: GB.
- Spec string
- Specification. Valid values:
opensearch.share.junior
: Entry-level.opensearch.share.common
: Shared universal.opensearch.share.compute
: Shared computing.opensearch.share.storage
: Shared storage type.opensearch.private.common
: Exclusive universal type.opensearch.private.compute
: Exclusive computing type.opensearch.private.storage
: Exclusive storage type
- Compute
Resource string - Computing resources. Unit: LCU.
- Doc
Size string - Storage Size. Unit: GB.
- Spec string
- Specification. Valid values:
opensearch.share.junior
: Entry-level.opensearch.share.common
: Shared universal.opensearch.share.compute
: Shared computing.opensearch.share.storage
: Shared storage type.opensearch.private.common
: Exclusive universal type.opensearch.private.compute
: Exclusive computing type.opensearch.private.storage
: Exclusive storage type
- compute
Resource String - Computing resources. Unit: LCU.
- doc
Size String - Storage Size. Unit: GB.
- spec String
- Specification. Valid values:
opensearch.share.junior
: Entry-level.opensearch.share.common
: Shared universal.opensearch.share.compute
: Shared computing.opensearch.share.storage
: Shared storage type.opensearch.private.common
: Exclusive universal type.opensearch.private.compute
: Exclusive computing type.opensearch.private.storage
: Exclusive storage type
- compute
Resource string - Computing resources. Unit: LCU.
- doc
Size string - Storage Size. Unit: GB.
- spec string
- Specification. Valid values:
opensearch.share.junior
: Entry-level.opensearch.share.common
: Shared universal.opensearch.share.compute
: Shared computing.opensearch.share.storage
: Shared storage type.opensearch.private.common
: Exclusive universal type.opensearch.private.compute
: Exclusive computing type.opensearch.private.storage
: Exclusive storage type
- compute_
resource str - Computing resources. Unit: LCU.
- doc_
size str - Storage Size. Unit: GB.
- spec str
- Specification. Valid values:
opensearch.share.junior
: Entry-level.opensearch.share.common
: Shared universal.opensearch.share.compute
: Shared computing.opensearch.share.storage
: Shared storage type.opensearch.private.common
: Exclusive universal type.opensearch.private.compute
: Exclusive computing type.opensearch.private.storage
: Exclusive storage type
- compute
Resource String - Computing resources. Unit: LCU.
- doc
Size String - Storage Size. Unit: GB.
- spec String
- Specification. Valid values:
opensearch.share.junior
: Entry-level.opensearch.share.common
: Shared universal.opensearch.share.compute
: Shared computing.opensearch.share.storage
: Shared storage type.opensearch.private.common
: Exclusive universal type.opensearch.private.compute
: Exclusive computing type.opensearch.private.storage
: Exclusive storage type
Package Details
- Repository
- Alibaba Cloud pulumi/pulumi-alicloud
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
alicloud
Terraform Provider.