diff options
author | Henning Baldersheim <balder@yahoo-inc.com> | 2022-06-24 14:21:59 +0200 |
---|---|---|
committer | Henning Baldersheim <balder@yahoo-inc.com> | 2022-06-24 14:21:59 +0200 |
commit | e6a4d0a49ec3f06470753e71a855917fc1c316b9 (patch) | |
tree | ed070ad9d0756f3d4ba08c4840c8f17ec0ae588a | |
parent | d2d5867ec560c192da03bf63326dfb0fb326643a (diff) |
Use already defined strings
-rw-r--r-- | container-search/src/main/java/com/yahoo/search/query/profile/QueryProfileProperties.java | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/container-search/src/main/java/com/yahoo/search/query/profile/QueryProfileProperties.java b/container-search/src/main/java/com/yahoo/search/query/profile/QueryProfileProperties.java index c821f22bc49..3f9df4d9955 100644 --- a/container-search/src/main/java/com/yahoo/search/query/profile/QueryProfileProperties.java +++ b/container-search/src/main/java/com/yahoo/search/query/profile/QueryProfileProperties.java @@ -303,9 +303,9 @@ public class QueryProfileProperties extends Properties { if (context.containsKey(ENVIRONMENT) && context.containsKey(REGION) && context.containsKey(INSTANCE)) return context; Map<String, String> contextWithZoneInfo = new HashMap<>(context); - contextWithZoneInfo.putIfAbsent("environment", zoneInfo.zone().environment().name()); - contextWithZoneInfo.putIfAbsent("region", zoneInfo.zone().region()); - contextWithZoneInfo.putIfAbsent("instance", zoneInfo.application().instance()); + contextWithZoneInfo.putIfAbsent(ENVIRONMENT, zoneInfo.zone().environment().name()); + contextWithZoneInfo.putIfAbsent(REGION, zoneInfo.zone().region()); + contextWithZoneInfo.putIfAbsent(INSTANCE, zoneInfo.application().instance()); return Collections.unmodifiableMap(contextWithZoneInfo); } |