I am encountering a connectivity issue while attempting to connect to Snowflake from my Azure Spring Apps application. The application fails to establish a connection, and the logs show the following exception stack trace:
java.sql.SQLException: Network error IOException: Connection refused: no further information HTTPSConnectionPool(host='balxxxx.xxxxxxx.snowflakecomputing.com', port=443): Max retries exceeded with url: /session/v1/login-request?request_id=s31d5e5a-62c8-4cfa-b97c-f78e6160f907&request_guid=1b427ccf-ed08-4184-ad2d-01c09d3ac441 (Caused by NewConnectionError('<snowflake.connector.vendored.urllib3.connection.HTTPSConnection object at 0x135b87910>: Failed to establish a new connection: [Errno 61] Connection refused'))
...
Caused by: java.net.ConnectException: Connection refused: no further information
I am using snowflake-jdbc version 3.14.4
I am stuck and not sure what exactly needs to be done in order to resolve this issue. is it because I am trying to connect across cloud providers from Azure to AWS?
I tried connecting it from my local but still getting the above error. I verified the public private keys, but it didn't help at all
The error seems to be quite clear. your app probably does not have connectivity to Snowflake db (assuming public/private key pair configuration is done correctly). I would suggest to review Network Configuration as following:
Also, your error seems very similar to one posted here : https://community.snowflake.com/s/article/Examples-of-Connectivity-Troubleshooting .try to follow the suggested steps and see if it helps.