Package com.evolveum.midpoint.repo.sqale
Class SqaleServiceBase
- java.lang.Object
-
- com.evolveum.midpoint.repo.sqale.SqaleServiceBase
-
- Direct Known Subclasses:
SqaleAuditService
,SqaleRepositoryService
public class SqaleServiceBase extends Object
-
-
Field Summary
Fields Modifier and Type Field Description protected Trace
logger
protected String
opNamePrefix
Class name prefix for operation names, including the dot separator.protected SqlPerformanceMonitorImpl
performanceMonitor
static String
REPOSITORY_IMPL_NAME
Name of the repository implementation.protected SqlPerformanceMonitorsCollection
sqlPerformanceMonitorsCollection
protected SqaleRepoContext
sqlRepoContext
-
Constructor Summary
Constructors Constructor Description SqaleServiceBase(SqaleRepoContext sqlRepoContext, SqlPerformanceMonitorsCollection sqlPerformanceMonitorsCollection)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
destroy()
SqlPerformanceMonitorImpl
getPerformanceMonitor()
@NotNull RepositoryDiag
getRepositoryDiag()
protected SystemException
handledGeneralException(@NotNull Throwable ex, @NotNull OperationResult operationResult)
Handles exception outside of transaction - this does not handle transactional problems.protected <T> void
logSearchInputParameters(Class<T> type, ObjectQuery query, String operation)
protected PrismContext
prismContext()
protected void
recordFatalError(@NotNull OperationResult operationResult, @NotNull Throwable t)
protected void
registerOperationFinish(long opHandle)
protected <T extends Containerable>
longregisterOperationStart(String kind, PrismContainer<T> object)
Registers operation start with specified short operation type name.protected long
registerOperationStart(String kind, Class<?> type)
SqaleRepositoryConfiguration
repositoryConfiguration()
SqaleRepoContext
sqlRepoContext()
-
-
-
Field Detail
-
logger
protected final Trace logger
-
REPOSITORY_IMPL_NAME
public static final String REPOSITORY_IMPL_NAME
Name of the repository implementation. While public, the value is often copied because this service class is implementation detail for the rest of the midPoint.- See Also:
- Constant Field Values
-
opNamePrefix
protected final String opNamePrefix
Class name prefix for operation names, including the dot separator. Use with various `RepositoryService.OP_*` constants, not with constants without `OP_` prefix because they already contain class name of the service interface. [NOTE] This distinguishes operation names for audit and repository (e.g. `searchObjects`) - both in operation results and in performance monitoring (which previously didn't include class names). To make things compact enough, simple (short) class name is used.
-
sqlRepoContext
protected final SqaleRepoContext sqlRepoContext
-
sqlPerformanceMonitorsCollection
protected final SqlPerformanceMonitorsCollection sqlPerformanceMonitorsCollection
-
performanceMonitor
protected SqlPerformanceMonitorImpl performanceMonitor
-
-
Constructor Detail
-
SqaleServiceBase
public SqaleServiceBase(SqaleRepoContext sqlRepoContext, SqlPerformanceMonitorsCollection sqlPerformanceMonitorsCollection)
-
-
Method Detail
-
sqlRepoContext
public SqaleRepoContext sqlRepoContext()
-
repositoryConfiguration
public SqaleRepositoryConfiguration repositoryConfiguration()
-
prismContext
protected PrismContext prismContext()
-
getPerformanceMonitor
public SqlPerformanceMonitorImpl getPerformanceMonitor()
-
handledGeneralException
protected SystemException handledGeneralException(@NotNull @NotNull Throwable ex, @NotNull @NotNull OperationResult operationResult)
Handles exception outside of transaction - this does not handle transactional problems. ReturnsSystemException
, call with `throw` keyword.
-
recordFatalError
protected void recordFatalError(@NotNull @NotNull OperationResult operationResult, @NotNull @NotNull Throwable t)
-
logSearchInputParameters
protected <T> void logSearchInputParameters(Class<T> type, ObjectQuery query, String operation)
-
registerOperationStart
protected <T extends Containerable> long registerOperationStart(String kind, PrismContainer<T> object)
Registers operation start with specified short operation type name.
-
registerOperationFinish
protected void registerOperationFinish(long opHandle)
-
destroy
@PreDestroy public void destroy()
-
getRepositoryDiag
@NotNull public @NotNull RepositoryDiag getRepositoryDiag()
-
-