Java Doc for VirtualDatabaseMBean.java in  » Database-JDBC-Connection-Pool » sequoia-2.10.9 » org » continuent » sequoia » common » jmx » mbeans » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Database JDBC Connection Pool » sequoia 2.10.9 » org.continuent.sequoia.common.jmx.mbeans 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


org.continuent.sequoia.common.jmx.mbeans.VirtualDatabaseMBean

All known Subclasses:   org.continuent.sequoia.controller.virtualdatabase.management.VirtualDatabase,
VirtualDatabaseMBean
public interface VirtualDatabaseMBean (Code)
JMX Interface to remotely manage a Virtual Databases.
author:
   Emmanuel Cecchet
author:
   Nicolas Modrzyk
version:
   1.0




Method Summary
 voidabort(long transactionId, boolean logAbort, boolean forceAbort)
     Abort a transaction that has been started but in which no query was executed.
 voidbackupBackend(String backendName, String login, String password, String dumpName, String backuperName, String path, boolean force, ArrayList tables)
     Create a backup of a specific backend.
 voidbackupBackend(String backendName, String login, String password, String dumpName, String backuperName, String path, ArrayList tables)
     This is backupBackend(force=true).
 booleancheckAdminAuthentication(String adminLogin, String adminPassword)
    
 voidclosePersistentConnection(String login, long persistentConnectionId)
     Close the given persistent connection.
 voidcopyLogFromCheckpoint(String dumpName, String controllerName)
     Copies a chunk of the local virtual database recovery log onto a remote controller's peer virtual database log.
 voiddeleteDump(String dumpName, boolean keepsFile)
     Delete the dump entry associated to the dumpName.
If keepsFile is false, the dump file is also removed from the file system.
 voiddeleteLogUpToCheckpoint(String checkpointName)
     Deletes the recovery log (if any) from the begining upto the specified checkpoint.
 voiddisableBackendWithCheckpoint(String databaseBackendName)
     Disables a backend once all the pending write queries are executed.
 voidenableBackendFromCheckpoint(String backendName)
    
 voidforceDisableBackend(String databaseBackendName)
     Disables a backend that is currently enabled on this virtual database (without further check).
 voidforceEnableBackend(String databaseBackendName)
     Enables a backend that has been previously added to this virtual database and that is in the disabled state.
 ListgetAllBackendNames()
     Get a list of all DatabaseBackend names.
 DumpInfo[]getAvailableDumps()
     Get all available dump info for this virtual database an array of DumpInfo containing the available dumpinfo for this virtual database.
 StringgetBackendInformation(String backendName)
     Return information about the specified backend.
 StringgetBackendSchema(String backendName)
     The getXml() method does not return the schema if it is not static anymore, to avoid confusion between static and dynamic schema.
 BackendStatisticsgetBackendStatistics(String backendName)
    
 String[]getBackuperNames()
     Get the names of the Backupers available from this BackupManager.
 String[]getControllers()
     Return the list of controllers defining this virtual database.
 intgetCurrentNbOfThreads()
     Returns the currentNbOfThreads.
 StringgetDumpFormatForBackuper(String backuperName)
    
 TabularDatagetDumps()
    
 StringgetOwningController()
    
 StringgetVirtualDatabaseName()
    
 StringgetXml()
    
 booleanhasRecoveryLog()
    
 booleanhasResultCache()
    
 voidinitializeFromBackend(String databaseBackendName, boolean force)
     Initializes a virtual database from specified Backend.
 voidinitializeFromBackend(String databaseBackendName)
     Performs initializeFromBackend(databaseBackendName, force=false).
 booleanisDistributed()
    
 voidreplicateBackend(String backendName, String newBackendName, Map parameters)
     Add an additionnal backend to the virtual database with connection managers identical to the backend replicated.
 voidrestoreDumpOnBackend(String databaseBackendName, String login, String password, String dumpName, ArrayList tables)
     Restore a dump on a specific backend.
 voidsetBackendLastKnownCheckpoint(String backendName, String checkpoint)
     Sets the last known checkpoint of a backend.
 voidsetMonitoringToActive(boolean active)
     If a monitoring section exists, we can set the monitoring on or off by calling this method.
 voidshutdown(int level)
     Shutdown this virtual database.
 voidtransferBackend(String backend, String controllerDestination)
     Transfer the backend to the destinated controller.
 voidtransferDump(String dumpName, String remoteControllerName, boolean noCopy)
     Transfer specified dump over to specified vdb's controller, making it available for restore operation.
 voidupdateDumpPath(String dumpName, String newPath)
     Update the path of the dump for a given dumpName.



