Package org.apache.accumulo.core.client
Class AccumuloSecurityException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- org.apache.accumulo.core.client.AccumuloSecurityException
-
- All Implemented Interfaces:
Serializable
public class AccumuloSecurityException extends Exception
An Accumulo Exception for security violations, authentication failures, authorization failures, etc.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description AccumuloSecurityException(String user, SecurityErrorCode errorcode)
AccumuloSecurityException(String user, SecurityErrorCode errorcode, String tableInfo)
AccumuloSecurityException(String user, SecurityErrorCode errorcode, String tableInfo, Throwable cause)
AccumuloSecurityException(String user, SecurityErrorCode errorcode, Throwable cause)
AccumuloSecurityException(ThriftSecurityException thrift)
Construct a user-facing exception from a serialized version.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ThriftSecurityException
asThriftException()
String
getMessage()
SecurityErrorCode
getSecurityErrorCode()
String
getTableInfo()
String
getUser()
void
setTableInfo(String tableInfo)
void
setUser(String s)
-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
-
-
-
Constructor Detail
-
AccumuloSecurityException
public AccumuloSecurityException(ThriftSecurityException thrift)
Construct a user-facing exception from a serialized version.- Parameters:
thrift
- a serialized version
-
AccumuloSecurityException
public AccumuloSecurityException(String user, SecurityErrorCode errorcode, Throwable cause)
- Parameters:
user
- the relevant user for the security violationerrorcode
- the specific reason for this exceptioncause
- the exception that caused this violation
-
AccumuloSecurityException
public AccumuloSecurityException(String user, SecurityErrorCode errorcode, String tableInfo, Throwable cause)
- Parameters:
user
- the relevant user for the security violationerrorcode
- the specific reason for this exceptiontableInfo
- the relevant tableInfo for the security violationcause
- the exception that caused this violation
-
AccumuloSecurityException
public AccumuloSecurityException(String user, SecurityErrorCode errorcode)
- Parameters:
user
- the relevant user for the security violationerrorcode
- the specific reason for this exception
-
AccumuloSecurityException
public AccumuloSecurityException(String user, SecurityErrorCode errorcode, String tableInfo)
- Parameters:
user
- the relevant user for the security violationerrorcode
- the specific reason for this exceptiontableInfo
- the relevant tableInfo for the security violation
-
-
Method Detail
-
asThriftException
public ThriftSecurityException asThriftException()
- Returns:
- this exception as a thrift exception
-
getUser
public String getUser()
- Returns:
- the relevant user for the security violation
-
setUser
public void setUser(String s)
-
getTableInfo
public String getTableInfo()
- Returns:
- the relevant tableInfo for the security violation
-
setTableInfo
public void setTableInfo(String tableInfo)
-
getSecurityErrorCode
public SecurityErrorCode getSecurityErrorCode()
- Returns:
- the specific reason for this exception
- Since:
- 1.5.0
-
getMessage
public String getMessage()
- Overrides:
getMessage
in classThrowable
-
-