You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by GitBox <gi...@apache.org> on 2021/08/03 19:54:56 UTC

[GitHub] [airflow] josh-fell opened a new pull request #17399: Adding JWT, IP filtering, and direct session login support for SalesforceHook

josh-fell opened a new pull request #17399:
URL: https://github.com/apache/airflow/pull/17399


   Closes: #17192
   
   - Adding login and authentication support when using the `SalesforceHook`:
     - JWT bearer authentication
     - IP filtering (allow-listing)
     - Direct session/instance access
   
   - New fields were also added to the connection form for the "Salesforce" type:
     ![image](https://user-images.githubusercontent.com/48934154/128040196-299a2726-db55-4c5f-96fb-b82123c71d8c.png)
   
   - Connection documentation has also been updated to describe each connection field and what type of login/authentication is related.
   
   - Refactored unit tests to include mock implementations of the 4 supported auth/login types.
   
   ---
   **^ Add meaningful description above**
   
   Read the **[Pull Request Guidelines](https://github.com/apache/airflow/blob/main/CONTRIBUTING.rst#pull-request-guidelines)** for more information.
   In case of fundamental code change, Airflow Improvement Proposal ([AIP](https://cwiki.apache.org/confluence/display/AIRFLOW/Airflow+Improvements+Proposals)) is needed.
   In case of a new dependency, check compliance with the [ASF 3rd Party License Policy](https://www.apache.org/legal/resolved.html#category-x).
   In case of backwards incompatible changes please leave a note in [UPDATING.md](https://github.com/apache/airflow/blob/main/UPDATING.md).
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] github-actions[bot] commented on pull request #17399: Adding JWT, IP filtering, and direct session login support for SalesforceHook

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on pull request #17399:
URL: https://github.com/apache/airflow/pull/17399#issuecomment-892589165


   The PR is likely OK to be merged with just subset of tests for default Python and Database versions without running the full matrix of tests, because it does not modify the core of Airflow. If the committers decide that the full tests matrix is needed, they will add the label 'full tests needed'. Then you should rebase to the latest main or amend the last commit of the PR, and push it with --force-with-lease.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] kurtqq commented on a change in pull request #17399: Adding JWT, IP filtering, and direct session login support for SalesforceHook

Posted by GitBox <gi...@apache.org>.
kurtqq commented on a change in pull request #17399:
URL: https://github.com/apache/airflow/pull/17399#discussion_r682077772



##########
File path: airflow/providers/salesforce/hooks/salesforce.py
##########
@@ -74,6 +91,29 @@ def get_connection_form_widgets() -> Dict[str, Any]:
                 lazy_gettext("Security Token"), widget=BS3PasswordFieldWidget()
             ),
             "extra__salesforce__domain": StringField(lazy_gettext("Domain"), widget=BS3TextFieldWidget()),
+            "extra__salesforce__consumer_key": StringField(
+                lazy_gettext("Consumer Key"), widget=BS3TextFieldWidget()
+            ),
+            "extra__salesforce__private_key_file_path": PasswordField(
+                lazy_gettext("Private Key File Path"), widget=BS3PasswordFieldWidget()
+            ),
+            "extra__salesforce__private_key": PasswordField(
+                lazy_gettext("Private Key"), widget=BS3PasswordFieldWidget()
+            ),
+            "extra__salesforce__organization_id": StringField(
+                lazy_gettext("Organization ID"), widget=BS3TextFieldWidget()
+            ),
+            "extra__salesforce__instance": StringField(lazy_gettext("Instance"), widget=BS3TextFieldWidget()),
+            "extra__salesforce__instance_url": StringField(
+                lazy_gettext("Instance URL"), widget=BS3TextFieldWidget()
+            ),
+            "extra__salesforce__proxies": StringField(lazy_gettext("Proxies"), widget=BS3TextFieldWidget()),
+            "extra__salesforce__version": StringField(
+                lazy_gettext("Salesforce API Version"), widget=BS3TextFieldWidget()

Review comment:
       ```suggestion
                   lazy_gettext("API Version"), widget=BS3TextFieldWidget()
   ```
   This is salesforce connection, just calling it api version is enough i believe




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] josh-fell commented on pull request #17399: Adding JWT, IP filtering, and direct session login support for SalesforceHook

Posted by GitBox <gi...@apache.org>.
josh-fell commented on pull request #17399:
URL: https://github.com/apache/airflow/pull/17399#issuecomment-892325412


   @eladkal FYI if you'd like to review.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] github-actions[bot] commented on pull request #17399: Adding JWT, IP filtering, and direct session login support for SalesforceHook

Posted by GitBox <gi...@apache.org>.
github-actions[bot] commented on pull request #17399:
URL: https://github.com/apache/airflow/pull/17399#issuecomment-892589165


   The PR is likely OK to be merged with just subset of tests for default Python and Database versions without running the full matrix of tests, because it does not modify the core of Airflow. If the committers decide that the full tests matrix is needed, they will add the label 'full tests needed'. Then you should rebase to the latest main or amend the last commit of the PR, and push it with --force-with-lease.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] eladkal merged pull request #17399: Adding JWT, IP filtering, and direct session login support for SalesforceHook

Posted by GitBox <gi...@apache.org>.
eladkal merged pull request #17399:
URL: https://github.com/apache/airflow/pull/17399


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org