1. Packages
  2. Google Cloud Native
  3. API Docs
  4. datastore
  5. datastore/v1
  6. Index

Google Cloud Native is in preview. Google Cloud Classic is fully supported.

Google Cloud Native v0.32.0 published on Wednesday, Nov 29, 2023 by Pulumi

google-native.datastore/v1.Index

Explore with Pulumi AI

google-native logo

Google Cloud Native is in preview. Google Cloud Classic is fully supported.

Google Cloud Native v0.32.0 published on Wednesday, Nov 29, 2023 by Pulumi

    Creates the specified index. A newly created index’s initial state is CREATING. On completion of the returned google.longrunning.Operation, the state will be READY. If the index already exists, the call will return an ALREADY_EXISTS status. During index creation, the process could result in an error, in which case the index will move to the ERROR state. The process can be recovered by fixing the data that caused the error, removing the index with delete, then re-creating the index with create. Indexes with a single property cannot be created. Auto-naming is currently not supported for this resource.

    Create Index Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new Index(name: string, args: IndexArgs, opts?: CustomResourceOptions);
    @overload
    def Index(resource_name: str,
              args: IndexArgs,
              opts: Optional[ResourceOptions] = None)
    
    @overload
    def Index(resource_name: str,
              opts: Optional[ResourceOptions] = None,
              ancestor: Optional[IndexAncestor] = None,
              kind: Optional[str] = None,
              properties: Optional[Sequence[GoogleDatastoreAdminV1IndexedPropertyArgs]] = None,
              project: Optional[str] = None)
    func NewIndex(ctx *Context, name string, args IndexArgs, opts ...ResourceOption) (*Index, error)
    public Index(string name, IndexArgs args, CustomResourceOptions? opts = null)
    public Index(String name, IndexArgs args)
    public Index(String name, IndexArgs args, CustomResourceOptions options)
    
    type: google-native:datastore/v1:Index
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args IndexArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args IndexArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args IndexArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args IndexArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args IndexArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Example

    The following reference example uses placeholder values for all input properties.

    var exampleindexResourceResourceFromDatastorev1 = new GoogleNative.Datastore.V1.Index("exampleindexResourceResourceFromDatastorev1", new()
    {
        Ancestor = GoogleNative.Datastore.V1.IndexAncestor.AncestorModeUnspecified,
        Kind = "string",
        Properties = new[]
        {
            new GoogleNative.Datastore.V1.Inputs.GoogleDatastoreAdminV1IndexedPropertyArgs
            {
                Direction = GoogleNative.Datastore.V1.GoogleDatastoreAdminV1IndexedPropertyDirection.DirectionUnspecified,
                Name = "string",
            },
        },
        Project = "string",
    });
    
    example, err := datastore.NewIndex(ctx, "exampleindexResourceResourceFromDatastorev1", &datastore.IndexArgs{
    Ancestor: datastore.IndexAncestorAncestorModeUnspecified,
    Kind: pulumi.String("string"),
    Properties: datastore.GoogleDatastoreAdminV1IndexedPropertyArray{
    &datastore.GoogleDatastoreAdminV1IndexedPropertyArgs{
    Direction: datastore.GoogleDatastoreAdminV1IndexedPropertyDirectionDirectionUnspecified,
    Name: pulumi.String("string"),
    },
    },
    Project: pulumi.String("string"),
    })
    
    var exampleindexResourceResourceFromDatastorev1 = new Index("exampleindexResourceResourceFromDatastorev1", IndexArgs.builder()        
        .ancestor("ANCESTOR_MODE_UNSPECIFIED")
        .kind("string")
        .properties(GoogleDatastoreAdminV1IndexedPropertyArgs.builder()
            .direction("DIRECTION_UNSPECIFIED")
            .name("string")
            .build())
        .project("string")
        .build());
    
    exampleindex_resource_resource_from_datastorev1 = google_native.datastore.v1.Index("exampleindexResourceResourceFromDatastorev1",
        ancestor=google_native.datastore.v1.IndexAncestor.ANCESTOR_MODE_UNSPECIFIED,
        kind="string",
        properties=[google_native.datastore.v1.GoogleDatastoreAdminV1IndexedPropertyArgs(
            direction=google_native.datastore.v1.GoogleDatastoreAdminV1IndexedPropertyDirection.DIRECTION_UNSPECIFIED,
            name="string",
        )],
        project="string")
    
    const exampleindexResourceResourceFromDatastorev1 = new google_native.datastore.v1.Index("exampleindexResourceResourceFromDatastorev1", {
        ancestor: google_native.datastore.v1.IndexAncestor.AncestorModeUnspecified,
        kind: "string",
        properties: [{
            direction: google_native.datastore.v1.GoogleDatastoreAdminV1IndexedPropertyDirection.DirectionUnspecified,
            name: "string",
        }],
        project: "string",
    });
    
    type: google-native:datastore/v1:Index
    properties:
        ancestor: ANCESTOR_MODE_UNSPECIFIED
        kind: string
        project: string
        properties:
            - direction: DIRECTION_UNSPECIFIED
              name: string
    

    Index Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    The Index resource accepts the following input properties:

    Ancestor Pulumi.GoogleNative.Datastore.V1.IndexAncestor
    The index's ancestor mode. Must not be ANCESTOR_MODE_UNSPECIFIED.
    Kind string
    The entity kind to which this index applies.
    Properties List<Pulumi.GoogleNative.Datastore.V1.Inputs.GoogleDatastoreAdminV1IndexedProperty>
    An ordered sequence of property names and their index attributes. Requires: * A maximum of 100 properties.
    Project string
    Ancestor IndexAncestor
    The index's ancestor mode. Must not be ANCESTOR_MODE_UNSPECIFIED.
    Kind string
    The entity kind to which this index applies.
    Properties []GoogleDatastoreAdminV1IndexedPropertyArgs
    An ordered sequence of property names and their index attributes. Requires: * A maximum of 100 properties.
    Project string
    ancestor IndexAncestor
    The index's ancestor mode. Must not be ANCESTOR_MODE_UNSPECIFIED.
    kind String
    The entity kind to which this index applies.
    properties List<GoogleDatastoreAdminV1IndexedProperty>
    An ordered sequence of property names and their index attributes. Requires: * A maximum of 100 properties.
    project String
    ancestor IndexAncestor
    The index's ancestor mode. Must not be ANCESTOR_MODE_UNSPECIFIED.
    kind string
    The entity kind to which this index applies.
    properties GoogleDatastoreAdminV1IndexedProperty[]
    An ordered sequence of property names and their index attributes. Requires: * A maximum of 100 properties.
    project string
    ancestor IndexAncestor
    The index's ancestor mode. Must not be ANCESTOR_MODE_UNSPECIFIED.
    kind str
    The entity kind to which this index applies.
    properties Sequence[GoogleDatastoreAdminV1IndexedPropertyArgs]
    An ordered sequence of property names and their index attributes. Requires: * A maximum of 100 properties.
    project str
    ancestor "ANCESTOR_MODE_UNSPECIFIED" | "NONE" | "ALL_ANCESTORS"
    The index's ancestor mode. Must not be ANCESTOR_MODE_UNSPECIFIED.
    kind String
    The entity kind to which this index applies.
    properties List<Property Map>
    An ordered sequence of property names and their index attributes. Requires: * A maximum of 100 properties.
    project String

    Outputs

    All input properties are implicitly available as output properties. Additionally, the Index resource produces the following output properties:

    Id string
    The provider-assigned unique ID for this managed resource.
    IndexId string
    The resource ID of the index.
    State string
    The state of the index.
    Id string
    The provider-assigned unique ID for this managed resource.
    IndexId string
    The resource ID of the index.
    State string
    The state of the index.
    id String
    The provider-assigned unique ID for this managed resource.
    indexId String
    The resource ID of the index.
    state String
    The state of the index.
    id string
    The provider-assigned unique ID for this managed resource.
    indexId string
    The resource ID of the index.
    state string
    The state of the index.
    id str
    The provider-assigned unique ID for this managed resource.
    index_id str
    The resource ID of the index.
    state str
    The state of the index.
    id String
    The provider-assigned unique ID for this managed resource.
    indexId String
    The resource ID of the index.
    state String
    The state of the index.

    Supporting Types

    GoogleDatastoreAdminV1IndexedProperty, GoogleDatastoreAdminV1IndexedPropertyArgs

    Direction Pulumi.GoogleNative.Datastore.V1.GoogleDatastoreAdminV1IndexedPropertyDirection
    The indexed property's direction. Must not be DIRECTION_UNSPECIFIED.
    Name string
    The property name to index.
    Direction GoogleDatastoreAdminV1IndexedPropertyDirection
    The indexed property's direction. Must not be DIRECTION_UNSPECIFIED.
    Name string
    The property name to index.
    direction GoogleDatastoreAdminV1IndexedPropertyDirection
    The indexed property's direction. Must not be DIRECTION_UNSPECIFIED.
    name String
    The property name to index.
    direction GoogleDatastoreAdminV1IndexedPropertyDirection
    The indexed property's direction. Must not be DIRECTION_UNSPECIFIED.
    name string
    The property name to index.
    direction GoogleDatastoreAdminV1IndexedPropertyDirection
    The indexed property's direction. Must not be DIRECTION_UNSPECIFIED.
    name str
    The property name to index.
    direction "DIRECTION_UNSPECIFIED" | "ASCENDING" | "DESCENDING"
    The indexed property's direction. Must not be DIRECTION_UNSPECIFIED.
    name String
    The property name to index.

    GoogleDatastoreAdminV1IndexedPropertyDirection, GoogleDatastoreAdminV1IndexedPropertyDirectionArgs

    DirectionUnspecified
    DIRECTION_UNSPECIFIEDThe direction is unspecified.
    Ascending
    ASCENDINGThe property's values are indexed so as to support sequencing in ascending order and also query by <, >, <=, >=, and =.
    Descending
    DESCENDINGThe property's values are indexed so as to support sequencing in descending order and also query by <, >, <=, >=, and =.
    GoogleDatastoreAdminV1IndexedPropertyDirectionDirectionUnspecified
    DIRECTION_UNSPECIFIEDThe direction is unspecified.
    GoogleDatastoreAdminV1IndexedPropertyDirectionAscending
    ASCENDINGThe property's values are indexed so as to support sequencing in ascending order and also query by <, >, <=, >=, and =.
    GoogleDatastoreAdminV1IndexedPropertyDirectionDescending
    DESCENDINGThe property's values are indexed so as to support sequencing in descending order and also query by <, >, <=, >=, and =.
    DirectionUnspecified
    DIRECTION_UNSPECIFIEDThe direction is unspecified.
    Ascending
    ASCENDINGThe property's values are indexed so as to support sequencing in ascending order and also query by <, >, <=, >=, and =.
    Descending
    DESCENDINGThe property's values are indexed so as to support sequencing in descending order and also query by <, >, <=, >=, and =.
    DirectionUnspecified
    DIRECTION_UNSPECIFIEDThe direction is unspecified.
    Ascending
    ASCENDINGThe property's values are indexed so as to support sequencing in ascending order and also query by <, >, <=, >=, and =.
    Descending
    DESCENDINGThe property's values are indexed so as to support sequencing in descending order and also query by <, >, <=, >=, and =.
    DIRECTION_UNSPECIFIED
    DIRECTION_UNSPECIFIEDThe direction is unspecified.
    ASCENDING
    ASCENDINGThe property's values are indexed so as to support sequencing in ascending order and also query by <, >, <=, >=, and =.
    DESCENDING
    DESCENDINGThe property's values are indexed so as to support sequencing in descending order and also query by <, >, <=, >=, and =.
    "DIRECTION_UNSPECIFIED"
    DIRECTION_UNSPECIFIEDThe direction is unspecified.
    "ASCENDING"
    ASCENDINGThe property's values are indexed so as to support sequencing in ascending order and also query by <, >, <=, >=, and =.
    "DESCENDING"
    DESCENDINGThe property's values are indexed so as to support sequencing in descending order and also query by <, >, <=, >=, and =.

    GoogleDatastoreAdminV1IndexedPropertyResponse, GoogleDatastoreAdminV1IndexedPropertyResponseArgs

    Direction string
    The indexed property's direction. Must not be DIRECTION_UNSPECIFIED.
    Name string
    The property name to index.
    Direction string
    The indexed property's direction. Must not be DIRECTION_UNSPECIFIED.
    Name string
    The property name to index.
    direction String
    The indexed property's direction. Must not be DIRECTION_UNSPECIFIED.
    name String
    The property name to index.
    direction string
    The indexed property's direction. Must not be DIRECTION_UNSPECIFIED.
    name string
    The property name to index.
    direction str
    The indexed property's direction. Must not be DIRECTION_UNSPECIFIED.
    name str
    The property name to index.
    direction String
    The indexed property's direction. Must not be DIRECTION_UNSPECIFIED.
    name String
    The property name to index.

    IndexAncestor, IndexAncestorArgs

    AncestorModeUnspecified
    ANCESTOR_MODE_UNSPECIFIEDThe ancestor mode is unspecified.
    None
    NONEDo not include the entity's ancestors in the index.
    AllAncestors
    ALL_ANCESTORSInclude all the entity's ancestors in the index.
    IndexAncestorAncestorModeUnspecified
    ANCESTOR_MODE_UNSPECIFIEDThe ancestor mode is unspecified.
    IndexAncestorNone
    NONEDo not include the entity's ancestors in the index.
    IndexAncestorAllAncestors
    ALL_ANCESTORSInclude all the entity's ancestors in the index.
    AncestorModeUnspecified
    ANCESTOR_MODE_UNSPECIFIEDThe ancestor mode is unspecified.
    None
    NONEDo not include the entity's ancestors in the index.
    AllAncestors
    ALL_ANCESTORSInclude all the entity's ancestors in the index.
    AncestorModeUnspecified
    ANCESTOR_MODE_UNSPECIFIEDThe ancestor mode is unspecified.
    None
    NONEDo not include the entity's ancestors in the index.
    AllAncestors
    ALL_ANCESTORSInclude all the entity's ancestors in the index.
    ANCESTOR_MODE_UNSPECIFIED
    ANCESTOR_MODE_UNSPECIFIEDThe ancestor mode is unspecified.
    NONE
    NONEDo not include the entity's ancestors in the index.
    ALL_ANCESTORS
    ALL_ANCESTORSInclude all the entity's ancestors in the index.
    "ANCESTOR_MODE_UNSPECIFIED"
    ANCESTOR_MODE_UNSPECIFIEDThe ancestor mode is unspecified.
    "NONE"
    NONEDo not include the entity's ancestors in the index.
    "ALL_ANCESTORS"
    ALL_ANCESTORSInclude all the entity's ancestors in the index.

    Package Details

    Repository
    Google Cloud Native pulumi/pulumi-google-native
    License
    Apache-2.0
    google-native logo

    Google Cloud Native is in preview. Google Cloud Classic is fully supported.

    Google Cloud Native v0.32.0 published on Wednesday, Nov 29, 2023 by Pulumi