Method Detail
abort
void abort(long transactionId, boolean logAbort, boolean forceAbort) throws SQLException(Code)
Abort a transaction that has been started but in which no query was executed. As we use lazy transaction begin, there is no need to rollback such transaction but just to cleanup the metadata associated with this not effectively started transaction.
Parameters:
  transactionId - id of the transaction to abort
Parameters:
  logAbort - true if the abort (in fact rollback) should be logged inthe recovery log
Parameters:
  forceAbort - true if the abort will be forced. Actually, abort will donothing when a transaction has savepoints (we do not abort thewhole transaction, so that the user can rollback to a previoussavepoint), except when the connection is closed. In this lastcase, if the transaction is not aborted, it prevents futuremaintenance operations such as shutdowns, enable/disable fromcompleting, so we have to force this abort operation. It alsoapplies to the DeadlockDetectionThread and the cleanup of theVirtualDatabaseWorkerThread.
throws:
  SQLException - if an error occurs



backupBackend
void backupBackend(String backendName, String login, String password, String dumpName, String backuperName, String path, boolean force, ArrayList tables) throws VirtualDatabaseException(Code)
Create a backup of a specific backend. Note the backend will be disabled if needed during backup, and will be put back to its previous state after backup. If there is only one backend left in the system, this operation will fail when using 'false' as force parameter.
Parameters:
  backendName - the target backend to backup
Parameters:
  login - the login to use to connect to the database for the backupoperation
Parameters:
  password - the password to use to connect to the database for thebackup operation
Parameters:
  dumpName - the name of the dump to create
Parameters:
  backuperName - the logical name of the backuper to use
Parameters:
  path - the path where to store the dump
Parameters:
  force - use true to force the backup even if there is only one backendleft in the system.
Parameters:
  tables - the list of tables to backup, null means all tables
throws:
  VirtualDatabaseException - if the backup fails



backupBackend
void backupBackend(String backendName, String login, String password, String dumpName, String backuperName, String path, ArrayList tables) throws VirtualDatabaseException(Code)
This is backupBackend(force=true).
See Also:    backupBackend(String backendName, String login, String password,
See Also:   String dumpName, String backuperName, String path, boolean force,
See Also:   ArrayList tables).



checkAdminAuthentication
boolean checkAdminAuthentication(String adminLogin, String adminPassword) throws VirtualDatabaseException(Code)
Authenticate a user for a given virtual database
Parameters:
  adminLogin - username
Parameters:
  adminPassword - password true if authentication is a success, false otherwise
throws:
  VirtualDatabaseException - if database does not exists



closePersistentConnection
void closePersistentConnection(String login, long persistentConnectionId)(Code)
Close the given persistent connection.
Parameters:
  login - login to use to retrieve the right connection pool
Parameters:
  persistentConnectionId - id of the persistent connection to close



copyLogFromCheckpoint
void copyLogFromCheckpoint(String dumpName, String controllerName) throws VirtualDatabaseException(Code)
Copies a chunk of the local virtual database recovery log onto a remote controller's peer virtual database log. The copy is performed from the checkpoint associated to the specified dump uptil 'now' (a new global checkpoint). The copy is sent to the specified remote node.
Parameters:
  dumpName - the name of the dump (which gives associated checkpoint)from which to perform the copy.
Parameters:
  controllerName - the remote controller to send the copy to
throws:
  VirtualDatabaseException - if there is no recovery log, or thevirtual database is not distributed, or in case of error.



deleteDump
void deleteDump(String dumpName, boolean keepsFile) throws VirtualDatabaseException(Code)
Delete the dump entry associated to the dumpName.
If keepsFile is false, the dump file is also removed from the file system.
Parameters:
  dumpName - name of the dump entry to remove
Parameters:
  keepsFile - true if the dump should be also removedfrom the file system, false else
throws:
  VirtualDatabaseException - if an exception occured while removing thedump entry or the dump file



deleteLogUpToCheckpoint
void deleteLogUpToCheckpoint(String checkpointName) throws VirtualDatabaseException(Code)
Deletes the recovery log (if any) from the begining upto the specified checkpoint.
Parameters:
  checkpointName - the name of the checkpoint upto which to delete therecovery log.
throws:
  VirtualDatabaseException - if there is no recovery log, or in case oferror.



disableBackendWithCheckpoint
void disableBackendWithCheckpoint(String databaseBackendName) throws VirtualDatabaseException(Code)
Disables a backend once all the pending write queries are executed. A checkpoint is inserted in the recovery log. The backend must belong to this virtual database. Disabling a disabled backend is a no-operation.
Parameters:
  databaseBackendName - The database backend logical name to disable
exception:
  VirtualDatabaseException - in case of communication-related error



