use of com.zimbra.soap.admin.message.ReloadLocalConfigResponse in project zm-mailbox by Zimbra.
the class ReloadLocalConfig method handle.
@Override
public Element handle(Element request, Map<String, Object> context) throws ServiceException {
try {
LC.reload();
} catch (DocumentException e) {
ZimbraLog.misc.error("Failed to reload LocalConfig", e);
throw AdminServiceException.FAILURE("Failed to reload LocalConfig", e);
} catch (ConfigException e) {
ZimbraLog.misc.error("Failed to reload LocalConfig", e);
throw AdminServiceException.FAILURE("Failed to reload LocalConfig", e);
}
ZimbraLog.misc.info("LocalConfig reloaded");
reloadLCOnAllImapDaemons();
ZimbraSoapContext zsc = getZimbraSoapContext(context);
return zsc.jaxbToElement(new ReloadLocalConfigResponse());
}
use of com.zimbra.soap.admin.message.ReloadLocalConfigResponse in project zm-mailbox by Zimbra.
the class TestUtil method setLCValue.
protected static void setLCValue(KnownKey key, String newValue) throws DocumentException, ConfigException, IOException, ServiceException {
LocalConfig lc = new LocalConfig(null);
if (newValue == null) {
lc.remove(key.key());
} else {
lc.set(key.key(), newValue);
}
lc.save();
SoapProvisioning prov = TestUtil.newSoapProvisioning();
ReloadLocalConfigRequest req = new ReloadLocalConfigRequest();
ReloadLocalConfigResponse resp = prov.invokeJaxb(req);
assertNotNull("ReloadLocalConfigResponse", resp);
}
use of com.zimbra.soap.admin.message.ReloadLocalConfigResponse in project zm-mailbox by Zimbra.
the class SoapTest method modifyLocalconfigAndReload.
static void modifyLocalconfigAndReload(SoapTransport transport, KnownKey key, String value) throws Exception {
LocalconfigTestUtil.modifyLocalConfig(key, value);
// reload LC on server
ReloadLocalConfigRequest req = new ReloadLocalConfigRequest();
ReloadLocalConfigResponse resp = invokeJaxb(transport, req);
}
Aggregations