Hi @PRADEEPCHEEKATLA There was some issue with the apache spark pool I created. I had to delete and create a new one. That resolved the issue.
Error connecting to an api and fetch data
Raj D
616
Reputation points
Hi, I am running a notebook in Azure Synapse Analytics against an apache spark pool with pyspark code, where I am connecting to an api and view data in json. When I test this out in postman it works as expected. But when I run the notebook I get error.
Code:
import requests
user = 'name'
password = 'abc123'
response = requests.get('https:/webapi/getdata', auth=(user, password))
data = response.json()
print(data)
Error:
ConnectionError: HTTPSConnectionPool(host='', port=#): Max retries exceeded with url: (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7fe70e4690f0>: Failed to establish a new connection: [Errno 110] Connection timed out',))
Azure Synapse Analytics
Azure Synapse Analytics
An Azure analytics service that brings together data integration, enterprise data warehousing, and big data analytics. Previously known as Azure SQL Data Warehouse.
5,373 questions