Package net.snowflake.client.jdbc
Class SnowflakeSQLException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.sql.SQLException
-
- net.snowflake.client.jdbc.SnowflakeSQLException
-
- All Implemented Interfaces:
Serializable
,Iterable<Throwable>
- Direct Known Subclasses:
SnowflakeReauthenticationRequest
,SnowflakeSQLLoggedException
public class SnowflakeSQLException extends SQLException
- Author:
- jhuang
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description SnowflakeSQLException(String reason)
SnowflakeSQLException(String sqlState, int vendorCode)
SnowflakeSQLException(String sqlState, int vendorCode, Object... params)
SnowflakeSQLException(String reason, String SQLState)
SnowflakeSQLException(String queryId, String reason, String sqlState, int vendorCode)
This constructor should only be used for error from Global service.SnowflakeSQLException(Throwable ex, String sqlState, int vendorCode)
SnowflakeSQLException(Throwable ex, String sqlState, int vendorCode, Object... params)
SnowflakeSQLException(Throwable ex, ErrorCode errorCode, Object... params)
SnowflakeSQLException(SFException e)
SnowflakeSQLException(ErrorCode errorCode, int retryCount, boolean issocketTimeoutNoBackoff, long elapsedSeconds)
SnowflakeSQLException(ErrorCode errorCode, Object... params)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description long
getElapsedSeconds()
String
getQueryId()
int
getRetryCount()
boolean
issocketTimeoutNoBackoff()
-
Methods inherited from class java.sql.SQLException
getErrorCode, getNextException, getSQLState, iterator, setNextException
-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
-
-
-
Constructor Detail
-
SnowflakeSQLException
public SnowflakeSQLException(String queryId, String reason, String sqlState, int vendorCode)
This constructor should only be used for error from Global service. Since Global service has already built the error message, we use it as is. For any errors local to JDBC driver, we should use one of the constructors below to build the error message.- Parameters:
queryId
- query idreason
- reason for which exception is createdsqlState
- sql statevendorCode
- vendor code
-
SnowflakeSQLException
public SnowflakeSQLException(String sqlState, int vendorCode)
-
SnowflakeSQLException
public SnowflakeSQLException(String sqlState, int vendorCode, Object... params)
-
SnowflakeSQLException
public SnowflakeSQLException(Throwable ex, ErrorCode errorCode, Object... params)
-
SnowflakeSQLException
public SnowflakeSQLException(Throwable ex, String sqlState, int vendorCode, Object... params)
-
SnowflakeSQLException
public SnowflakeSQLException(ErrorCode errorCode, int retryCount, boolean issocketTimeoutNoBackoff, long elapsedSeconds)
-
SnowflakeSQLException
public SnowflakeSQLException(SFException e)
-
SnowflakeSQLException
public SnowflakeSQLException(String reason)
-
-
Method Detail
-
getQueryId
public String getQueryId()
-
getRetryCount
public int getRetryCount()
-
issocketTimeoutNoBackoff
public boolean issocketTimeoutNoBackoff()
-
getElapsedSeconds
public long getElapsedSeconds()
-
-