Tabnine Logo
Constraints.writeConstraint
Code IndexAdd Tabnine to your IDE (free)

How to use
writeConstraint
method
in
org.apache.hadoop.hbase.constraint.Constraints

Best Java code snippets using org.apache.hadoop.hbase.constraint.Constraints.writeConstraint (Showing top 9 results out of 315)

origin: apache/hbase

/**
 * Write the raw constraint and configuration to the descriptor.
 * <p>
 * This method takes care of creating a new configuration based on the passed
 * in configuration and then updating that with enabled and priority of the
 * constraint.
 * <p>
 * When a constraint is added, it is automatically enabled.
 */
private static void addConstraint(HTableDescriptor desc,
  Class<? extends Constraint> clazz, Configuration conf, long priority)
  throws IOException {
 writeConstraint(desc, serializeConstraintClass(clazz),
   configure(conf, true, priority));
}
origin: apache/hbase

/**
 * Change the whether the constraint (if it is already present) is enabled or
 * disabled.
 */
private static void changeConstraintEnabled(HTableDescriptor desc,
  Class<? extends Constraint> clazz, boolean enabled) throws IOException {
 // get the original constraint
 Pair<String, String> entry = getKeyValueForClass(desc, clazz);
 if (entry == null) {
  throw new IllegalArgumentException("Constraint: " + clazz.getName()
    + " is not associated with this table. You can't enable it!");
 }
 // create a new configuration from that conf
 Configuration conf = readConfiguration(entry.getSecond());
 // set that it is enabled
 conf.setBoolean(ENABLED_KEY, enabled);
 // write it back out
 writeConstraint(desc, entry.getFirst(), conf);
}
origin: apache/hbase

writeConstraint(desc, e.getFirst(), conf);
origin: co.cask.hbase/hbase

/**
 * Write the raw constraint and configuration to the descriptor.
 * <p>
 * This method takes care of creating a new configuration based on the passed
 * in configuration and then updating that with enabled and priority of the
 * constraint.
 * <p>
 * When a constraint is added, it is automatically enabled.
 */
private static void addConstraint(HTableDescriptor desc,
  Class<? extends Constraint> clazz, Configuration conf, long priority)
  throws IOException {
 writeConstraint(desc, serializeConstraintClass(clazz),
   configure(conf, true, priority));
}
origin: harbby/presto-connectors

/**
 * Write the raw constraint and configuration to the descriptor.
 * <p>
 * This method takes care of creating a new configuration based on the passed
 * in configuration and then updating that with enabled and priority of the
 * constraint.
 * <p>
 * When a constraint is added, it is automatically enabled.
 */
private static void addConstraint(HTableDescriptor desc,
  Class<? extends Constraint> clazz, Configuration conf, long priority)
  throws IOException {
 writeConstraint(desc, serializeConstraintClass(clazz),
   configure(conf, true, priority));
}
origin: co.cask.hbase/hbase

/**
 * Change the whether the constraint (if it is already present) is enabled or
 * disabled.
 */
private static void changeConstraintEnabled(HTableDescriptor desc,
  Class<? extends Constraint> clazz, boolean enabled) throws IOException {
 // get the original constraint
 Pair<String, String> entry = getKeyValueForClass(desc, clazz);
 if (entry == null) {
  throw new IllegalArgumentException("Constraint: " + clazz.getName()
    + " is not associated with this table. You can't enable it!");
 }
 // create a new configuration from that conf
 Configuration conf = readConfiguration(entry.getSecond());
 // set that it is enabled
 conf.setBoolean(ENABLED_KEY, enabled);
 // write it back out
 writeConstraint(desc, entry.getFirst(), conf);
}
origin: harbby/presto-connectors

/**
 * Change the whether the constraint (if it is already present) is enabled or
 * disabled.
 */
private static void changeConstraintEnabled(HTableDescriptor desc,
  Class<? extends Constraint> clazz, boolean enabled) throws IOException {
 // get the original constraint
 Pair<String, String> entry = getKeyValueForClass(desc, clazz);
 if (entry == null) {
  throw new IllegalArgumentException("Constraint: " + clazz.getName()
    + " is not associated with this table. You can't enable it!");
 }
 // create a new configuration from that conf
 Configuration conf = readConfiguration(entry.getSecond());
 // set that it is enabled
 conf.setBoolean(ENABLED_KEY, enabled);
 // write it back out
 writeConstraint(desc, entry.getFirst(), conf);
}
origin: co.cask.hbase/hbase

writeConstraint(desc, e.getFirst(), conf);
origin: harbby/presto-connectors

writeConstraint(desc, e.getFirst(), conf);
org.apache.hadoop.hbase.constraintConstraintswriteConstraint

Javadoc

Write the given key and associated configuration to the HTableDescriptor

Popular methods of Constraints

  • disable
    Turn off processing constraints for a given table, even if constraints have been turned on or added.
  • getConstraints
  • addConstraint
    Write the raw constraint and configuration to the descriptor. This method takes care of creating a n
  • changeConstraintEnabled
    Change the whether the constraint (if it is already present) is enabled or disabled.
  • configure
    Setup the configuration for a constraint as to whether it is enabled and its priority
  • enable
    Enable constraints on a table. Currently, if you attempt to add a constraint to the table, then Cons
  • getKeyValueForClass
    Get the kv Entry in the descriptor for the specified class
  • getNextPriority
  • readConfiguration
    Read the Configuration stored in the byte stream.
  • serializeConfiguration
    Write the configuration to a String
  • serializeConstraintClass
    Just write the class to a String representation of the class as a key for the HTableDescriptor
  • updateLatestPriority
  • serializeConstraintClass,
  • updateLatestPriority,
  • add,
  • disableConstraint,
  • enabled,
  • has,
  • remove,
  • setConfiguration

Popular in Java

  • Making http requests using okhttp
  • findViewById (Activity)
  • setRequestProperty (URLConnection)
  • onCreateOptionsMenu (Activity)
  • File (java.io)
    An "abstract" representation of a file system entity identified by a pathname. The pathname may be a
  • BigInteger (java.math)
    An immutable arbitrary-precision signed integer.FAST CRYPTOGRAPHY This implementation is efficient f
  • SimpleDateFormat (java.text)
    Formats and parses dates in a locale-sensitive manner. Formatting turns a Date into a String, and pa
  • Hashtable (java.util)
    A plug-in replacement for JDK1.5 java.util.Hashtable. This version is based on org.cliffc.high_scale
  • TreeSet (java.util)
    TreeSet is an implementation of SortedSet. All optional operations (adding and removing) are support
  • Executors (java.util.concurrent)
    Factory and utility methods for Executor, ExecutorService, ScheduledExecutorService, ThreadFactory,
  • CodeWhisperer alternatives
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now