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

[DatasourceItem] use_remote_query_agent settable on publish #1401

Closed
MSGMax opened this issue Jun 19, 2024 · 4 comments
Closed

[DatasourceItem] use_remote_query_agent settable on publish #1401

MSGMax opened this issue Jun 19, 2024 · 4 comments
Labels
enhancement needs investigation Issue needs to be looked at by Tableau

Comments

@MSGMax
Copy link

MSGMax commented Jun 19, 2024

Summary

Can we have DatasourceItem attribute use_remote_query_agent settable (True/False), so we can publish Datasources that are capable of connecting to Private Networks (use Tableau Bridge)?

Request Type

Currently this attribute cannot be set when DatasourceItem object is created.

Type 1: support a REST API:
This functionality is supported by REST API
https://help.tableau.com/current/api/rest_api/en-us/REST/rest_api_ref_data_sources.htm#update_data_source

Type 2: add a REST API and support it in tsc.
N/A

Type 3: new functionality
N/A

Description

Enable setting use_remote_query_agent (True/False) when DatasourceItem item is being created

@MSGMax MSGMax added enhancement needs investigation Issue needs to be looked at by Tableau labels Jun 19, 2024
@jorwoods
Copy link
Contributor

It looks like use_remote_query_agent is already an attribute on DatasourceItems, and included as part of the XML request during publish, though not included as part of update requests. Does this existing functionality meet your need?

if datasource_item.use_remote_query_agent is not None:
datasource_element.attrib["useRemoteQueryAgent"] = str(datasource_item.use_remote_query_agent).lower()

@MSGMax
Copy link
Author

MSGMax commented Jun 20, 2024

Hi jorwoods,

Thanks for looking into it.
I have a problem with initialising DatasourceItem before I can even publish it as per below code:
datasource_item = tsc.DatasourceItem(project_id='hh881338-4a4c-4365-837t-abc7aa1c69e6', name='test', use_remote_query_agent=True)

above throws the following error:
DatasourceItem.init() got an unexpected keyword argument 'use_remote_query_agent'.

Can you give me an example of a code that would allow me to publish a new data source with use_remote_query_agent set to true (default is false)?

Thanks,
M

@jorwoods
Copy link
Contributor

datasource_item = tsc.DatasourceItem(project_id='hh881338-4a4c-4365-837t-abc7aa1c69e6',  name='test')
datasource_item.use_remote_query_agent=True

@MSGMax
Copy link
Author

MSGMax commented Jun 24, 2024

Works perfectly. Case closed.
Thank you very much.

@MSGMax MSGMax closed this as completed Jun 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement needs investigation Issue needs to be looked at by Tableau
Projects
None yet
Development

No branches or pull requests

2 participants