Which use case is this pull request trying to solve
We are operating in an environment where we need to explicitly put Salesforce IPs into an allow-list to be able to connect. We are pushed to limit the number of IPs that we are requesting. For us it would hence be helpful to narrow down the number of IPs that we need to connect to. For this we would like more control over which Salesforce endpoint is used by the Salesforce input plugin for authentication and for further API requests. The latter would usually go to the instance url which is returned by the login request. The login request would always go to either login.salesforce.com or test.salesforce.com (depending on the value of the use_test_sandbox setting).
What does this pull request do
This pull request introduces a new configuration setting of the Salesforce input plugin which allows to provide the Salesforce instance url to connect to (already) for authentication and further API requests. The configuration parameter is named sfdc_instance_url and takes a string value of the form <mydomain>.my.salesforce.com, e.g. the hostname part of the instance url without protocol or path.
If a sfdc_instance_url is given, it takes precedence over the use_test_sandbox setting and controls the endpoint to which the login request is sent.
If sfdc_instance_url is not set, then the use_test_sandbox setting will control which endpoint is used.
Which use case is this pull request trying to solve
We are operating in an environment where we need to explicitly put Salesforce IPs into an allow-list to be able to connect. We are pushed to limit the number of IPs that we are requesting. For us it would hence be helpful to narrow down the number of IPs that we need to connect to. For this we would like more control over which Salesforce endpoint is used by the Salesforce input plugin for authentication and for further API requests. The latter would usually go to the instance url which is returned by the login request. The login request would always go to either login.salesforce.com or test.salesforce.com (depending on the value of the
use_test_sandbox
setting).What does this pull request do
This pull request introduces a new configuration setting of the Salesforce input plugin which allows to provide the Salesforce instance url to connect to (already) for authentication and further API requests. The configuration parameter is named
sfdc_instance_url
and takes a string value of the form<mydomain>.my.salesforce.com
, e.g. the hostname part of the instance url without protocol or path. If asfdc_instance_url
is given, it takes precedence over theuse_test_sandbox
setting and controls the endpoint to which the login request is sent. Ifsfdc_instance_url
is not set, then theuse_test_sandbox
setting will control which endpoint is used.