token = "xxxx"
http = urllib3.PoolManager(cert_reqs='CERT_NONE')
url = "https://xxxx"
data = {
"x": x,
"x": {
"x": xx,
"y": yyy,
},
}
encoded_data = json.dumps(data).encode('utf-8')
headers = {
"Authorization": f"Bearer {token}",
"Content-Type": "application/json" }
response = http.request(
method="POST",
url=url,
body=encoded_data,
headers=headers,
redirect=False,
timeout=30)
ERROR: Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ConnectTimeoutError(<urllib3.connection.HTTPSConnection object at 0x7ff193235250>, 'Connection to energyaustralia-edw-dev.cloud.databricks.com timed out. (connect timeout=30)')': /api/2.1/jobs/run-now
THEN IT TIMES OUT WITH THIS LOG : 2023-11-28T09:42:05.149Z cf8c889b-2e3d-4788-998f-e15fc6d895a3 Task timed out after 120.10 seconds
expected to get the 200 response. It is not able to connect to the server