org.sqlproc.engine.spring.jmx
Class SpringEngineFactoryJmx

java.lang.Object
  extended by org.sqlproc.engine.jmx.SqlSimpleFactoryMXBean
      extended by 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 SqlSimpleFactoryMXBean

The 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
SpringEngineFactoryJmx()
           
 
Method Summary
 void clearConfiguration()
           
 void clearConfigurationUsage()
           
 Boolean getAsyncInit()
          
 List<String> getCrudEngineProcessingCache(String name)
          
 List<String> getCrudEnginesToInit()
          
 int getCrudEngineUsage(String name)
          
 List<String> getDynamicNames()
          
 Boolean getInitInUsageOrder()
          
 Integer getInitTreshold()
          
 List<String> getNames()
          
 List<String> getProcedureEngineProcessingCache(String name)
          
 List<String> getProcedureEnginesToInit()
          
 int getProcedureEngineUsage(String name)
          
 List<String> getQueryEngineProcessingCache(String name)
          
 List<String> getQueryEnginesToInit()
          
 int getQueryEngineUsage(String name)
          
 int initCrudEngines(String names)
          
 int initProcedureEngines(String names)
          
 int initQueryEngines(String names)
          
 boolean isLazyInit()
          
 void loadConfiguration()
           
 void newCrudEngine(String name, String sqlStatement)
          
 void newProcedureEngine(String name, String sqlStatement)
          
 void newQueryEngine(String name, String sqlStatement)
          
 int resetCrudEngineProcessingCache(String name, String names)
          
 int resetCrudEngines(String names)
          
 int resetCrudEngineUsage(String name)
          
 int resetProcedureEngineProcessingCache(String name, String names)
          
 int resetProcedureEngines(String names)
          
 int resetProcedureEngineUsage(String name)
          
 int resetQueryEngineProcessingCache(String name, String names)
          
 int resetQueryEngines(String names)
          
 int resetQueryEngineUsage(String name)
          
 void setAsyncInit(Boolean asyncInit)
          
 void setInitInUsageOrder(Boolean initInUsageOrder)
           
 void setInitTreshold(Integer initTreshold)
          
 void setLazyInit(boolean lazyInit)
          
 void storeConfiguration()
           
 
Methods inherited from class org.sqlproc.engine.jmx.SqlSimpleFactoryMXBean
setSqlEngineFactory
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SpringEngineFactoryJmx

public SpringEngineFactoryJmx()
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(value=)
public int initQueryEngines(String names)

Overrides:
initQueryEngines in class SqlSimpleFactoryMXBean

initCrudEngines

@ManagedOperation(description="In the case the SQL CRUD Engines are not initialized, a new static instances are established in the cache.")
@ManagedOperationParameters(value=)
public int initCrudEngines(String names)

Overrides:
initCrudEngines in class SqlSimpleFactoryMXBean

initProcedureEngines

@ManagedOperation(description="In the case the SQL Procedure Engines are not initialized, a new static instances are established in the cache.")
@ManagedOperationParameters(value=)
public int initProcedureEngines(String names)

Overrides:
initProcedureEngines in class SqlSimpleFactoryMXBean

resetQueryEngines

@ManagedOperation(description="In the case any dynamic SQL Query Engine is in the cache, the static one is re-established.")
@ManagedOperationParameters(value=)
public int resetQueryEngines(String names)

Overrides:
resetQueryEngines in class SqlSimpleFactoryMXBean

resetCrudEngines

@ManagedOperation(description="In the case any dynamic SQL CRUD Engine is in the cache, the static one is re-established.")
@ManagedOperationParameters(value=)
public int resetCrudEngines(String names)

Overrides:
resetCrudEngines in class SqlSimpleFactoryMXBean

resetProcedureEngines

@ManagedOperation(description="In the case any dynamic SQL Procedure Engine is in the cache, the static one is re-established.")
@ManagedOperationParameters(value=)
public int resetProcedureEngines(String names)

Overrides:
resetProcedureEngines in class SqlSimpleFactoryMXBean

newQueryEngine

@ManagedOperation(description="A new dynamic SQL Query Engine instance is established in the cache. The static one is suppressed.")
@ManagedOperationParameters(value={,})
public void newQueryEngine(String name,
                                                                       String sqlStatement)
                    throws SqlEngineException

