google_healthcare_fhir_store

A FhirStore is a datastore inside a Healthcare dataset that conforms to the FHIR (https://www.hl7.org/fhir/STU3/) standard for Healthcare information exchange

To get more information about FhirStore, see:

Open in Cloud Shell

Example Usage - Healthcare Fhir Store Basic

resource "google_healthcare_fhir_store" "default" {
  name    = "example-fhir-store"
  dataset = google_healthcare_dataset.dataset.id
  version = "R4"
  complex_data_type_reference_parsing = "DISABLED"

  enable_update_create           = false
  disable_referential_integrity  = false
  disable_resource_versioning    = false
  enable_history_import          = false
  default_search_handling_strict = false

  notification_config {
    pubsub_topic = google_pubsub_topic.topic.id
  }

  labels = {
    label1 = "labelvalue1"
  }
}

resource "google_pubsub_topic" "topic" {
  name     = "fhir-notifications"
}

resource "google_healthcare_dataset" "dataset" {
  name     = "example-dataset"
  location = "us-central1"
}
Open in Cloud Shell

Example Usage - Healthcare Fhir Store Streaming Config

resource "google_healthcare_fhir_store" "default" {
  name    = "example-fhir-store"
  dataset = google_healthcare_dataset.dataset.id
  version = "R4"

  enable_update_create          = false
  disable_referential_integrity = false
  disable_resource_versioning   = false
  enable_history_import         = false

  labels = {
    label1 = "labelvalue1"
  }

  stream_configs {
    resource_types = ["Observation"]
    bigquery_destination {
      dataset_uri = "bq://${google_bigquery_dataset.bq_dataset.project}.${google_bigquery_dataset.bq_dataset.dataset_id}"
      schema_config {
        recursive_structure_depth = 3
        last_updated_partition_config {
          type = "HOUR"
          expiration_ms = 1000000
        }
      }
    }
  }
}

resource "google_pubsub_topic" "topic" {
  name     = "fhir-notifications"
}

resource "google_healthcare_dataset" "dataset" {
  name     = "example-dataset"
  location = "us-central1"
}

resource "google_bigquery_dataset" "bq_dataset" {
  dataset_id    = "bq_example_dataset"
  friendly_name = "test"
  description   = "This is a test description"
  location      = "US"
  delete_contents_on_destroy = true
}
Open in Cloud Shell

Example Usage - Healthcare Fhir Store Notification Config

resource "google_healthcare_fhir_store" "default" {
  name    = "example-fhir-store"
  dataset = google_healthcare_dataset.dataset.id
  version = "R4"

  enable_update_create          = false
  disable_referential_integrity = false
  disable_resource_versioning   = false
  enable_history_import         = false

  labels = {
    label1 = "labelvalue1"
  }

  notification_config {
    pubsub_topic = "${google_pubsub_topic.topic.id}"
  }
}

resource "google_pubsub_topic" "topic" {
  name = "fhir-notifications"
}

resource "google_healthcare_dataset" "dataset" {
  name     = "example-dataset"
  location = "us-central1"
}
Open in Cloud Shell

Example Usage - Healthcare Fhir Store Notification Configs

resource "google_healthcare_fhir_store" "default" {
  provider = google-beta
  name     = "example-fhir-store"
  dataset  = google_healthcare_dataset.dataset.id
  version  = "R4"

  enable_update_create          = false
  disable_referential_integrity = false
  disable_resource_versioning   = false
  enable_history_import         = false
  enable_history_modifications  = false

  labels = {
    label1 = "labelvalue1"
  }

  notification_configs {
    pubsub_topic                     = "${google_pubsub_topic.topic.id}"
    send_full_resource               = true
    send_previous_resource_on_delete = true
  }
}

resource "google_pubsub_topic" "topic" {
  provider = google-beta
  name     = "fhir-notifications"
}

resource "google_healthcare_dataset" "dataset" {
  provider = google-beta
  name     = "example-dataset"
  location = "us-central1"
}

Argument Reference

The following arguments are supported:


The notification_config block supports:

The stream_configs block supports:

The bigquery_destination block supports:

The schema_config block supports:

The last_updated_partition_config block supports:

The notification_configs block supports:

Attributes Reference

In addition to the arguments listed above, the following computed attributes are exported:

Timeouts

This resource provides the following Timeouts configuration options:

Import

FhirStore can be imported using any of these accepted formats:

In Terraform v1.5.0 and later, use an import block to import FhirStore using one of the formats above. For example:

import {
  id = "{{dataset}}/fhirStores/{{name}}"
  to = google_healthcare_fhir_store.default
}

When using the terraform import command, FhirStore can be imported using one of the formats above. For example:

$ terraform import google_healthcare_fhir_store.default {{dataset}}/fhirStores/{{name}}
$ terraform import google_healthcare_fhir_store.default {{dataset}}/{{name}}