Package com.atlassian.bamboo.logger
Class ErrorDetailsImpl
java.lang.Object
com.atlassian.bamboo.logger.ErrorDetailsImpl
- All Implemented Interfaces:
ErrorDetails
- Direct Known Subclasses:
ElasticErrorDetailsImpl
Stores all the error details for many different sorts of errors. (i.e don't assume specific attributes will exists)
-
Field Summary
-
Constructor Summary
ConstructorDescriptionErrorDetailsImpl
(int errorNumber, String planKey, Integer resultNumber, @Nullable Long agentId, String context, @Nullable Date timeStamp, @Nullable ThrowableDetails throwableDetails) ErrorDetailsImpl
(int errorNumber, String planKey, Long resultNumber, @Nullable Long agentId, String context, @Nullable Date timeStamp, @Nullable ThrowableDetails throwableDetails) -
Method Summary
Modifier and TypeMethodDescriptionDeprecated.since 5.5Deprecated.since 5.5Deprecated.since 5.5Top level message related to error@Nullable Key
Get entity key associated with this errorint
@NotNull Date
@NotNull Date
int
@Nullable ResultKey
Get result key associated with this error@Nullable Integer
@Nullable Long
@Nullable ThrowableDetails
Contains the details of anyThrowable
which may have been thrown in the errorboolean
Is this error specific to one plan (true) or for all/any plans (false) e.g.boolean
Is this error specific to Elastic Bamboo
-
Field Details
-
ALL_BUILDS
- See Also:
-
-
Constructor Details
-
ErrorDetailsImpl
-
ErrorDetailsImpl
-
-
Method Details
-
getErrorNumber
public int getErrorNumber()- Specified by:
getErrorNumber
in interfaceErrorDetails
-
getBuildKey
Deprecated.since 5.5Full key for the build plan (e.g BAMBOO-TRUNK)- Specified by:
getBuildKey
in interfaceErrorDetails
- Returns:
- build key
-
getEntityKey
Description copied from interface:ErrorDetails
Get entity key associated with this error- Specified by:
getEntityKey
in interfaceErrorDetails
- Returns:
- entity key
-
getBuildResultKey
Deprecated.since 5.5Full key for the build result (e.g BAMBOO-TRUNK-4)- Specified by:
getBuildResultKey
in interfaceErrorDetails
- Returns:
- build result key
-
getResultKey
Description copied from interface:ErrorDetails
Get result key associated with this error- Specified by:
getResultKey
in interfaceErrorDetails
- Returns:
- result key
-
getAgentIds
- Specified by:
getAgentIds
in interfaceErrorDetails
-
getBuildNumber
Deprecated.since 5.5- Specified by:
getBuildNumber
in interfaceErrorDetails
-
getResultNumber
- Specified by:
getResultNumber
in interfaceErrorDetails
- Returns:
- associated result number or null
-
getResultNumberLong
- Specified by:
getResultNumberLong
in interfaceErrorDetails
- Returns:
- associated result number or null
-
getContext
Description copied from interface:ErrorDetails
Top level message related to error- Specified by:
getContext
in interfaceErrorDetails
-
getLastOccurred
- Specified by:
getLastOccurred
in interfaceErrorDetails
- Returns:
- Date this error was last thrown (if it only occurred once it will be the same as
ErrorDetails.getFirstOccurred()
)
-
getFirstOccurred
- Specified by:
getFirstOccurred
in interfaceErrorDetails
- Returns:
- Date this error was first thrown
-
getNumberOfOccurrences
public int getNumberOfOccurrences()- Specified by:
getNumberOfOccurrences
in interfaceErrorDetails
- Returns:
- Number of times this error has occurred
-
getThrowableDetails
Contains the details of anyThrowable
which may have been thrown in the error- Specified by:
getThrowableDetails
in interfaceErrorDetails
- Returns:
- details of any
Throwable
for this error
-
isBuildSpecific
public boolean isBuildSpecific()Description copied from interface:ErrorDetails
Is this error specific to one plan (true) or for all/any plans (false) e.g. a system error or elastic error.- Specified by:
isBuildSpecific
in interfaceErrorDetails
- Returns:
- true if error contains a build key.
-
isElastic
public boolean isElastic()Is this error specific to Elastic Bamboo- Returns:
- true if error is for elastic bamboo, otherwise false.
-