@Test public void testSecuritySensitiveConfig() { Map<String, String> properties = new TreeMap<>(); properties.put("value", "some value"); inspect(properties, null, null, null, binder -> bindConfig(binder).bind(SetterSensitiveClass.class)) .component("ConfigurationMetadataTest$SetterSensitiveClass") .value("Value", "value", "[REDACTED]", "[REDACTED]", "description") .end(); }
public SortedSet<ConfigRecord<?>> inspect(ConfigurationFactory configurationFactory) { ImmutableSortedSet.Builder<ConfigRecord<?>> builder = ImmutableSortedSet.naturalOrder(); for (ConfigurationIdentity<?> configurationIdentity : configurationFactory.getRegisteredConfigs()) { builder.add(ConfigRecord.createConfigRecord(configurationFactory, configurationIdentity)); } return builder.build(); }
ConfigurationInspector { public SortedSet<ConfigRecord<?>> inspect(ConfigurationFactory configurationFactory) { ImmutableSortedSet.Builder<ConfigRecord<?>> builder = ImmutableSortedSet.naturalOrder(); for (ConfigurationIdentity<?> configurationIdentity : configurationFactory.getRegisteredConfigs()) { builder.add(ConfigRecord.createConfigRecord(configurationFactory, configurationIdentity)); } return builder.build(); } }
ConfigurationInspector { public SortedSet<ConfigRecord<?>> inspect(ConfigurationFactory configurationFactory) { ImmutableSortedSet.Builder<ConfigRecord<?>> builder = ImmutableSortedSet.naturalOrder(); for (ConfigurationIdentity<?> configurationIdentity : configurationFactory.getRegisteredConfigs()) { builder.add(ConfigRecord.createConfigRecord(configurationFactory, configurationIdentity)); } return builder.build(); }  }
ConfigurationInspector { public SortedSet<ConfigRecord<?>> inspect(ConfigurationFactory configurationFactory) { ImmutableSortedSet.Builder<ConfigRecord<?>> builder = ImmutableSortedSet.naturalOrder(); for (ConfigurationIdentity<?> configurationIdentity : configurationFactory.getRegisteredConfigs()) { builder.add(ConfigRecord.createConfigRecord(configurationFactory, configurationIdentity)); } return builder.build(); }  SortedSet<ConfigRecord<?>> inspect(ConfigurationFactory configurationFactory); }
ConfigurationInspector { public SortedSet<ConfigRecord<?>> inspect(ConfigurationFactory configurationFactory) { ImmutableSortedSet.Builder<ConfigRecord<?>> builder = ImmutableSortedSet.naturalOrder(); for (ConfigurationIdentity<?> configurationIdentity : configurationFactory.getRegisteredConfigs()) { builder.add(ConfigRecord.createConfigRecord(configurationFactory, configurationIdentity)); } return builder.build(); }  SortedSet<ConfigRecord<?>> inspect(ConfigurationFactory configurationFactory);  }