enableBackendFromCheckpoint
void enableBackendFromCheckpoint(String backendName) throws VirtualDatabaseException(Code)
Enable the given backend from its last known checkpoint
Parameters:
  backendName - the name of the backend to enable
throws:
  VirtualDatabaseException - if enable failed, or if there is no lastknown checkpoint



forceDisableBackend
void forceDisableBackend(String databaseBackendName) throws VirtualDatabaseException(Code)
Disables a backend that is currently enabled on this virtual database (without further check).
Parameters:
  databaseBackendName - The database backend logical name to enable
exception:
  VirtualDatabaseException - in case of communication-related error



forceEnableBackend
void forceEnableBackend(String databaseBackendName) throws VirtualDatabaseException(Code)
Enables a backend that has been previously added to this virtual database and that is in the disabled state. The backend is enabled without further check.
Parameters:
  databaseBackendName - The database backend logical name to enable
exception:
  VirtualDatabaseException - in case of communication-related error



getAllBackendNames
List getAllBackendNames() throws VirtualDatabaseException(Code)
Get a list of all DatabaseBackend names. List ArrayList of String representingdatabase backend names
throws:
  VirtualDatabaseException - if an error occurs



getAvailableDumps
DumpInfo[] getAvailableDumps() throws VirtualDatabaseException(Code)
Get all available dump info for this virtual database an array of DumpInfo containing the available dumpinfo for this virtual database. Cannot be null but can be empty.
exception:
  VirtualDatabaseException - if we can't retrieve dumps



getBackendInformation
String getBackendInformation(String backendName) throws VirtualDatabaseException(Code)
Return information about the specified backend.
Parameters:
  backendName - the backend logical name String the backend information
throws:
  VirtualDatabaseException - if an error occurs



getBackendSchema
String getBackendSchema(String backendName) throws VirtualDatabaseException(Code)
The getXml() method does not return the schema if it is not static anymore, to avoid confusion between static and dynamic schema. This method returns a static view of the schema, whatever the dynamic precision is.
Parameters:
  backendName - the name of the backend to get the schema from an xml formatted string
throws:
  VirtualDatabaseException - if an error occurs while accessing thebackend, or if the backend does not exist.



getBackendStatistics
BackendStatistics getBackendStatistics(String backendName) throws Exception(Code)
Retrieves an array of statistics of the given backend for this virtual database
Parameters:
  backendName - name of the backend BackendStatistics[] of formatted data for allbackends or null if the backend does not exist
throws:
  Exception - if fails



getBackuperNames
String[] getBackuperNames()(Code)
Get the names of the Backupers available from this BackupManager. an (possibly 0-sized) array of String representingthe name of the Backupers



getControllers
String[] getControllers()(Code)
Return the list of controllers defining this virtual database. If the database is not distributed this returns the same as getOwningController otherwise returns an array of controller configuring this DistributedVirtualDatabase String[] of controller names.



getCurrentNbOfThreads
int getCurrentNbOfThreads()(Code)
Returns the currentNbOfThreads. int



getDumpFormatForBackuper
String getDumpFormatForBackuper(String backuperName)(Code)
Get the dump format associated to a given Backuper
Parameters:
  backuperName - name associated to a Backuper the dump format associated to a given Backuper



getDumps
TabularData getDumps() throws Exception(Code)
Get all available dump info for this virtual database an open-type represenation of the array of DumpInfothat would be returned by #getAvailableDumps() above.
exception:
  VirtualDatabaseException - if we can't retrieve dumps



getOwningController
String getOwningController()(Code)
Name of the controller owning this virtual database url of the controller



getVirtualDatabaseName
String getVirtualDatabaseName()(Code)
Gets the virtual database name to be used by the client (Sequoia driver) the virtual database name



getXml
String getXml()(Code)
Retrieves this VirtualDatabase object in xml format xml formatted string that conforms to sequoia.dtd



hasRecoveryLog
boolean hasRecoveryLog()(Code)
Indicate if there is a recovery log defined for this virtual database true if the recovery log is defined and can beaccessed, false otherwise



hasResultCache
boolean hasResultCache()(Code)
Indicate if there is a result cache defined for this virtual database true if a request cache is defined and can beaccessed, false otherwise



initializeFromBackend
void initializeFromBackend(String databaseBackendName, boolean force) throws VirtualDatabaseException(Code)
Initializes a virtual database from specified Backend. This has to be performed prior to any use of the vdb backends, i.e. there are no active backends in the vdb, and none has a last known checkpoint. This should be immediately followed by a backup operation on the specified backend. This resets the recovery log - if any - to an empty state, i.e. drops logtable, drops checkpoint table, and clears checkpoint names in the dump table. Finally, sets the last known checkpoint of specified backend to Initial_empty_recovery_log.
Parameters:
  databaseBackendName - the name of the backend to use forinitialization.
