server-client-python icon indicating copy to clipboard operation
server-client-python copied to clipboard

Set FILESIZE_LIMIT_MB via environment variables

Open Der-Henning opened this issue 1 year ago • 2 comments

In one of my current projects I have to upload datasources to a tableau server behind a reverse proxy that only allows a maximum file size of 30MB. Due to different reasons it is not possible to change this limit.

In this PR I suggest to extend the existing Config class to provide the FILESIZE_LIMIT_MB variable via an optional environment variable. The default value stays at 64MB.

Der-Henning avatar Sep 18 '24 13:09 Der-Henning

Thanks for the contribution! Before we can merge this, we need @Der-Henning to sign the Salesforce Inc. Contributor License Agreement.

salesforce-cla[bot] avatar Sep 18 '24 13:09 salesforce-cla[bot]

Looks ok overall. I think as well as/instead of just setting the default value to 64, you could return the smaller of the two values, so people don't try putting in a larger value and hit server errors.

jacalata avatar Sep 20 '24 07:09 jacalata