Overrides:
newQueryEngine in class SqlSimpleFactoryMXBean
Throws:
SqlEngineException

newCrudEngine

@ManagedOperation(description="A new dynamic SQL CRUD Engine instance is established in the cache. The static one is suppressed.")
@ManagedOperationParameters(value={,})
public void newCrudEngine(String name,
                                                                      String sqlStatement)

Overrides:
newCrudEngine in class SqlSimpleFactoryMXBean

newProcedureEngine

@ManagedOperation(description="A new dynamic SQL Procedure Engine instance is established in the cache. The static one is suppressed.")
@ManagedOperationParameters(value={,})
public void newProcedureEngine(String name,
                                                                           String sqlStatement)

Overrides:
newProcedureEngine in class SqlSimpleFactoryMXBean

getNames

@ManagedOperation(description="Returns the collection of names of all initialized/constructed static SQL Engine instances.")
public List<String> getNames()

Overrides:
getNames in class SqlSimpleFactoryMXBean

getDynamicNames

@ManagedOperation(description="Returns the collection of names of all initialized/constructed dynamic SQL Engine instances.")
public List<String> getDynamicNames()

Overrides:
getDynamicNames in class SqlSimpleFactoryMXBean

getQueryEngineProcessingCache

@ManagedOperation(description="Returns the processing cache used for the selected SQL Query Engine.")
public List<String> getQueryEngineProcessingCache(String name)

Overrides:
getQueryEngineProcessingCache in class SqlSimpleFactoryMXBean

getCrudEngineProcessingCache

@ManagedOperation(description="Returns the processing cache used for the selected SQL CRUD Engine.")
public List<String> getCrudEngineProcessingCache(String name)

Overrides:
getCrudEngineProcessingCache in class SqlSimpleFactoryMXBean

getProcedureEngineProcessingCache

@ManagedOperation(description="Returns the processing cache used for the selected SQL Procedure Engine.")
public List<String> getProcedureEngineProcessingCache(String name)

Overrides:
getProcedureEngineProcessingCache in class SqlSimpleFactoryMXBean

resetQueryEngineProcessingCache

@ManagedOperation(description="Clears the processing cache used for the selected SQL Query Engine.")
public int resetQueryEngineProcessingCache(String name,
                                                            String names)

Overrides:
resetQueryEngineProcessingCache in class SqlSimpleFactoryMXBean

resetCrudEngineProcessingCache

@ManagedOperation(description="Clears the processing cache used for the selected SQL CRUD Engine.")
public int resetCrudEngineProcessingCache(String name,
                                                           String names)

Overrides:
resetCrudEngineProcessingCache in class SqlSimpleFactoryMXBean

resetProcedureEngineProcessingCache

@ManagedOperation(description="Clears the processing cache used for the selected SQL Procedure Engine.")
public int resetProcedureEngineProcessingCache(String name,
                                                                String names)

Overrides:
resetProcedureEngineProcessingCache in class SqlSimpleFactoryMXBean

isLazyInit

@ManagedOperation(description="Returns the collection of names of all initialized/constructed static SQL Engine instances.")
public boolean isLazyInit()

Overrides:
isLazyInit in class SqlSimpleFactoryMXBean

setLazyInit

@ManagedOperation(description="Sets the indicator to speed up the initialization process.")
@ManagedOperationParameters(value=)
public void setLazyInit(boolean lazyInit)

Overrides:
setLazyInit in class SqlSimpleFactoryMXBean

getAsyncInit

@ManagedOperation(description="Returns the indicator the initialization process should be done asynchronously.")
public Boolean getAsyncInit()

Overrides:
getAsyncInit in class SqlSimpleFactoryMXBean

setAsyncInit

@ManagedOperation(description="Sets the indicator the initialization process should be done asynchronously")
@ManagedOperationParameters(value=)
public void setAsyncInit(Boolean asyncInit)

Overrides:
setAsyncInit in class SqlSimpleFactoryMXBean

getInitTreshold

@ManagedOperation(description="Returns the initialization threshold. The engines, which usage is at least this number should be initialized directly.")
public Integer getInitTreshold()

