Package org.cyclos.impl.messaging
Class ErrorLogServiceImpl
- java.lang.Object
-
- org.cyclos.impl.AbstractServerComponent
-
- org.cyclos.impl.AbstractNetworkedServerComponent
-
- org.cyclos.impl.BaseServiceImpl
-
- org.cyclos.impl.messaging.ErrorLogServiceImpl
-
- All Implemented Interfaces:
ApplicationUpgradeInitializationListener,BaseApplicationInitializationListener,ErrorLogServiceLocal,ErrorLogService,Service
@Service public class ErrorLogServiceImpl extends BaseServiceImpl implements ErrorLogServiceLocal, ApplicationUpgradeInitializationListener
-
-
Field Summary
-
Fields inherited from class org.cyclos.impl.AbstractNetworkedServerComponent
authHandler, conversionHandler, customFieldValueHandler, entityManagerHandler, groupsHandler, productsHandler, restBeanPropertyMapping, userLocatorHandler
-
Fields inherited from class org.cyclos.impl.AbstractServerComponent
accountHandler, configurationHandler, dataTranslationHandler, notificationHandler, profileFieldHandler, transactionHandler, translationHandler
-
Fields inherited from interface org.cyclos.impl.BaseApplicationInitializationListener
MAX_PRIORITY, MIN_PRIORITY, NORMAL_PRIORITY
-
-
Constructor Summary
Constructors Constructor Description ErrorLogServiceImpl()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description IntegercountErrors(Date since)Counts the application errors since the given time.Longcreate(String methodName, String paremetersAsJson, String stackTrace, Channel channel, BasicUser user)Create new error log entrylongdeleteOldErrorLogs()Deletes the old error logs according to the global configuration parametersErrorLogSearchDatagetSearchData()Searches the error log historyErrorLogDetailedVOload(Long id)Loads an entry by idvoidonApplicationUpgradeInitialization()Invoked when the application service is initializedprotected voidregisterNetworkMappings(NetworkPathRegistry networkPathRegistry)Needs to be overridden by subclasses to register the path up to the networkvoidremove(Long id)Removes a single entryvoidremoveAll(Set<Long> ids)Removes all the given entriesPage<ErrorLogVO>search(ErrorLogQuery params)Searches the error log history-
Methods inherited from class org.cyclos.impl.BaseServiceImpl
initializeNetworkMappings
-
Methods inherited from class org.cyclos.impl.AbstractNetworkedServerComponent
canManage, checkManagesUser, checkPermission, checkRelatesToUser, checkValue, clearAlreadyValidated, getBaseEntityManagerHandler, getConfiguration, getLoggedBasicUser, getLoggedUser, getProducts, getTranslatedName, getTranslatedValue, hasPermission, hasValue, inSameNetwork, inSameNetworkOrGlobal, isAdmin, isAlreadyValidated, isBroker, isGlobalAdmin, isGlobalAdminInNetwork, isGuest, isLoggedIn, isMember, isMemberOnly, isNetworkAdmin, isOperator, isRelatedToUser, isSystem, isUserManager, isUserManagerOf, message, message, permission, permission, permissionOptionalValue, permissionOptionalValue, setAlreadyValidated, toDate, toDateTime, validate
-
Methods inherited from class org.cyclos.impl.AbstractServerComponent
dataTranslationProxy, dataTranslationProxy, delete, detach, doDataTranslationProxy, find, flush, from, getApplicationContext, getFormatter, getFormatter, getFormatter, getLogger, getRemoteAddress, getSessionData, mailContentBuilder, message, message, persist, processBatch, processBatch, refresh, remove, selectFrom, subQuery, update
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.cyclos.impl.BaseApplicationInitializationListener
applicationInitializationPriority, getInitializationId
-
-
-
-
Method Detail
-
countErrors
public Integer countErrors(Date since)
Description copied from interface:ErrorLogServiceLocalCounts the application errors since the given time. If time is null, counts all errors. Only non-removed errors are counted.- Specified by:
countErrorsin interfaceErrorLogServiceLocal
-
create
public Long create(String methodName, String paremetersAsJson, String stackTrace, Channel channel, BasicUser user)
Description copied from interface:ErrorLogServiceLocalCreate new error log entry- Specified by:
createin interfaceErrorLogServiceLocal
-
deleteOldErrorLogs
public long deleteOldErrorLogs()
Description copied from interface:ErrorLogServiceLocalDeletes the old error logs according to the global configuration parameters- Specified by:
deleteOldErrorLogsin interfaceErrorLogServiceLocal
-
getSearchData
public ErrorLogSearchData getSearchData() throws FrameworkException
Description copied from interface:ErrorLogServiceSearches the error log history- Specified by:
getSearchDatain interfaceErrorLogService- Throws:
FrameworkException
-
load
public ErrorLogDetailedVO load(Long id) throws EntityNotFoundException
Description copied from interface:ErrorLogServiceLoads an entry by id- Specified by:
loadin interfaceErrorLogService- Throws:
EntityNotFoundException
-
onApplicationUpgradeInitialization
public void onApplicationUpgradeInitialization()
Description copied from interface:ApplicationUpgradeInitializationListenerInvoked when the application service is initialized- Specified by:
onApplicationUpgradeInitializationin interfaceApplicationUpgradeInitializationListener
-
remove
public void remove(Long id)
Description copied from interface:ErrorLogServiceRemoves a single entry- Specified by:
removein interfaceErrorLogService
-
removeAll
public void removeAll(Set<Long> ids)
Description copied from interface:ErrorLogServiceRemoves all the given entries- Specified by:
removeAllin interfaceErrorLogService
-
search
public Page<ErrorLogVO> search(ErrorLogQuery params)
Description copied from interface:ErrorLogServiceSearches the error log history- Specified by:
searchin interfaceErrorLogService
-
registerNetworkMappings
protected void registerNetworkMappings(NetworkPathRegistry networkPathRegistry)
Description copied from class:BaseServiceImplNeeds to be overridden by subclasses to register the path up to the network- Specified by:
registerNetworkMappingsin classBaseServiceImpl
-
-