Codota Logo
SentryConfigurationException
Code IndexAdd Codota to your IDE (free)

How to use
SentryConfigurationException
in
org.apache.sentry.core.common

Best Java code snippets using org.apache.sentry.core.common.SentryConfigurationException (Showing top 7 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
DateTime d =
  • Codota Iconnew DateTime()
  • Codota IconDateTimeFormatter formatter;String text;formatter.parseDateTime(text)
  • Codota IconObject instant;new DateTime(instant)
  • Smart code suggestions by Codota
}
origin: apache/incubator-sentry

@Override
public void validatePolicy(boolean strictValidation)
  throws SentryConfigurationException {
 throw new SentryConfigurationException("Not implemented yet");
}
origin: apache/incubator-sentry

private void printConfigErrors(SentryConfigurationException configException)
  throws SentryConfigurationException {
 System.out.println(" *** Found configuration problems *** ");
 for (String errMsg : configException.getConfigErrors()) {
  System.out.println("ERROR: " + errMsg);
 }
 for (String warnMsg : configException.getConfigWarnings()) {
  System.out.println("Warning: " + warnMsg);
 }
 throw configException;
}
origin: apache/incubator-sentry

@Override
public void validatePolicy(boolean strictValidation) throws SentryConfigurationException {
 if (!initialized) {
  throw new IllegalStateException("Backend has not been properly initialized");
 }
 List<String> localConfigErrors = Lists.newArrayList(configErrors);
 List<String> localConfigWarnings = Lists.newArrayList(configWarnings);
 if (strictValidation && !localConfigWarnings.isEmpty() || !localConfigErrors.isEmpty()) {
  localConfigErrors.add("Failed to process global policy file " + resourcePath);
  SentryConfigurationException e = new SentryConfigurationException("");
  e.setConfigErrors(localConfigErrors);
  e.setConfigWarnings(localConfigWarnings);
  throw e;
 }
}
origin: apache/incubator-sentry

 @Override
 public void validate(PrivilegeValidatorContext context) throws SentryConfigurationException {
  String privilege = context.getPrivilege();
  Iterable<IndexerModelAuthorizable> authorizables = parsePrivilege(privilege);
  boolean foundIndexerInAuthorizables = false;

  for(IndexerModelAuthorizable authorizable : authorizables) {
   if(authorizable instanceof Indexer) {
    foundIndexerInAuthorizables = true;
    break;
   }
  }
  if(!foundIndexerInAuthorizables) {
   String msg = "Missing indexer object in " + privilege;
   throw new SentryConfigurationException(msg);
  }
 }
}
origin: apache/incubator-sentry

 @Override
 public void validate(PrivilegeValidatorContext context) throws SentryConfigurationException {
  String privilege = context.getPrivilege();
  Iterable<SearchModelAuthorizable> authorizables = parsePrivilege(privilege);
  boolean foundCollectionInAuthorizables = false;

  for(SearchModelAuthorizable authorizable : authorizables) {
   if(authorizable instanceof Collection) {
    foundCollectionInAuthorizables = true;
    break;
   }
  }
  if(!foundCollectionInAuthorizables) {
   String msg = "Missing collection object in " + privilege;
   throw new SentryConfigurationException(msg);
  }
 }
}
origin: apache/incubator-sentry

 configErrors.add("Failed to read policy file " + resourcePath +
  " Error: " + e.getMessage());
 throw new SentryConfigurationException("Error loading policy file " + resourcePath, e);
} catch (IllegalArgumentException e) {
 configErrors.add("Failed to read policy file " + resourcePath +
  " Error: " + e.getMessage());
 throw new SentryConfigurationException("Error loading policy file " + resourcePath, e);
} else if (!allowPerDatabaseSection) {
 String msg = "Per-db policy file is not expected in this configuration.";
 throw new SentryConfigurationException(msg);
} else {
 for(Map.Entry<String, String> entry : filesSection.entrySet()) {
   if(perDbIni.containsKey(PolicyFileConstants.USERS)) {
    configErrors.add("Per-db policy file cannot contain " + PolicyFileConstants.USERS + " section in " +  perDbPolicy);
    throw new SentryConfigurationException("Per-db policy files cannot contain " + PolicyFileConstants.USERS + " section");
    throw new SentryConfigurationException("Per-db policy files cannot contain " + PolicyFileConstants.DATABASES + " section");
origin: apache/incubator-sentry

throw new SentryConfigurationException("Didn't find a hive-site.xml");
org.apache.sentry.core.commonSentryConfigurationException

Most used methods

  • <init>
  • getConfigErrors
  • getConfigWarnings
  • setConfigErrors
  • setConfigWarnings

Popular in Java

  • Reading from database using SQL prepared statement
  • scheduleAtFixedRate (ScheduledExecutorService)
  • notifyDataSetChanged (ArrayAdapter)
  • requestLocationUpdates (LocationManager)
  • MessageFormat (java.text)
    MessageFormat provides a means to produce concatenated messages in language-neutral way. Use this to
  • BitSet (java.util)
    This class implements a vector of bits that grows as needed. Each component of the bit set has a boo
  • PriorityQueue (java.util)
    An unbounded priority Queue based on a priority heap. The elements of the priority queue are ordered
  • StringTokenizer (java.util)
    The string tokenizer class allows an application to break a string into tokens. The tokenization met
  • Cipher (javax.crypto)
    This class provides access to implementations of cryptographic ciphers for encryption and decryption
  • Loader (org.hibernate.loader)
    Abstract superclass of object loading (and querying) strategies. This class implements useful common
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now