ServerResource extends AbstractBrooklynRestResource implements ServerApi { @Override public String getConfig(String configKey) { if (!Entitlements.isEntitled(mgmt().getEntitlementManager(), Entitlements.SEE_ALL_SERVER_INFO, null)) { throw WebResourceUtils.forbidden("User '%s' is not authorized to perform this operation", Entitlements.getEntitlementContext().user()); } ConfigKey<String> config = ConfigKeys.newStringConfigKey(configKey); return (String) WebResourceUtils.getValueForDisplay(mapper(), mgmt().getConfig().getConfig(config), true, true); }  @Override void reloadBrooklynProperties(); @Override void shutdown(final boolean stopAppsFirst, final boolean forceShutdownOnError,
            String shutdownTimeoutRaw, String requestTimeoutRaw, String delayForHttpReturnRaw,
            Long delayMillis); @Override VersionSummary getVersion(); @Override String getPlaneId(); @Override boolean isUp(); @Override boolean isShuttingDown(); @Override boolean isHealthy(); @Override Map<String,Object> getUpExtended(); @Override String getConfig(String configKey); @Override ManagementNodeState getHighAvailabilityNodeState(); @Override ManagementNodeState setHighAvailabilityNodeState(HighAvailabilityMode mode); @Override Map<String, Object> getHighAvailabilityMetrics(); @Override long getHighAvailabitlityPriority(); @Override long setHighAvailabilityPriority(long priority); @Override HighAvailabilitySummary getHighAvailabilityPlaneStates(); @Override Response clearHighAvailabilityPlaneStates(); @Override String getUser(); @Override Response exportPersistenceData(String preferredOrigin);  }
@Test void testGetConfig() throws Exception { ((ManagementContextInternal)getManagementContext()).getBrooklynProperties().put("foo.bar.baz", "quux"); try { assertEquals(client().path("/server/config/foo.bar.baz").get(String.class), "\"quux\""); } finally { ((ManagementContextInternal)getManagementContext()).getBrooklynProperties().remove("foo.bar.baz"); } }