Skip to content

Commit

Permalink
Fix issue#20603 (#13295)
Browse files Browse the repository at this point in the history
  • Loading branch information
jialei-chen authored Mar 7, 2025
1 parent bfce3cf commit 184ff95
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 3 deletions.
1 change: 0 additions & 1 deletion mmv1/products/discoveryengine/SearchEngine.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,6 @@ properties:
description: |
The data stores associated with this engine. For SOLUTION_TYPE_SEARCH type of engines, they can only associate with at most one data store.
required: true
immutable: true
item_type:
type: String
- name: 'createTime'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
package discoveryengine_test

import (
"testing"

"github.com/hashicorp/terraform-plugin-testing/helper/resource"
"github.com/hashicorp/terraform-provider-google/google/acctest"
"testing"
)

func TestAccDiscoveryEngineSearchEngine_discoveryengineSearchengineBasicExample_update(t *testing.T) {
Expand Down Expand Up @@ -53,12 +54,21 @@ resource "google_discovery_engine_data_store" "basic" {
solution_types = ["SOLUTION_TYPE_SEARCH"]
create_advanced_site_search = false
}
resource "google_discovery_engine_data_store" "second" {
location = "global"
data_store_id = "tf-test-example2-datastore%{random_suffix}"
display_name = "tf-test-structured-datastore2"
industry_vertical = "GENERIC"
content_config = "NO_CONTENT"
solution_types = ["SOLUTION_TYPE_SEARCH"]
create_advanced_site_search = false
}
resource "google_discovery_engine_search_engine" "basic" {
engine_id = "tf-test-example-engine-id%{random_suffix}"
collection_id = "default_collection"
location = google_discovery_engine_data_store.basic.location
display_name = "Example Display Name"
data_store_ids = [google_discovery_engine_data_store.basic.data_store_id]
data_store_ids = [google_discovery_engine_data_store.basic.data_store_id, google_discovery_engine_data_store.second.data_store_id]
industry_vertical = google_discovery_engine_data_store.basic.industry_vertical
common_config {
company_name = "Example Company Name"
Expand All @@ -82,6 +92,15 @@ resource "google_discovery_engine_data_store" "basic" {
solution_types = ["SOLUTION_TYPE_SEARCH"]
create_advanced_site_search = false
}
resource "google_discovery_engine_data_store" "second" {
location = "global"
data_store_id = "tf-test-example2-datastore%{random_suffix}"
display_name = "tf-test-structured-datastore2"
industry_vertical = "GENERIC"
content_config = "NO_CONTENT"
solution_types = ["SOLUTION_TYPE_SEARCH"]
create_advanced_site_search = false
}
resource "google_discovery_engine_search_engine" "basic" {
engine_id = "tf-test-example-engine-id%{random_suffix}"
collection_id = "default_collection"
Expand Down

0 comments on commit 184ff95

Please sign in to comment.