Package org.sqlproc.engine.spring.jmx
Class SpringEngineFactoryJmx
- java.lang.Object
-
- org.sqlproc.engine.jmx.SqlDefaultFactoryMXBean
-
- org.sqlproc.engine.spring.jmx.SpringEngineFactoryJmx
-
@ManagedResource(objectName="sql-processor:type=Engine", description="The simplified JMX interface for the SQL Engine factory.") public class SpringEngineFactoryJmx extends SqlDefaultFactoryMXBeanThe implementation of the simplified JMX interface for the SQL Engine factory.The factory can be based on Spring DI framework for example.
For more info please see the Tutorials.
- Author:
- Vladimir Hudec
-
-
Constructor Summary
Constructors Constructor Description SpringEngineFactoryJmx()
-
Method Summary
-
Methods inherited from class org.sqlproc.engine.jmx.SqlDefaultFactoryMXBean
setSqlEngineFactory
-
-
-
-
Method Detail
-
initQueryEngines
@ManagedOperation(description="In the case the SQL Query Engines are not initialized, a new static instances are established in the cache.") @ManagedOperationParameters(@ManagedOperationParameter(name="names",description="The names of the required SQL Query Engines instances")) public int initQueryEngines(String names)
- Overrides:
initQueryEnginesin classSqlDefaultFactoryMXBean
-
initCrudEngines
@ManagedOperation(description="In the case the SQL CRUD Engines are not initialized, a new static instances are established in the cache.") @ManagedOperationParameters(@ManagedOperationParameter(name="names",description="The names of the required SQL CRUD Engines instances")) public int initCrudEngines(String names)
- Overrides:
initCrudEnginesin classSqlDefaultFactoryMXBean
-
initProcedureEngines
@ManagedOperation(description="In the case the SQL Procedure Engines are not initialized, a new static instances are established in the cache.") @ManagedOperationParameters(@ManagedOperationParameter(name="names",description="The names of the required SQL Procedure Engines instances")) public int initProcedureEngines(String names)
- Overrides:
initProcedureEnginesin classSqlDefaultFactoryMXBean
-
resetQueryEngines
@ManagedOperation(description="In the case any dynamic SQL Query Engine is in the cache, the static one is re-established.") @ManagedOperationParameters(@ManagedOperationParameter(name="names",description="The names of the required SQL Query Engines instances")) public int resetQueryEngines(String names)
- Overrides:
resetQueryEnginesin classSqlDefaultFactoryMXBean
-
resetCrudEngines
@ManagedOperation(description="In the case any dynamic SQL CRUD Engine is in the cache, the static one is re-established.") @ManagedOperationParameters(@ManagedOperationParameter(name="names",description="The names of the required SQL CRUD Engines instances")) public int resetCrudEngines(String names)
- Overrides:
resetCrudEnginesin classSqlDefaultFactoryMXBean
-
resetProcedureEngines
@ManagedOperation(description="In the case any dynamic SQL Procedure Engine is in the cache, the static one is re-established.") @ManagedOperationParameters(@ManagedOperationParameter(name="names",description="The names of the required SQL Procedure Engines instances")) public int resetProcedureEngines(String names)
- Overrides:
resetProcedureEnginesin classSqlDefaultFactoryMXBean
-
newQueryEngine
@ManagedOperation(description="A new dynamic SQL Query Engine instance is established in the cache. The static one is suppressed.") @ManagedOperationParameter(name="name",description="The name of the required SQL Query Engine instances") @ManagedOperationParameter(name="sqlStatement",description="The new SQL statement, which is going to replace the original one") public void newQueryEngine(String name, String sqlStatement) throws SqlEngineException
- Overrides:
newQueryEnginein classSqlDefaultFactoryMXBean- Throws:
SqlEngineException
-
newCrudEngine
@ManagedOperation(description="A new dynamic SQL CRUD Engine instance is established in the cache. The static one is suppressed.") @ManagedOperationParameter(name="name",description="The name of the required SQL CRUD Engine instances") @ManagedOperationParameter(name="sqlStatement",description="The new SQL statement, which is going to replace the original one") public void newCrudEngine(String name, String sqlStatement)
- Overrides:
newCrudEnginein classSqlDefaultFactoryMXBean
-
newProcedureEngine
@ManagedOperation(description="A new dynamic SQL Procedure Engine instance is established in the cache. The static one is suppressed.") @ManagedOperationParameter(name="name",description="The name of the required Procedure Query Engine instances") @ManagedOperationParameter(name="sqlStatement",description="The new SQL statement, which is going to replace the original one") public void newProcedureEngine(String name, String sqlStatement)
- Overrides:
newProcedureEnginein classSqlDefaultFactoryMXBean
-
getQueryNames
@ManagedOperation(description="Returns the collection of names of all initialized/constructed static SQL Query Engine instances.") public List<String> getQueryNames()
- Overrides:
getQueryNamesin classSqlDefaultFactoryMXBean
-
getQueryDynamicNames
@ManagedOperation(description="Returns the collection of names of all initialized/constructed dynamic SQL Query Engine instances.") public List<String> getQueryDynamicNames()
- Overrides:
getQueryDynamicNamesin classSqlDefaultFactoryMXBean
-
getCrudNames
@ManagedOperation(description="Returns the collection of names of all initialized/constructed static SQL Crud Engine instances.") public List<String> getCrudNames()
- Overrides:
getCrudNamesin classSqlDefaultFactoryMXBean
-
getCrudDynamicNames
@ManagedOperation(description="Returns the collection of names of all initialized/constructed dynamic SQL Crud Engine instances.") public List<String> getCrudDynamicNames()
- Overrides:
getCrudDynamicNamesin classSqlDefaultFactoryMXBean
-
getProcedureNames
@ManagedOperation(description="Returns the collection of names of all initialized/constructed static SQL Procedure Engine instances.") public List<String> getProcedureNames()
- Overrides:
getProcedureNamesin classSqlDefaultFactoryMXBean
-
getProcedureDynamicNames
@ManagedOperation(description="Returns the collection of names of all initialized/constructed dynamic SQL Procedure Engine instances.") public List<String> getProcedureDynamicNames()
- Overrides:
getProcedureDynamicNamesin classSqlDefaultFactoryMXBean
-
getQueryEngineProcessingCache
@ManagedOperation(description="Returns the processing cache used for the selected SQL Query Engine.") public List<String> getQueryEngineProcessingCache(String name)
- Overrides:
getQueryEngineProcessingCachein classSqlDefaultFactoryMXBean
-
getCrudEngineProcessingCache
@ManagedOperation(description="Returns the processing cache used for the selected SQL CRUD Engine.") public List<String> getCrudEngineProcessingCache(String name)
- Overrides:
getCrudEngineProcessingCachein classSqlDefaultFactoryMXBean
-
getProcedureEngineProcessingCache
@ManagedOperation(description="Returns the processing cache used for the selected SQL Procedure Engine.") public List<String> getProcedureEngineProcessingCache(String name)
- Overrides:
getProcedureEngineProcessingCachein classSqlDefaultFactoryMXBean
-
getQueryEngineProcessingCacheStatistics
@ManagedOperation(description="Returns the processing cache statistics used for the selected SQL Query Engine.") public List<String> getQueryEngineProcessingCacheStatistics(String name)
- Overrides:
getQueryEngineProcessingCacheStatisticsin classSqlDefaultFactoryMXBean
-
getCrudEngineProcessingCacheStatistics
@ManagedOperation(description="Returns the processing cache statistics used for the selected SQL CRUD Engine.") public List<String> getCrudEngineProcessingCacheStatistics(String name)
- Overrides:
getCrudEngineProcessingCacheStatisticsin classSqlDefaultFactoryMXBean
-
getProcedureEngineProcessingCacheStatistics
@ManagedOperation(description="Returns the processing cache statistics used for the selected SQL Procedure Engine.") public List<String> getProcedureEngineProcessingCacheStatistics(String name)
- Overrides:
getProcedureEngineProcessingCacheStatisticsin classSqlDefaultFactoryMXBean
-
resetQueryEngineProcessingCache
@ManagedOperation(description="Clears the processing cache used for the selected SQL Query Engine.") public int resetQueryEngineProcessingCache(String name, String names)
- Overrides:
resetQueryEngineProcessingCachein classSqlDefaultFactoryMXBean
-
resetCrudEngineProcessingCache
@ManagedOperation(description="Clears the processing cache used for the selected SQL CRUD Engine.") public int resetCrudEngineProcessingCache(String name, String names)
- Overrides:
resetCrudEngineProcessingCachein classSqlDefaultFactoryMXBean
-
resetProcedureEngineProcessingCache
@ManagedOperation(description="Clears the processing cache used for the selected SQL Procedure Engine.") public int resetProcedureEngineProcessingCache(String name, String names)
- Overrides:
resetProcedureEngineProcessingCachein classSqlDefaultFactoryMXBean
-
isLazyInit
@ManagedOperation(description="Returns the collection of names of all initialized/constructed static SQL Engine instances.") public boolean isLazyInit()
- Overrides:
isLazyInitin classSqlDefaultFactoryMXBean
-
setLazyInit
@ManagedOperation(description="Sets the indicator to speed up the initialization process.") @ManagedOperationParameters(@ManagedOperationParameter(name="lazyInit",description="The indicator to speed up the initialization process.")) public void setLazyInit(boolean lazyInit)
- Overrides:
setLazyInitin classSqlDefaultFactoryMXBean
-
getAsyncInitThreads
@ManagedOperation(description="Returns the indicator the initialization process should be done asynchronously.") public Integer getAsyncInitThreads()
- Overrides:
getAsyncInitThreadsin classSqlDefaultFactoryMXBean
-
setAsyncInitThreads
@ManagedOperation(description="Sets the number of threads used for asynchronous initialization") @ManagedOperationParameters(@ManagedOperationParameter(name="asyncInitThreads",description="The number of threads used for asynchronous initialization.")) public void setAsyncInitThreads(Integer asyncInitThreads)
- Overrides:
setAsyncInitThreadsin classSqlDefaultFactoryMXBean
-
getInitTreshold
@ManagedOperation(description="Returns the initialization threshold. The engines, which usage is at least this number should be initialized directly.") public Integer getInitTreshold()
- Overrides:
getInitTresholdin classSqlDefaultFactoryMXBean
-
setInitTreshold
@ManagedOperation(description="Sets the initialization threshold. The engines, which usage is at least this number should be initialized directly.") @ManagedOperationParameters(@ManagedOperationParameter(name="initTreshold",description="The initialization threshold.")) public void setInitTreshold(Integer initTreshold)
- Overrides:
setInitTresholdin classSqlDefaultFactoryMXBean
-
getInitInUsageOrder
@ManagedOperation(description="Returns the indicator that the most frequently used engines should be initialized preferentially.") public Boolean getInitInUsageOrder()
- Overrides:
getInitInUsageOrderin classSqlDefaultFactoryMXBean
-
setInitInUsageOrder
@ManagedOperation(description="Sets the indicator that the most frequently used engines should be initialized preferentially.") @ManagedOperationParameters(@ManagedOperationParameter(name="initTreshold",description="The indicator value.")) public void setInitInUsageOrder(Boolean initInUsageOrder)
- Overrides:
setInitInUsageOrderin classSqlDefaultFactoryMXBean
-
isAsyncInitFinished
@ManagedOperation(description="Returns the flag indicating the asynchronous SQL Processor engines initialization has been finished.") public Boolean isAsyncInitFinished()
- Overrides:
isAsyncInitFinishedin classSqlDefaultFactoryMXBean
-
getEnginesInitErrors
@ManagedOperation(description="Returns the result of engines initialization process.") public String getEnginesInitErrors()
- Overrides:
getEnginesInitErrorsin classSqlDefaultFactoryMXBean
-
getQueryEnginesToInit
@ManagedOperation(description="Returns the container of the Query Engines\' names, which has to be initialized.") public List<String> getQueryEnginesToInit()
- Overrides:
getQueryEnginesToInitin classSqlDefaultFactoryMXBean
-
getCrudEnginesToInit
@ManagedOperation(description="Returns the container of the CRUD Engines\' names, which has to be initialized.") public List<String> getCrudEnginesToInit()
- Overrides:
getCrudEnginesToInitin classSqlDefaultFactoryMXBean
-
getProcedureEnginesToInit
@ManagedOperation(description="Returns the container of the Procedure Engines\' names, which has to be initialized.") public List<String> getProcedureEnginesToInit()
- Overrides:
getProcedureEnginesToInitin classSqlDefaultFactoryMXBean
-
getQueryEngineUsage
@ManagedOperation(description="Returns the Query Engine usage number.") @ManagedOperationParameters(@ManagedOperationParameter(name="name",description="The name of the SQL Query Engine")) public int getQueryEngineUsage(String name)
- Overrides:
getQueryEngineUsagein classSqlDefaultFactoryMXBean
-
getCrudEngineUsage
@ManagedOperation(description="Returns the CRUD Engine usage number.") @ManagedOperationParameters(@ManagedOperationParameter(name="name",description="The name of the SQL CRUD Engine")) public int getCrudEngineUsage(String name)
- Overrides:
getCrudEngineUsagein classSqlDefaultFactoryMXBean
-
getProcedureEngineUsage
@ManagedOperation(description="Returns the Procedure Engine usage number.") @ManagedOperationParameters(@ManagedOperationParameter(name="name",description="The name of the SQL Procedure Engine")) public int getProcedureEngineUsage(String name)
- Overrides:
getProcedureEngineUsagein classSqlDefaultFactoryMXBean
-
resetQueryEngineUsage
@ManagedOperation(description="Resets the Query Engine usage number.") @ManagedOperationParameters(@ManagedOperationParameter(name="name",description="The name of the SQL Query Engine")) public int resetQueryEngineUsage(String name)
- Overrides:
resetQueryEngineUsagein classSqlDefaultFactoryMXBean
-
resetCrudEngineUsage
@ManagedOperation(description="Resets the CRUD Engine usage number.") @ManagedOperationParameters(@ManagedOperationParameter(name="name",description="The name of the SQL CRUD Engine")) public int resetCrudEngineUsage(String name)
- Overrides:
resetCrudEngineUsagein classSqlDefaultFactoryMXBean
-
resetProcedureEngineUsage
@ManagedOperation(description="Resets the Procedure Engine usage number.") @ManagedOperationParameters(@ManagedOperationParameter(name="name",description="The name of the SQL Procedure Engine")) public int resetProcedureEngineUsage(String name)
- Overrides:
resetProcedureEngineUsagein classSqlDefaultFactoryMXBean
-
loadConfiguration
@ManagedOperation(description="Loads the persisted configuration.") public void loadConfiguration()
- Overrides:
loadConfigurationin classSqlDefaultFactoryMXBean
-
storeConfiguration
@ManagedOperation(description="Persists the configuration into the external file.") public void storeConfiguration()
- Overrides:
storeConfigurationin classSqlDefaultFactoryMXBean
-
clearConfiguration
@ManagedOperation(description="Resets the state of the dynamic configuration instance.") public void clearConfiguration()
- Overrides:
clearConfigurationin classSqlDefaultFactoryMXBean
-
clearConfigurationUsage
@ManagedOperation(description="Reset the engines\' usage counters.") public void clearConfigurationUsage()
- Overrides:
clearConfigurationUsagein classSqlDefaultFactoryMXBean
-
getUseProcessingCache
@ManagedOperation(description="Returns the indicator that the processing cache can be used.") public Boolean getUseProcessingCache()
- Overrides:
getUseProcessingCachein classSqlDefaultFactoryMXBean
-
setUseProcessingCache
@ManagedOperation(description="Sets the indicator that the processing cache can be used.") @ManagedOperationParameters(@ManagedOperationParameter(name="useProcessingCache",description="The indicator that the processing cache can be used")) public void setUseProcessingCache(Boolean useProcessingCache)
- Overrides:
setUseProcessingCachein classSqlDefaultFactoryMXBean
-
getUseDynamicProcessingCache
@ManagedOperation(description="Returns the indicator that the processing cache can be used dynamically.") public Boolean getUseDynamicProcessingCache()
- Overrides:
getUseDynamicProcessingCachein classSqlDefaultFactoryMXBean
-
setUseDynamicProcessingCache
@ManagedOperation(description="Sets the indicator that the processing cache can be used dynamically.") @ManagedOperationParameters(@ManagedOperationParameter(name="useDynamicProcessingCache",description="The indicator that the processing cache can be used dynamically")) public void setUseDynamicProcessingCache(Boolean useDynamicProcessingCache)
- Overrides:
setUseDynamicProcessingCachein classSqlDefaultFactoryMXBean
-
getDoProcessingCacheEngines
@ManagedOperation(description="Returns the negative processing cache.") public List<String> getDoProcessingCacheEngines()
- Overrides:
getDoProcessingCacheEnginesin classSqlDefaultFactoryMXBean
-
initDoProcessingCache
@ManagedOperation(description="Updates the positive processing cache.") @ManagedOperationParameters(@ManagedOperationParameter(name="names",description="The names of the SQL Query Engines instances")) public int initDoProcessingCache(String names)
- Overrides:
initDoProcessingCachein classSqlDefaultFactoryMXBean
-
resetDoProcessingCache
@ManagedOperation(description="Updates the positive processing cache.") @ManagedOperationParameters(@ManagedOperationParameter(name="names",description="The names of the SQL Query Engines instances")) public int resetDoProcessingCache(String names)
- Overrides:
resetDoProcessingCachein classSqlDefaultFactoryMXBean
-
getDontProcessingCacheEngines
@ManagedOperation(description="Returns the negative processing cache.") public List<String> getDontProcessingCacheEngines()
- Overrides:
getDontProcessingCacheEnginesin classSqlDefaultFactoryMXBean
-
initDontProcessingCache
@ManagedOperation(description="Updates the negative processing cache.") @ManagedOperationParameters(@ManagedOperationParameter(name="names",description="The names of the SQL Query Engines instances")) public int initDontProcessingCache(String names)
- Overrides:
initDontProcessingCachein classSqlDefaultFactoryMXBean
-
resetDontProcessingCache
@ManagedOperation(description="Updates the negative processing cache.") @ManagedOperationParameters(@ManagedOperationParameter(name="names",description="The names of the SQL Query Engines instances")) public int resetDontProcessingCache(String names)
- Overrides:
resetDontProcessingCachein classSqlDefaultFactoryMXBean
-
-