public void init()

in encryption/src/main/java/org/apache/solr/encryption/EncryptionDirectoryFactory.java [69:92]


  public void init(NamedList<?> args) {
    super.init(args);
    SolrParams params = args.toSolrParams();

    String keyManagerSupplierClass = params.get(PARAM_KEY_MANAGER_SUPPLIER);
    if (keyManagerSupplierClass == null) {
      throw new IllegalArgumentException("Missing " + PARAM_KEY_MANAGER_SUPPLIER + " argument for " + getClass().getName());
    }
    KeyManager.Supplier keyManagerSupplier = coreContainer.getResourceLoader().newInstance(keyManagerSupplierClass,
                                                                                           KeyManager.Supplier.class);
    keyManagerSupplier.init(args);
    keyManager = keyManagerSupplier.getKeyManager();

    String encrypterFactoryClass = params.get(PARAM_ENCRYPTER_FACTORY, CipherAesCtrEncrypter.Factory.class.getName());
    encrypterFactory = coreContainer.getResourceLoader().newInstance(encrypterFactoryClass,
                                                                     AesCtrEncrypterFactory.class);
    if (!encrypterFactory.isSupported()) {
      throw new UnsupportedOperationException(getClass().getName() + " cannot create an encrypterFactory of type "
                                                + encrypterFactory.getClass().getName(),
                                              encrypterFactory.getUnsupportedCause());
    }

    innerFactory = createInnerFactory();
  }