Overrides:
getInitTreshold in class SqlSimpleFactoryMXBean

setInitTreshold

@ManagedOperation(description="Sets the initialization threshold. The engines, which usage is at least this number should be initialized directly.")
@ManagedOperationParameters(value=)
public void setInitTreshold(Integer initTreshold)

Overrides:
setInitTreshold in class SqlSimpleFactoryMXBean

getInitInUsageOrder

@ManagedOperation(description="Returns the indicator that the most frequently used engines should be initialized preferentially.")
public Boolean getInitInUsageOrder()

Overrides:
getInitInUsageOrder in class SqlSimpleFactoryMXBean

setInitInUsageOrder

@ManagedOperation(description="Sets the indicator that the most frequently used engines should be initialized preferentially.")
@ManagedOperationParameters(value=)
public void setInitInUsageOrder(Boolean initInUsageOrder)
Overrides:
setInitInUsageOrder in class SqlSimpleFactoryMXBean

getQueryEnginesToInit

@ManagedOperation(description="Returns the container of the Query Engines\' names, which has to be initialized.")
public List<String> getQueryEnginesToInit()

Overrides:
getQueryEnginesToInit in class SqlSimpleFactoryMXBean

getCrudEnginesToInit

@ManagedOperation(description="Returns the container of the CRUD Engines\' names, which has to be initialized.")
public List<String> getCrudEnginesToInit()

Overrides:
getCrudEnginesToInit in class SqlSimpleFactoryMXBean

getProcedureEnginesToInit

@ManagedOperation(description="Returns the container of the Procedure Engines\' names, which has to be initialized.")
public List<String> getProcedureEnginesToInit()

Overrides:
getProcedureEnginesToInit in class SqlSimpleFactoryMXBean

getQueryEngineUsage

@ManagedOperation(description="Returns the Query Engine usage number.")
@ManagedOperationParameters(value=)
public int getQueryEngineUsage(String name)

Overrides:
getQueryEngineUsage in class SqlSimpleFactoryMXBean

getCrudEngineUsage

@ManagedOperation(description="Returns the CRUD Engine usage number.")
@ManagedOperationParameters(value=)
public int getCrudEngineUsage(String name)

Overrides:
getCrudEngineUsage in class SqlSimpleFactoryMXBean

getProcedureEngineUsage

@ManagedOperation(description="Returns the Procedure Engine usage number.")
@ManagedOperationParameters(value=)
public int getProcedureEngineUsage(String name)

Overrides:
getProcedureEngineUsage in class SqlSimpleFactoryMXBean

resetQueryEngineUsage

@ManagedOperation(description="Resets the Query Engine usage number.")
@ManagedOperationParameters(value=)
public int resetQueryEngineUsage(String name)

Overrides:
resetQueryEngineUsage in class SqlSimpleFactoryMXBean

resetCrudEngineUsage

@ManagedOperation(description="Resets the CRUD Engine usage number.")
@ManagedOperationParameters(value=)
public int resetCrudEngineUsage(String name)

Overrides:
resetCrudEngineUsage in class SqlSimpleFactoryMXBean

resetProcedureEngineUsage

@ManagedOperation(description="Resets the Procedure Engine usage number.")
@ManagedOperationParameters(value=)
public int resetProcedureEngineUsage(String name)

Overrides:
resetProcedureEngineUsage in class SqlSimpleFactoryMXBean

loadConfiguration

@ManagedOperation(description="Loads the persisted configuration.")
public void loadConfiguration()
Overrides:
loadConfiguration in class SqlSimpleFactoryMXBean

storeConfiguration

@ManagedOperation(description="Persists the configuration into the external file.")
public void storeConfiguration()
Overrides:
storeConfiguration in class SqlSimpleFactoryMXBean

clearConfiguration

@ManagedOperation(description="Resets the state of the dynamic configuration instance.")
public void clearConfiguration()
Overrides:
clearConfiguration in class SqlSimpleFactoryMXBean

clearConfigurationUsage

@ManagedOperation(description="Reset the engines\' usage counters.")
public void clearConfigurationUsage()
Overrides:
clearConfigurationUsage in class SqlSimpleFactoryMXBean


Copyright © 2015. All rights reserved.