Search in sources :

Example 1 with ConfigUpdateEntry

use of com.google.gerrit.server.config.ConfigUpdatedEvent.ConfigUpdateEntry in project gerrit by GerritCodeReview.

the class ReloadConfig method run.

@Override
protected void run() throws Failure {
    enableGracefulStop();
    Multimap<UpdateResult, ConfigUpdateEntry> updates = gerritServerConfigReloader.reloadConfig();
    if (updates.isEmpty()) {
        stdout.println("No config entries updated!");
        return;
    }
    // Print out UpdateResult.{ACCEPTED|REJECTED} entries grouped by their type
    for (UpdateResult result : updates.keySet()) {
        stdout.println(result.toString() + " configuration changes:");
        updates.get(result).forEach(cfgEntry -> stdout.println(cfgEntry.toString()));
    }
}
Also used : ConfigUpdateEntry(com.google.gerrit.server.config.ConfigUpdatedEvent.ConfigUpdateEntry) UpdateResult(com.google.gerrit.server.config.ConfigUpdatedEvent.UpdateResult)

Aggregations

ConfigUpdateEntry (com.google.gerrit.server.config.ConfigUpdatedEvent.ConfigUpdateEntry)1 UpdateResult (com.google.gerrit.server.config.ConfigUpdatedEvent.UpdateResult)1