Parameters:
  force - if true, do not perform sanity checks, unconditionally performthe initialization
throws:
  VirtualDatabaseException - if there is an active backend or a backendwhich has a last known checkpoint, or if there is no recovery logfor this vdb.



initializeFromBackend
void initializeFromBackend(String databaseBackendName) throws VirtualDatabaseException(Code)
Performs initializeFromBackend(databaseBackendName, force=false). This is a convenience method for backward compatibility.
Parameters:
  databaseBackendName - the name of the backend to use forinitialization.
throws:
  VirtualDatabaseException - if there is an active backend or a backendwhich has a last known checkpoint, or if there is no recovery logfor this vdb.



isDistributed
boolean isDistributed()(Code)
Tells whether this database is distributed or not true if the database is distributed among multiplecontrollers false if it exists on a singlecontroller only



replicateBackend
void replicateBackend(String backendName, String newBackendName, Map parameters) throws VirtualDatabaseException(Code)
Add an additionnal backend to the virtual database with connection managers identical to the backend replicated.
Parameters:
  backendName - the backend to replicate and to use parameters from.
Parameters:
  newBackendName - the new backend name.
Parameters:
  parameters - parameters to override or modify when replicating to thenew backend
throws:
  VirtualDatabaseException - if cannot replicate backend



restoreDumpOnBackend
void restoreDumpOnBackend(String databaseBackendName, String login, String password, String dumpName, ArrayList tables) throws VirtualDatabaseException(Code)
Restore a dump on a specific backend. The proper Backuper is retrieved automatically according to the dump format stored in the recovery log dump table.

This method disables the backend and leave it disabled after recovery process. The user has to call the enableBackendFromCheckpoint after this.
Parameters:
  databaseBackendName - the name of the backend to restore
Parameters:
  login - the login to use to connect to the database for the restoreoperation
Parameters:
  password - the password to use to connect to the database for therestore operation
Parameters:
  dumpName - the name of the dump to restore
Parameters:
  tables - the list of tables to restore, null means all tables
throws:
  VirtualDatabaseException - if the restore operation failed




setBackendLastKnownCheckpoint
void setBackendLastKnownCheckpoint(String backendName, String checkpoint) throws VirtualDatabaseException(Code)
Sets the last known checkpoint of a backend. This will also update the value in the recovery log
Parameters:
  backendName - backend
Parameters:
  checkpoint - checkpoint
throws:
  VirtualDatabaseException - if fails



setMonitoringToActive
void setMonitoringToActive(boolean active) throws VirtualDatabaseException(Code)
If a monitoring section exists, we can set the monitoring on or off by calling this method. If monitoring is not defined we throw an exception.
Parameters:
  active - should set the monitor to on or off
throws:
  VirtualDatabaseException - if there is no monitor.



shutdown
void shutdown(int level) throws VirtualDatabaseException(Code)
Shutdown this virtual database. Finish all threads and stop connection to backends
Parameters:
  level - Constants.SHUTDOWN_WAIT, Constants.SHUTDOWN_SAFE orConstants.SHUTDOWN_FORCE
throws:
  VirtualDatabaseException - if an error occurs



transferBackend
void transferBackend(String backend, String controllerDestination) throws VirtualDatabaseException(Code)
Transfer the backend to the destinated controller. Note that this does nothing in a non-distributed environment
Parameters:
  backend - the backend to transfer
Parameters:
  controllerDestination - the controller to copy the backend to
throws:
  VirtualDatabaseException - if transfer failed



transferDump
void transferDump(String dumpName, String remoteControllerName, boolean noCopy) throws VirtualDatabaseException(Code)
Transfer specified dump over to specified vdb's controller, making it available for restore operation. The local dump is not deleted and still available for local restore operations. This operation wants a recovery log to be enabled for the vdb (stores dump info, and meaning less otherwize as no restore is possible without a recovery log). It is pointless (and an error) to use this on a non-distributed virtual db.
Parameters:
  dumpName - the name of the dump to copy. Should exist locally, and notremotely.
Parameters:
  remoteControllerName - the remote controller to talk to.
Parameters:
  noCopy - specifies whether or not to actually copy the dump. Default:false. No-copy is a useful option in case of NFS/shared dumps.
throws:
  VirtualDatabaseException - in case of error



updateDumpPath
void updateDumpPath(String dumpName, String newPath) throws VirtualDatabaseException(Code)
Update the path of the dump for a given dumpName.
Parameters:
  dumpName - name of the dump
Parameters:
  newPath - new path for the dump
throws:
  VirtualDatabaseException - if cannot update the path



www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.