mirror of
https://github.com/elastic/elasticsearch.git
synced 2025-04-24 15:17:30 -04:00
Introduce deprecation categories (#68061)
Sort-of backport of #67443. Closes #64824. Introduce the concept of categories to deprecation logging. Every location where we log a deprecation message must now include a deprecation category.
This commit is contained in:
parent
6c8ed22e95
commit
1c5b89c89d
172 changed files with 612 additions and 313 deletions
|
@ -26,6 +26,7 @@ import com.amazonaws.auth.BasicAWSCredentials;
|
|||
import com.amazonaws.auth.BasicSessionCredentials;
|
||||
import org.apache.logging.log4j.LogManager;
|
||||
import org.apache.logging.log4j.Logger;
|
||||
import org.elasticsearch.common.logging.DeprecationCategory;
|
||||
import org.elasticsearch.common.logging.DeprecationLogger;
|
||||
import org.elasticsearch.common.settings.SecureSetting;
|
||||
import org.elasticsearch.common.settings.SecureString;
|
||||
|
@ -135,12 +136,12 @@ final class Ec2ClientSettings {
|
|||
return null;
|
||||
} else {
|
||||
if (key.length() == 0) {
|
||||
deprecationLogger.deprecate("ec2_invalid_settings",
|
||||
deprecationLogger.deprecate(DeprecationCategory.SETTINGS, "ec2_invalid_settings",
|
||||
"Setting [{}] is set but [{}] is not, which will be unsupported in future",
|
||||
SECRET_KEY_SETTING.getKey(), ACCESS_KEY_SETTING.getKey());
|
||||
}
|
||||
if (secret.length() == 0) {
|
||||
deprecationLogger.deprecate("ec2_invalid_settings",
|
||||
deprecationLogger.deprecate(DeprecationCategory.SETTINGS, "ec2_invalid_settings",
|
||||
"Setting [{}] is set but [{}] is not, which will be unsupported in future",
|
||||
ACCESS_KEY_SETTING.getKey(), SECRET_KEY_SETTING.getKey());
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue