Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expose remote functions options as first class properties #1552

Closed
shobsi opened this issue Apr 17, 2023 · 3 comments
Closed

Expose remote functions options as first class properties #1552

shobsi opened this issue Apr 17, 2023 · 3 comments
Assignees
Labels
api: bigquery Issues related to the googleapis/python-bigquery API. type: feature request ‘Nice-to-have’ improvement, new feature or different behavior or design.

Comments

@shobsi
Copy link
Contributor

shobsi commented Apr 17, 2023

Right now if I want to access spec details for a bigquery remote function I have to use the hidden properties, e.g.

        routines = bq_client.list_routines(f"{gcp_project_id}.{bq_dataset}")
        for routine in routines:
            rf_options = routine._properties.get("remoteFunctionOptions")
            if rf_options:
                http_endpoint = rf_options.get("endpoint")
                bq_connection = rf_options.get("connection")

which is not ideal and takes a bit of figuring out. It would be nice to have it exposed via first class properties, which can be used like

        routines = bq_client.list_routines(f"{gcp_project_id}.{bq_dataset}")
        for routine in routines:
            rf_options = routine.remote_function_options
            if rf_options:
                http_endpoint = rf_options.endpoint
                bq_connection = rf_options.connection
@product-auto-label product-auto-label bot added the api: bigquery Issues related to the googleapis/python-bigquery API. label Apr 17, 2023
@tswast tswast added the type: feature request ‘Nice-to-have’ improvement, new feature or different behavior or design. label Apr 19, 2023
@tswast tswast changed the title Expose remote functions as first class properties Expose remote functions options as first class properties Apr 19, 2023
@tswast
Copy link
Contributor

tswast commented Aug 16, 2023

This could be a really good starter project for my apprentices.

@tswast
Copy link
Contributor

tswast commented Aug 16, 2023

@tswast tswast self-assigned this Aug 16, 2023
@shollyman
Copy link
Contributor

This was added as part of #1558 but the work was tracked on an internal issue. Closing this external issue, apologies for missing it initially.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: bigquery Issues related to the googleapis/python-bigquery API. type: feature request ‘Nice-to-have’ improvement, new feature or different behavior or design.
Projects
None yet
Development

No branches or pull requests

3 participants