Package com.avoka.fc.core.dao
Class ErrorLogDao
java.lang.Object
com.avoka.core.dao.BaseDao
com.avoka.fc.core.dao.AbstractDao
com.avoka.fc.core.dao.ErrorLogDao
Provides a DAO for the ErrorLog entity.
- See Also:
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
The 'Equal' filter operator..static final String
The 'Like' filter operator.static final String
The 'Not Equal' filter operator.static final String
The 'Not Like' filter operator..static final String[]
The filter operators.Fields inherited from class com.avoka.core.dao.BaseDao
FETCH_LIMIT, STATEMENT_MAX_NO_PARAMETERS
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionReturn the error log record with the specified OIDgetErrorLogList
(String clientId, String errorId, String submissionId, String portalId, String name, String messageFilter, String message, Date startDate, Date endDate) Deprecated.getErrorLogList
(String clientId, String errorId, String submissionId, String portalId, String name, String messageFilter, String message, Date startDate, Date endDate, String errorType, boolean criticalError, boolean groovyError, String serverNodeId, int offset, int pageSize) Return the list of error log records matching the specified search criteria.getErrorLogTrendData
(String errorType, Object portalId, boolean criticalError, boolean groovyError, Date startDate, Date endDate) Return error log trend data for time period and criteria.getJobActionErrors
(Object jobActionId) Return the list of error log entries associated with a submission (note: the query uses the generic fetch limit and is thus used in lieu of submission.getErrors() for performance reasons)getSubmissionErrors
(Object submissionId) Return the list of error log entries associated with a submission (note: the query uses the generic fetch limit and is thus used in lieu of submission.getErrors() for performance reasons)int
purgeErrorLog
(int maxAgeDays, int fetchLimit, long maxTimeMs) Delete error log records older than a specified number of daysMethods inherited from class com.avoka.fc.core.dao.AbstractDao
andFilterClientExcludeNull, andFilterClientIncludeNull, andFilterClientOnly, isClientAccessAllowed, performQueryConfigCached
Methods inherited from class com.avoka.core.dao.BaseDao
addOrdering, addOrderingCaseInsensitive, addOrderingCaseSensitive, andQueryBetween, andQueryInExp, andQueryInExp, andQueryLikeIgnoreCaseExp, andQueryMatchDbExp, andQueryMatchExp, andQueryMatchIsNotNull, andQueryMatchIsNull, andQueryNoMatchExp, andQueryNotTrue, deleteObject, deleteObjects, findObject, getDataContext, getFetchLimit, getLogger, getObjectForPK, newObject, orQueryLikeIgnoreCaseExp, orQueryMatchExp, performNamedQuery, performNamedQuery, performNamedQuery, performNamedQuery, performNonSelectingQuery, performNonSelectingQuery, performNonSelectingQuery, performNonSelectingQuery, performQuery, performQuery, performQuery, registerNewObject, setCacheStrategy, setFetchLimit, setLocalCacheStrategy, setLocalCacheStrategy, setSharedCacheStrategy, toMap, toMap
-
Field Details
-
FILTER_LIKE
The 'Like' filter operator.- See Also:
-
FILTER_NOT_LIKE
The 'Not Like' filter operator..- See Also:
-
FILTER_EQUAL
The 'Equal' filter operator..- See Also:
-
FILTER_NOT_EQUAL
The 'Not Equal' filter operator.- See Also:
-
MESSAGE_FILTER_OPERATORS
The filter operators.
-
-
Constructor Details
-
ErrorLogDao
public ErrorLogDao()
-
-
Method Details
-
getErrorLogForId
Return the error log record with the specified OID- Parameters:
id
- the OID- Returns:
- the matching error log record, or null if not found
-
getErrorLogList
public Iterable<Map> getErrorLogList(String clientId, String errorId, String submissionId, String portalId, String name, String messageFilter, String message, Date startDate, Date endDate) Deprecated.Return the list of error log records matching the specified search criteria.- Parameters:
clientId
- the OID of the client associated with the error log entry (optional)errorId
- the error log OID (optional)submissionId
- the OID of the submission associated with the error log entry (optional)portalId
- the OID of the associated portal (optional)name
- the error log name (optional)messageFilter
- the message filtermessage
- a substring of the error message (optional)startDate
- the lower bound on the error time (optional)endDate
- the upper bound on the error time (optional)- Returns:
- the list of matching error log records
-
getErrorLogList
public List<ErrorLog> getErrorLogList(String clientId, String errorId, String submissionId, String portalId, String name, String messageFilter, String message, Date startDate, Date endDate, String errorType, boolean criticalError, boolean groovyError, String serverNodeId, int offset, int pageSize) Return the list of error log records matching the specified search criteria.- Parameters:
clientId
- the OID of the client associated with the error log entry (optional)errorId
- the error log OID (optional)submissionId
- the OID of the submission associated with the error log entry (optional)portalId
- the OID of the associated portal (optional)name
- the error log name (optional)messageFilter
- the message filtermessage
- a substring of the error message (optional)startDate
- the lower bound on the error time (optional)endDate
- the upper bound on the error time (optional)errorType
- the type of error (optional)criticalError
- specify whether a critical errorgroovyError
- specify whether a groovy script errorserverNodeId
- the server node ID (optional)offset
- the offset to be used in the querypageSize
- the number of items to be returned- Returns:
- the list of matching error log records
- Since:
- 4.3.4
-
purgeErrorLog
public int purgeErrorLog(int maxAgeDays, int fetchLimit, long maxTimeMs) Delete error log records older than a specified number of days- Parameters:
maxAgeDays
- The age in days above which records will be deleted. If this value is negative or equal to 0, no records will be purged.fetchLimit
- the maximum number of records to delete (only used if > 0)- Returns:
- the number of records that were deleted
-
getSubmissionErrors
Return the list of error log entries associated with a submission (note: the query uses the generic fetch limit and is thus used in lieu of submission.getErrors() for performance reasons)- Parameters:
submissionId
- the OID of a valid submission- Returns:
- the list of error log entries for the submission
-
getJobActionErrors
Return the list of error log entries associated with a submission (note: the query uses the generic fetch limit and is thus used in lieu of submission.getErrors() for performance reasons)- Parameters:
jobActionId
- the OID of a valid submission- Returns:
- the list of error log entries for the submission
-
getErrorLogTrendData
public List<Pair<Date,Integer>> getErrorLogTrendData(String errorType, Object portalId, boolean criticalError, boolean groovyError, Date startDate, Date endDate) Return error log trend data for time period and criteria.- Parameters:
errorType
- the error type (optional)portalId
- the OID of the portal to filter on (optional)criticalError
- is a critical errorgroovyError
- is a groovy errorstartDate
- the start date/time (required)endDate
- the end date/time (required)- Returns:
- trend data for the selected period
- Since:
- 4.3.4
-