Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion modules/bq-log-alerting/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ module "bq-log-alerting" {
function_entry_point = "cronPubSub"
function_source_directory = "${path.module}/logging/cloud_function"
function_name = "generate-alerts"
function_runtime = "nodejs14"
function_runtime = "nodejs20"
function_service_account_email = google_service_account.gcf_service_account.email
function_timeout_s = var.function_timeout
function_available_memory_mb = var.function_memory
Expand Down
2 changes: 1 addition & 1 deletion test/integration/bq-log-alerting/controls/gcp.rb
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@
its('description') { should eq 'read from BQ view to generate alerts' }
its('timeout') { should eq '540s' }
its('available_memory_mb') { should eq 256 }
its('runtime') { should eq 'nodejs14' }
its('runtime') { should eq 'nodejs20' }
its('environment_variables') {
should include(
'CSCC_SOURCE' => source_name,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -85,8 +85,8 @@ func TestLogBucketProjectModule(t *testing.T) {
assert.Equal(tc.writerIdentity, logSinkDetails.Get("writerIdentity").String(), "log sink writerIdentity should match")

// assert linked dataset name & BigQuery Dataset ID
projectNumber := gcloud.Runf(t, "projects describe %s", tc.projId).Get("projectNumber").String()
bigqueryDatasetID := fmt.Sprintf("bigquery.googleapis.com/projects/%s/datasets/%s", projectNumber, tc.linkedDsID)
// projectNumber := gcloud.Runf(t, "projects describe %s", tc.projId).Get("projectNumber").String()
bigqueryDatasetID := fmt.Sprintf("bigquery.googleapis.com/projects/%s/datasets/%s", tc.projId, tc.linkedDsID)
linkedDs := gcloud.Runf(t, "logging links describe %s --bucket=%s --location=%s --project=%s", tc.linkedDsID, tc.bktName, "global", tc.projId)
assert.Equal(tc.linkedDsName, linkedDs.Get("name").String(), "log bucket linked dataset name should match")
assert.Equal(bigqueryDatasetID, linkedDs.Get("bigqueryDataset.datasetId").String(), "log bucket BigQuery dataset ID should match")
Expand Down