INNER CODE UNIT · Java

setProperties

dadoonet/spring-elasticsearch · src/main/java/fr/pilato/spring/elasticsearch/ElasticsearchClientFactoryBean.java:221

    public void setProperties(Properties properties) {
        String securedUser = properties.getProperty(XPACK_USER, null);
        if (securedUser != null) {
            logger.warn("Usage of xpack.security.user property has been deprecated. " +
                    "You should now use username and password factory settings.");

            // We split the username and the password
            String[] split = securedUser.split(":");
            if (split.length < 2) {
                throw new IllegalArgumentException(XPACK_USER + " must have the form username:password");
            }
            username = split[0];
            password = split[1];
        }
    }

    /**
     * Set to true if you want to force reinit the indices. This will remove all existing indices managed by the factory.

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…