Interface InstanceOperations
public interface InstanceOperations
-
Method Summary
Modifier and TypeMethodDescriptiongetActiveCompactions
(String tserver) List the active compaction running on a tablet servergetActiveScans
(String tserver) List the active scans on tablet server.List the currently active tablet servers participating in the accumulo instancevoid
Throws an exception if a tablet server can not be contacted.void
removeProperty
(String property) Removes a system property from zookeeper.void
setProperty
(String property, String value) Sets an system property in zookeeper.boolean
testClassLoad
(String className, String asTypeName) Test to see if the instance can load the given class as the given type.void
Waits for the tablet balancer to run and return no migrations.
-
Method Details
-
setProperty
Sets an system property in zookeeper. Tablet servers will pull this setting and override the equivalent setting in accumulo-site.xml. Changes can be seen usinggetSystemConfiguration()
.Only some properties can be changed by this method, an IllegalArgumentException will be thrown if a read-only property is set.
- Parameters:
property
- the name of a per-table propertyvalue
- the value to set a per-table property to- Throws:
AccumuloException
- if a general error occursAccumuloSecurityException
- if the user does not have permission
-
removeProperty
Removes a system property from zookeeper. Changes can be seen usinggetSystemConfiguration()
- Parameters:
property
- the name of a per-table property- Throws:
AccumuloException
- if a general error occursAccumuloSecurityException
- if the user does not have permission
-
getSystemConfiguration
- Returns:
- A map of system properties set in zookeeper. If a property is not set in zookeeper, then it will return the value set in accumulo-site.xml on some server. If nothing is set in an accumulo-site.xml file it will return the default value for each property.
- Throws:
AccumuloException
AccumuloSecurityException
-
getSiteConfiguration
- Returns:
- A map of system properties set in accumulo-site.xml on some server. If nothing is set in an accumulo-site.xml file it will return the default value for each property.
- Throws:
AccumuloException
AccumuloSecurityException
-
getTabletServers
List the currently active tablet servers participating in the accumulo instance- Returns:
- A list of currently active tablet servers.
-
getActiveScans
List the active scans on tablet server.- Parameters:
tserver
- The tablet server address should be of the form<ip address>:<port>
- Returns:
- A list of active scans on tablet server.
- Throws:
AccumuloException
AccumuloSecurityException
-
getActiveCompactions
List<ActiveCompaction> getActiveCompactions(String tserver) throws AccumuloException, AccumuloSecurityException List the active compaction running on a tablet server- Parameters:
tserver
- The tablet server address should be of the form<ip address>:<port>
- Returns:
- the list of active compactions
- Throws:
AccumuloException
AccumuloSecurityException
- Since:
- 1.5.0
-
ping
Throws an exception if a tablet server can not be contacted.- Parameters:
tserver
- The tablet server address should be of the form<ip address>:<port>
- Throws:
AccumuloException
- Since:
- 1.5.0
-
testClassLoad
boolean testClassLoad(String className, String asTypeName) throws AccumuloException, AccumuloSecurityException Test to see if the instance can load the given class as the given type. This check does not consider per table classpaths, seeTableOperations.testClassLoad(String, String, String)
- Returns:
- true if the instance can load the given class as the given type, false otherwise
- Throws:
AccumuloException
AccumuloSecurityException
-
waitForBalance
Waits for the tablet balancer to run and return no migrations.- Throws:
AccumuloException
- Since:
- 1.7.0
-