GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Ability to list projects with BigQuery · Issue #3087 · googleapis/google-cloud-java

Ability to list projects with BigQuery #3087

New issue
Copy link
New issue
Copy link
Closed
Closed
Ability to list projects with BigQuery#3087
Copy link
Assignees
shollyman
Labels
🚨 criticalP0 critical issue. Requires immediate fixapi: bigqueryIssues related to the BigQuery API.priority: p2Moderately-important priority. Fix may not be included in next release.type: feature request‘Nice-to-have’ improvement, new feature or different behavior or design.

Description

@radkomateusz
radkomateusz
opened on Mar 27, 2018
Issue body actions

Hello,

I would like to have ability to list all projects where BIgQuery is enabled and I (as a user or service account) have required permissions.
This functionality corresponds with biqquery.projects.list api call.

I have an use case, when I want to perform some actions on tables in all projects accessible for me.
Ability to create BIgQuery services for each accessible project would be great.

Activity

  1. yihanzhen
    added
    type: feature request‘Nice-to-have’ improvement, new feature or different behavior or design.
    api: bigqueryIssues related to the BigQuery API.
    priority: p2Moderately-important priority. Fix may not be included in next release.
    on Mar 29, 2018
  2. MMMarcy commented on May 16, 2018

    @MMMarcy
    MMMarcy
    on May 16, 2018
    More actions

    Having a go at this.

    I have a working implementation (see this commit) that follows the format of listDatasets.

    If you think it's valid, feel free to assign to me and I will finalize the Project class following the Dataset.java (and DatasetId, DatasetInfo) format and add tests.

  3. radkomateusz commented on Jun 1, 2018

    @radkomateusz
    radkomateusz
    on Jun 1, 2018
    Author
    More actions

    Hello, my apologies for the slow reply.

    For me it looks good, the usage mentioned in javadoc in your commit:
    Page<Project> projects = bigQuery.listProjects(); for (Project project: projects.iterateAll()) { // do something with the project }
    is exactly what I'm looking for.

  4. radkomateusz commented on Jun 1, 2018

    @radkomateusz
    radkomateusz
    on Jun 1, 2018
    Author
    More actions

    I'm just wondering:
    maybe it will be good to have possibility to list dataset also from project level:
    Project gcpProjectWithBQ = <project object>; Page<Dataset> datasets = gcpProjectWithBQ.list()
    next to current option biqQuery.listDatasets(projectId).

    It would be consistent with Dataset implementation which allows me to call Page<Table> tablePage = dataset.list()

  5. JustinBeckwith
    added
    🚨 criticalP0 critical issue. Requires immediate fix
    on Sep 23, 2018
  6. shollyman commented on Sep 26, 2018

    @shollyman
    shollyman
    on Sep 26, 2018
    Contributor
    More actions

    Consider using the resource manager API, as that's a better source of visible projects. bigquery.projects.list predates the existence of the resource manager API, and filters the project list based on caller membership in the effective project ACL.

    See https://github.com/GoogleCloudPlatform/google-cloud-java/tree/master/google-cloud-clients/google-cloud-resourcemanager for more specific information on the idiomatic client for resource manager.

  7. marcin-kolda commented on Sep 27, 2018

    @marcin-kolda
    marcin-kolda
    on Sep 27, 2018
    More actions

    Hi @shollyman,

    Resource Manager API works fine if you have resourcemanager.projects.list permission on a project. It won't work if you have permissions specified in dataset ACL (i.e. dataset primitive roles). In such case only biqquery.projects.list API will return such project.

  8. shollyman commented on Sep 27, 2018

    @shollyman
    shollyman
    on Sep 27, 2018
    Contributor
    More actions

    Hello @marcin-kolda!

    bigquery.projects.list currently uses the resourcemanager API as part of its internal implementation. Neither endpoint will return projects where the caller has no permissions at the project (or higher) level of the resource hierarchy. That permission doesn't need to be BQ-related, but there does need to be a permission or role assigned at the project level for the project to be included.

  9. marcin-kolda commented on Sep 27, 2018

    @marcin-kolda
    marcin-kolda
    on Sep 27, 2018
    More actions

    Yes, you're right @shollyman. I just tested it and bigquery.projects.list doesn't return projects in which you have only access to datasets. I'm pretty sure that it was working like that some time ago :)

  10. shollyman commented on Sep 27, 2018

    @shollyman
    shollyman
    on Sep 27, 2018
    Contributor
    More actions

    Improving resource discovery is a larger problem that's being worked on, but that's outside the scope of these project enumeration methods.

  11. shollyman commented on Sep 28, 2018

    @shollyman
    shollyman
    on Sep 28, 2018
    Contributor
    More actions

    Based on the discussion, closing this FR.

  12. shollyman
    closed this as completedon Sep 28, 2018
  13. JustinBeckwith
    assigned
    shollyman
    on Feb 1, 2021
  14. chingor13
    added a commit that references this issue on Feb 20, 2026

    chore(main): release 3.17.0 (#3087)

    1ec1c91
  15. lqiu96
    added a commit that references this issue on Mar 20, 2026

    chore(main): release 3.17.0 (#3087)

    9ebd024
  16. chingor13
    added 3 commits that reference this issue on Mar 24, 2026

    chore: Clarify testing guide in DEVELOPMENT.md (#3087)

    9bfd57d

    chore: wait for all spans to finish to fix flakiness in test (#3087)

    f9e0042

    deps: update sdk-platform-java dependencies (#3087)

    1c7ef3c
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

  • @shollyman
    shollyman

Labels

🚨 criticalP0 critical issue. Requires immediate fixapi: bigqueryIssues related to the BigQuery API.priority: p2Moderately-important priority. Fix may not be included in next release.type: feature request‘Nice-to-have’ improvement, new feature or different behavior or design.

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

    You are visitor 01402775 — GeezerVison does not store the pages you look up.
    Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.