flvndh opened a new issue #14677:
URL: https://github.com/apache/airflow/issues/14677


   The following input parameter types should be adapted in 
`AzureDataFactoryHook` 
([source](https://github.com/apache/airflow/blob/e97d501a0bcfc7e808171fec8c44bb7a4292a9f9/airflow/providers/microsoft/azure/hooks/azure_data_factory.py)):
   |current|target|
   |-|-|
   |Dataset|DatasetResource|
   |LinkedService|LinkedServiceResource|
   |Trigger|TriggerResource|
   
   ## Example
   The following signature should be changed from this:
   ```python
       @provide_targeted_factory
       def update_linked_service(
           self,
           linked_service_name: str,
           linked_service: LinkedService,
           resource_group_name: Optional[str] = None,
           factory_name: Optional[str] = None,
           **config: Any,
       ) -> LinkedServiceResource:
   ```
   
   To this:
   ```python
       @provide_targeted_factory
       def update_linked_service(
           self,
           linked_service_name: str,
           linked_service: LinkedServiceResource,
           resource_group_name: Optional[str] = None,
           factory_name: Optional[str] = None,
           **config: Any,
       ) -> LinkedServiceResource:
   ```
   
   ## Reason
   
   `Dataset`, `LinkedService` and `Trigger` are properties classes that should 
be provided to their corresponding `Resource` type.
   
   ```python
   properties = AzureBlobFSLinkedService(url=adls_url, account_key=adls_key)
   linked_service = LinkedServiceResource(properties=properties)
   hook.create_linked_service("ADLS", linked_service)
   ```


----------------------------------------------------------------
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.

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


Reply via email to