ASSOCIATE-CLOUD-ENGINEER practice question 13 of 35

You are working for a hospital that stores Its medical images in an on-premises data room. The hospital wants to use Cloud Storage for archival storage of these images. The hospital wants an automated process to upload any new medical images to Cloud Storage. You need to design and implement a solution. What should you do?

Full set: 332 questions
Answer options
A: Deploy a Dataflow job from the batch template "Datastore lo Cloud Storage" Schedule the batch job on the desired interval
B: In the Cloud Console, go to Cloud Storage Upload the relevant images to the appropriate bucket
C: Create a script that uses the gsutil command line interface to synchronize the on-premises storage with Cloud Storage Schedule the script as a cron job Correct answer
D: Create a Pub/Sub topic, and enable a Cloud Storage trigger for the Pub/Sub topic. Create an application that sends all medical images to the Pub/Sub lope
Correct Answer:
C. Create a script that uses the gsutil command line interface to synchronize the on-premises storage with Cloud Storage Schedule the script as a cron job
Explanation

The gsutil rsync command is the standard and most efficient tool for synchronizing the contents of a local directory with a Cloud Storage bucket. It works by copying only the files that are new or have changed, which directly addresses the need to upload new medical images. By placing this command within a script and scheduling it to run at regular intervals using a cron job (a standard time-based job scheduler in Unix-like operating systems), the hospital can create a fully automated process. This solution is robust, simple to implement, and perfectly suited for transferring files from an on-premises environment to Cloud Storage.

Why Incorrect

A. The Dataflow "Datastore to Cloud Storage" template is designed to move data from Google Cloud Datastore, not from an on-premises file system.
B. Uploading images via the Cloud Console is a manual process and fails to meet the core requirement for an automated solution.
D. Pub/Sub is a messaging service, not a file transfer service. It has message size limits (typically 10 MB) which are often too small for medical images.

References

1. gsutil rsync command: The official documentation describes gsutil rsync as the tool to "make the contents of a destination directory or bucket match the contents of a source directory or bucket." This is precisely the required functionality.

Source: Google Cloud Documentation

gsutil rsync - Synchronize content of two buckets/directories. (cloud.google.com/storage/docs/gsutil/commands/rsync)

2. Data Transfer Options: Google Cloud's overview of data transfer options recommends gsutil for "small-to-medium transfers over a typical business-grade network from a private data center to Cloud Storage."

Source: Google Cloud Documentation

"Transferring data to Google Cloud

" Section: "Transfer from a private data center." (cloud.google.com/architecture/migration-to-google-cloud-transferring-your-large-datasets)

3. Dataflow Templates: The documentation for Dataflow templates confirms that the "Datastore to Cloud Storage" template reads data from Datastore

not an on-premises source.

Source: Google Cloud Documentation

"Google-provided templates

" Section: "Datastore to Cloud Storage." (cloud.google.com/dataflow/docs/guides/templates/provided-batch#datastore-to-cloud-storage)

4. Pub/Sub Quotas: The official documentation on Pub/Sub quotas and limits states the maximum size for the data portion of a message is 10 MB

making it unsuitable for potentially large image files.

Source: Google Cloud Documentation

"Quotas and limits

" Section: "Message-related quotas." (cloud.google.com/pubsub/quotas#message-relatedquotas)

Scroll to Top