From 3bf687e7267df8b454eea085946f7b523f562660 Mon Sep 17 00:00:00 2001 From: uboness Date: Wed, 21 Jan 2015 13:44:54 +0100 Subject: [PATCH] [Cleanup] Removed redundant Inject annotations Also removed unused constructors Original commit: elastic/x-pack-elasticsearch@1d1d2dcbade11c926f770c2edf6a2079368ed525 --- .../active_directory/ActiveDirectoryConnectionFactory.java | 2 -- .../shield/authc/active_directory/ActiveDirectoryRealm.java | 1 - .../shield/authc/ldap/LdapConnectionFactory.java | 2 -- .../shield/authc/ldap/LdapGroupToRoleMapper.java | 5 ----- .../java/org/elasticsearch/shield/authc/ldap/LdapRealm.java | 1 - 5 files changed, 11 deletions(-) diff --git a/src/main/java/org/elasticsearch/shield/authc/active_directory/ActiveDirectoryConnectionFactory.java b/src/main/java/org/elasticsearch/shield/authc/active_directory/ActiveDirectoryConnectionFactory.java index 611707369b0..b6bea827dbe 100644 --- a/src/main/java/org/elasticsearch/shield/authc/active_directory/ActiveDirectoryConnectionFactory.java +++ b/src/main/java/org/elasticsearch/shield/authc/active_directory/ActiveDirectoryConnectionFactory.java @@ -7,7 +7,6 @@ package org.elasticsearch.shield.authc.active_directory; import org.elasticsearch.common.Strings; import org.elasticsearch.common.collect.ImmutableMap; -import org.elasticsearch.common.inject.Inject; import org.elasticsearch.common.settings.Settings; import org.elasticsearch.common.unit.TimeValue; import org.elasticsearch.shield.ShieldSettingsException; @@ -51,7 +50,6 @@ public class ActiveDirectoryConnectionFactory extends ConnectionFactory { private final AbstractLdapConnection.GroupsResolver groupResolver; private final TimeValue timeout; - @Inject public LdapConnectionFactory(RealmConfig config) { super(LdapConnection.class, config); Settings settings = config.settings(); diff --git a/src/main/java/org/elasticsearch/shield/authc/ldap/LdapGroupToRoleMapper.java b/src/main/java/org/elasticsearch/shield/authc/ldap/LdapGroupToRoleMapper.java index 45faae91f7b..52109d2c201 100644 --- a/src/main/java/org/elasticsearch/shield/authc/ldap/LdapGroupToRoleMapper.java +++ b/src/main/java/org/elasticsearch/shield/authc/ldap/LdapGroupToRoleMapper.java @@ -6,7 +6,6 @@ package org.elasticsearch.shield.authc.ldap; import org.elasticsearch.shield.authc.RealmConfig; -import org.elasticsearch.shield.authc.support.RefreshListener; import org.elasticsearch.shield.authc.support.ldap.AbstractGroupToRoleMapper; import org.elasticsearch.watcher.ResourceWatcherService; @@ -15,10 +14,6 @@ import org.elasticsearch.watcher.ResourceWatcherService; */ public class LdapGroupToRoleMapper extends AbstractGroupToRoleMapper { - public LdapGroupToRoleMapper(RealmConfig config, ResourceWatcherService watcherService, RefreshListener listener) { - super(LdapRealm.TYPE, config, watcherService, listener); - } - public LdapGroupToRoleMapper(RealmConfig config, ResourceWatcherService watcherService) { super(LdapRealm.TYPE, config, watcherService, null); } diff --git a/src/main/java/org/elasticsearch/shield/authc/ldap/LdapRealm.java b/src/main/java/org/elasticsearch/shield/authc/ldap/LdapRealm.java index f5e22156ab1..8d227b84c82 100644 --- a/src/main/java/org/elasticsearch/shield/authc/ldap/LdapRealm.java +++ b/src/main/java/org/elasticsearch/shield/authc/ldap/LdapRealm.java @@ -18,7 +18,6 @@ public class LdapRealm extends AbstractLdapRealm { public static final String TYPE = "ldap"; - @Inject public LdapRealm(RealmConfig config, LdapConnectionFactory ldap, LdapGroupToRoleMapper roleMapper) { super(TYPE, config, ldap, roleMapper); }