Package net.snowflake.client.config
Class SFClientConfigParser
- java.lang.Object
-
- net.snowflake.client.config.SFClientConfigParser
-
public class SFClientConfigParser extends Object
-
-
Field Summary
Fields Modifier and Type Field Description static String
SF_CLIENT_CONFIG_ENV_NAME
static String
SF_CLIENT_CONFIG_FILE_NAME
-
Constructor Summary
Constructors Constructor Description SFClientConfigParser()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static String
getConfigFilePathFromJDBCJarLocation()
static SFClientConfig
loadSFClientConfig(String configFilePath)
Construct SFClientConfig from client config file passed by user.
-
-
-
Field Detail
-
SF_CLIENT_CONFIG_FILE_NAME
public static final String SF_CLIENT_CONFIG_FILE_NAME
- See Also:
- Constant Field Values
-
SF_CLIENT_CONFIG_ENV_NAME
public static final String SF_CLIENT_CONFIG_ENV_NAME
- See Also:
- Constant Field Values
-
-
Method Detail
-
loadSFClientConfig
public static SFClientConfig loadSFClientConfig(String configFilePath) throws IOException
Construct SFClientConfig from client config file passed by user. This method searches the config file in following order: 1. configFilePath param which is read from connection URL or connection property. 2. Environment variable: SF_CLIENT_CONFIG_FILE containing full path to sf_client_config file. 3. Searches for default config file name(sf_client_config.json under the driver directory from where the driver gets loaded. 4. Searches for default config file name(sf_client_config.json) under user home directory 5. Searches for default config file name(sf_client_config.json) under tmp directory.- Parameters:
configFilePath
- SF_CLIENT_CONFIG_FILE parameter read from connection URL or connection properties- Returns:
- SFClientConfig
- Throws:
IOException
-
getConfigFilePathFromJDBCJarLocation
public static String getConfigFilePathFromJDBCJarLocation()
-
-