Source
Configuring the JDBC Driver
Using the JDBC driver to connect to Snowflake requires a connection string with the syntax described below. You can generate the basic connection string in Snowsight.
Exception 'java.net.UnknownHostException' when connecting to scoped stage file URLs within Snowpark Java functions
CAUSE: Snowpark (Java, Scala, Python, etc.) functions execute in secure sandboxes over the Snowflake virtual warehouses and are not permitted to make any network related syscalls, including DNS resolution.