Welcome to ExamTopics
ExamTopics Logo
- Expert Verified, Online, Free.
exam questions

Exam Associate Cloud Engineer All Questions

View all questions & answers for the Associate Cloud Engineer exam

Exam Associate Cloud Engineer topic 1 question 102 discussion

Actual exam question from Google's Associate Cloud Engineer
Question #: 102
Topic #: 1
[All Associate Cloud Engineer Questions]

Your organization needs to grant users access to query datasets in BigQuery but prevent them from accidentally deleting the datasets. You want a solution that follows Google-recommended practices. What should you do?

  • A. Add users to roles/bigquery user role only, instead of roles/bigquery dataOwner.
  • B. Add users to roles/bigquery dataEditor role only, instead of roles/bigquery dataOwner.
  • C. Create a custom role by removing delete permissions, and add users to that role only.
  • D. Create a custom role by removing delete permissions. Add users to the group, and then add the group to the custom role.
Show Suggested Answer Hide Answer
Suggested Answer: D 🗳️

Comments

Chosen Answer:
This is a voting comment (?) , you can switch to a simple comment.
Switch to a voting comment New
someoneinthecloud
Highly Voted 4 years, 4 months ago
I believe the key part is the "following Google Best Practices" phrase. A - Works, but doesn't follow GCP best practices B - Doesn't work as the role grants permission to delete datasets C - Works, but is more complicated than A and doesn't follow Google best practices D - Correct, more complicated than A, but it follows Google Best Practices.
upvoted 73 times
TAvenger
3 years, 8 months ago
Read description carefully "prevent from accidentally deleting the datasets". Not tables, datasets! option B does not allow to delete datesets either. Check dateset permissions in the roles/bigquery.dataEditor: bigquery.datasets.create bigquery.datasets.get bigquery.datasets.getIamPolicy bigquery.datasets.updateTag You CANNOT delete dataset with option "B"
upvoted 11 times
Bableves
2 years, 7 months ago
Netiher with A.
upvoted 1 times
...
afooh
2 years, 3 months ago
But it means you will have to add the users one by one which doesn't follow Google best practices...
upvoted 3 times
...
...
YuvarajK
3 years, 5 months ago
I think A is the Answer and it follow GCP best practices. https://cloud.google.com/iam/docs/understanding-roles#bigquery-roles We do have the role - BigQuery User which does the below permissions When applied to a project, this role also provides the ability to run jobs, including queries, within the project. bigquery.datasets.create bigquery.datasets.get bigquery.datasets.getIamPolicy
upvoted 12 times
Abhi00754
1 year, 7 months ago
bigquery.datasets.create allows the creation of new datasets within the project; the creator is granted the BigQuery Data Owner role (roles/bigquery.dataOwner) on these new datasets so he can delete these created datasets
upvoted 4 times
Abhi00754
1 year, 7 months ago
D seems correct
upvoted 4 times
...
...
...
kyo
3 years, 4 months ago
I don't think A works properly. roles/bigquery.user has bigquery.datasets.create. And the documentation states: > Additional, allows the creation of new datasets within the project; the creator is granted the BigQuery Data Owner role (roles/bigquery.dataOwner) on these new datasets. If bigquery.user creates a new dataset, it's likely that bigquery.user will get permission to delete that dataset. This means that bigquery.user may have permission to delete data. https://cloud.google.com/bigquery/docs/access-control
upvoted 13 times
Bossam
2 years, 4 months ago
See the question carefully "accidentally deleting the datasets" it is saying not to delete "the" datasets which means original dataset which existed before his creation .So answer is A.
upvoted 1 times
Zina12
1 year, 11 months ago
The only way a user can accidentally delete a dataset is if they have the delete permission anyway. So brvinod and kyo's points still stand
upvoted 3 times
...
...
brvinod
2 years, 9 months ago
A bigquery.user will get a "data owner" role on the datasets he creates. That means he can delete those data sets he created. In that sense A fails to that extent.
upvoted 5 times
...
...
...
ESP_SAP
Highly Voted 4 years, 3 months ago
Correct Answer is (D): The proper answer regarding to bigquery roles is the listed in the options, the proper rol that resolve this requirement is: roles/bigquery.dataViewer https://cloud.google.com/bigquery/docs/access-control#custom_roles on the other hand, the question explicitly is asking to use the GCP best practices on IAM : GCP Best Practices explain clearly these rules: Policy management ❑ Set organization-level IAM policies to grant access to all projects in your organization. ❑ Grant roles to a Google group instead of individual users when possible. It is easier to add members to and remove members from a Google group instead of updating an IAM policy to add or remove users. ❑ If you need to grant multiple roles to allow a particular task, create a Google group, grant the roles to that group, and then add users to that group. https://cloud.google.com/iam/docs/using-iam-securely#policy_management
upvoted 57 times
JackGlemins
3 years, 9 months ago
Other best practice is use predefine roles over custom roles. Maybe A is correct
upvoted 8 times
JackGlemins
3 years, 9 months ago
I correct myself: https://cloud.google.com/iam/docs/understanding-custom-roles Key Point: Custom roles enable you to enforce the principle of least privilege, ensuring that the user and service accounts in your organization have only the permissions essential to performing their intended functions.
upvoted 6 times
...
...
prashuG
4 years, 2 months ago
Answer is A: roles/bigquery.user is a BigQuery User role which when applied to a project provides the ability to run jobs, including queries, within the project. A member with this role can enumerate their own jobs, cancel their own jobs, and enumerate datasets within a project. Ref: https://cloud.google.com/iam/docs/understanding-roles#bigquery-roles
upvoted 5 times
j1c4b
3 years, 7 months ago
you can create data set with bigquery.user role because it has bigquery.datasets.create permissions. And if a user has bigquery.datasets.create permissions, when that user creates a dataset, they are granted bigquery.dataOwner access to it. So A is NOT a choice
upvoted 5 times
...
...
...
Anji14
Most Recent 2 months ago
A is correct because the key point is.. users can query the dataset but not delete. For querying, jobs create role required which comes under bigquery user role
upvoted 1 times
...
Timfdklfajlksdjlakf
2 months, 3 weeks ago
Selected Answer: D
D. follows Google Best Practice. Others do not or are flat out wrong.
upvoted 1 times
...
omunoz
6 months, 2 weeks ago
Selected Answer: D
GCP Best Practices is to create a group of Users and assign it a custom role with the required permissions (least privilege).
upvoted 1 times
...
rahulsahni849
8 months, 2 weeks ago
Selected Answer: A
A IS THE ANWER
upvoted 1 times
...
blackBeard33
9 months ago
Selected Answer: D
D is solves the problem and follow best practices. With A you will be able to delete data sets you create.
upvoted 1 times
...
Aks14
9 months, 1 week ago
Selected Answer: A
You can create a custom role at the project or organization level. Since users are added to role, it should be A. https://cloud.google.com/iam/docs/creating-custom-roles
upvoted 1 times
...
leoalvarezh
9 months, 1 week ago
Selected Answer: A
I think the right answer is A due to a predefine valid role. I mean that biqguery.user role is valid so it's not needed to create a custom role. bigquery.user role can't delete datasets created by anyone. https://cloud.google.com/iam/docs/understanding-roles#bigquery.user bigquery.datasets.delete bigquery.datasets.deleteTagBinding
upvoted 1 times
...
leoalvarezh
9 months, 1 week ago
I think the right answer is A due to a predefine valid role. I mean that biqguery.user role is valid so it's not needed to create a custom role. bigquery.user role can't delete datasets. https://cloud.google.com/iam/docs/understanding-roles#bigquery.user
upvoted 1 times
...
kuracpalac
9 months, 2 weeks ago
Selected Answer: A
I think it's A for a couple of reasons. 1. you don't need to create a custom role if there is already one there, an it's Google best practice to ALWAYS use their roles, not create new ones unless absolutely necessary, which is very few cases and I'd be surprised if they'd put a Q in there that would actually . 2. the "roles/bigquery.user" role already allows for bigquery.datasets.create, bigquery.datasets.get, bigquery.datasets.getIamPolicy, which this Q is asking for.
upvoted 1 times
...
bubidubi
9 months, 2 weeks ago
I have no idea, but I think it's D as you add users to group first, then to a role, which is google best practice, but not sure about custom role in the first place.
upvoted 1 times
...
kelliot
12 months ago
Selected Answer: A
I gonna with A and not D as best practices is to use predefined roles.
upvoted 2 times
...
nathanBK
1 year ago
Selected Answer: C
The correct answer is C. Create a custom role by removing delete permissions, and add users to that role only. This is the recommended approach by Google, as it provides a granular level of control over user permissions. By creating a custom role that only allows users to query datasets, you can ensure that they do not have the ability to accidentally delete them.
upvoted 1 times
...
BAofBK
1 year ago
The correct answer is D
upvoted 1 times
...
VijKall
1 year ago
Selected Answer: A
I will go with A and not D as best practices is to use predefined roles. If the question had "least previledge" then answer would have been D.
upvoted 1 times
...
ekta25
1 year, 1 month ago
A. Add users to roles/bigquery user role only, instead of roles/bigquery dataOwner.
upvoted 1 times
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...