TableauSDK proxy settings
Asked Answered
A

1

7

We are using TableauSDK (Java) to publish extract into Tableau Server.

Our connection to Tableau server is via proxy. So we just set the java system properties https.proxyHost, https.proxyPort, http.proxyHost and http.proxyPort.

But it seems the proxy settings done in above java system properties does not take effect. Please help us to configure proxy settings in TableauSDK (Java)

Allison answered 19/9, 2016 at 5:19 Comment(1)
any follow up? I also need to know because i have the same issue.Lindie
T
2

The Tableau SDK uses a native library under the hood, which integrates with the Java SDK using JNI.

The native library respects the standard environment variables for proxy configuration, http_proxy and https_proxy. On a Linux, or Mac system, you can simply export these environment variables:

export http_proxy="http://my.proxy.server:3128"
export https_proxy="http://my.proxy.server:3128"
java -jar my-application.jar

If you use a proxy server which requires authentication, the SDK exposes a method to set the username and password:

ServerAPI.initialize();
ServerConnection serverConnection = new ServerConnection();
serverConnection.setProxyCredentials("user", "pass");
serverConnection.connect("https://tableau.url", "user", "password", "siteName");
serverConnection.publish("/path/to/extract", "projectName", "dataSourceName", true); // Overwrite Existing

I suspect this works pretty similarly using the Python SDK.

Trudietrudnak answered 14/5, 2018 at 0:14 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.