Search in sources :

Example 1 with BootstrapFileCryptoKeyProvider

use of org.apache.nifi.registry.security.crypto.BootstrapFileCryptoKeyProvider in project nifi-registry by apache.

the class NiFiRegistry method main.

/**
 * Main entry point of the application.
 *
 * @param args things which are ignored
 */
public static void main(String[] args) {
    LOGGER.info("Launching NiFi Registry...");
    final CryptoKeyProvider masterKeyProvider;
    final NiFiRegistryProperties properties;
    try {
        masterKeyProvider = new BootstrapFileCryptoKeyProvider(REGISTRY_BOOTSTRAP_FILE_LOCATION);
        LOGGER.info("Read property protection key from {}", REGISTRY_BOOTSTRAP_FILE_LOCATION);
        properties = initializeProperties(masterKeyProvider);
    } catch (final IllegalArgumentException iae) {
        throw new RuntimeException("Unable to load properties: " + iae, iae);
    }
    try {
        new NiFiRegistry(properties, masterKeyProvider);
    } catch (final Throwable t) {
        LOGGER.error("Failure to launch NiFi Registry due to " + t, t);
    }
}
Also used : CryptoKeyProvider(org.apache.nifi.registry.security.crypto.CryptoKeyProvider) BootstrapFileCryptoKeyProvider(org.apache.nifi.registry.security.crypto.BootstrapFileCryptoKeyProvider) BootstrapFileCryptoKeyProvider(org.apache.nifi.registry.security.crypto.BootstrapFileCryptoKeyProvider) NiFiRegistryProperties(org.apache.nifi.registry.properties.NiFiRegistryProperties)

Aggregations

NiFiRegistryProperties (org.apache.nifi.registry.properties.NiFiRegistryProperties)1 BootstrapFileCryptoKeyProvider (org.apache.nifi.registry.security.crypto.BootstrapFileCryptoKeyProvider)1 CryptoKeyProvider (org.apache.nifi.registry.security.crypto.CryptoKeyProvider)1