Update configuration from config service

@param commit commit hash, will be empty if configuration deleted
@param paths collection of paths updated
966856
@Override
    public void updateConfigurations(String commit, Collection<String> paths) {
        Map<String, Configuration> configurationsMap = getConfigurationMap(commit, paths);
        paths.forEach(path -> notifyUpdated(configurationsMap
            .getOrDefault(path, new Configuration(path, null))));
    }
231963
public static void modifyHavePathSelfConfig(Map<IConfigKeyWithPath, String> modifyConfig) throws IOException {
        Map<String, Map<IConfigKeyWithPath, String>> configPaths =
                new HashMap<String, Map<IConfigKeyWithPath, String>>();
        for (IConfigKeyWithPath configKeyWithPath : modifyConfig.keySet()) {
            String configAbsoluteClassPath = configKeyWithPath.getConfigPath();
            Map<IConfigKeyWithPath, String> configKeys = configPaths.get(configAbsoluteClassPath);
            if (configKeys == null) {
                configKeys = new HashMap<IConfigKeyWithPath, String>();
                configPaths.put(configAbsoluteClassPath, configKeys);
            }
            configKeys.put(configKeyWithPath, modifyConfig.get(configKeyWithPath));
        }
        for (String configAbsoluteClassPath : configPaths.keySet()) {
            OneProperties configs = otherConfigs.get(configAbsoluteClassPath);
            if (configs == null) {
                return;
            }
            configs.modifyConfig(configPaths.get(configAbsoluteClassPath));
        }
    }
416591
public static void updateTmpDirectoriesInConfiguration(
			Configuration configuration,
			@Nullable String defaultDirs) {
		if (configuration.contains(CoreOptions.TMP_DIRS)) {
			LOG.info("Overriding Fink's temporary file directories with those " +
				"specified in the Flink config: {}", configuration.getValue(CoreOptions.TMP_DIRS));
		} else if (defaultDirs != null) {
			LOG.info("Setting directories for temporary files to: {}", defaultDirs);
			configuration.setString(CoreOptions.TMP_DIRS, defaultDirs);
			configuration.setBoolean(USE_LOCAL_DEFAULT_TMP_DIRS, true);
		}
	}
811536
public ConfigurationRecord updateConfiguration (final String key, final ConfigField[] updates)
        throws ServiceException
    {
        requireAdminUser();

        final ServletWaiter<ConfigurationRecord> waiter =
            new ServletWaiter<ConfigurationRecord>("updateConfiguration");

        _omgr.postRunnable(new Runnable() {
            public void run () {
                DObject object = _confReg.getObject(key);
                object.startTransaction();

                int updateCount = 0;
                for (ConfigField update : updates) {
                    object.changeAttribute(update.name, update.type.toValue(update.valStr));
                    updateCount ++;
                }
                object.commitTransaction();

                ConfigurationRecord record = buildRecord(key);
                record.updates = updateCount;
                waiter.requestCompleted(record);
            }
        });

        return waiter.waitForResult();
    }
269331
def commit_update():
    
    unused = _find_unused_partition()
    new = _switch_partition()
    if new != unused:
        msg = f"Bad switch: switched to {new} when {unused} was unused"
        LOG.error(msg)
        raise RuntimeError(msg)
    else:
        LOG.info(f'commit_update: committed to booting {new}')
668160
public void commitStaged(SuggestionStage staging) {
    if (this.deletes == null) {
      this.deletes = new HashMap<>(staging.deletes.size());
    }
    staging.commitTo(deletes);
  }
1286851
def commit_config(self):
        """"""
        commands = []
        commands.append('copy startup-config flash:rollback-0')
        commands.append('configure session {}'.format(self.config_session))
        commands.append('commit')
        commands.append('write memory')

        self.device.run_commands(commands)
        self.config_session = None
147294
public void setConfigurationProperties(java.util.Collection<SdkConfigurationProperty> configurationProperties) {
        if (configurationProperties == null) {
            this.configurationProperties = null;
            return;
        }

        this.configurationProperties = new java.util.ArrayList<SdkConfigurationProperty>(configurationProperties);
    }
241203
public void addConfigurations(Configuration... configurations) {
		Assert.notNull(configurations, "Configurations must not be null");
		this.configurations.addAll(Arrays.asList(configurations));
	}
128681
public function updateCommit(Commit $commit)
    {
        $stmt = $this->db->prepare('UPDATE `commit` SET status = :status, output = :output, build_date = :current_date WHERE slug = :slug AND sha = :sha');
        $stmt->bindValue(':slug', $commit->getProject()->getSlug(), \PDO::PARAM_STR);
        $stmt->bindValue(':sha', $commit->getSha(), \PDO::PARAM_STR);
        $stmt->bindValue(':status', $commit->getStatusCode(), \PDO::PARAM_STR);
        $stmt->bindValue(':output', $commit->getOutput(), \PDO::PARAM_STR);
        $stmt->bindValue(':current_date', date('Y-m-d H:i:s'), \PDO::PARAM_STR);

        if (false === $stmt->execute()) {
            // @codeCoverageIgnoreStart
            throw new \RuntimeException(sprintf('Unable to save build "%s@%s".', $commit->getProject()->getName(), $commit->getSha()));
            // @codeCoverageIgnoreEnd
        }
    }
569411
public void updateLobUsage(boolean commit) {

        if (!hasLobOps) {
            return;
        }

        hasLobOps = false;

        if (commit) {
            for (int i = 0; i < createdLobs.size(); i++) {
                long lobID = createdLobs.get(i);
                int  delta = lobUsageCount.get(lobID, 0);

                if (delta == 1) {
                    lobUsageCount.remove(lobID);
                    createdLobs.remove(i);

                    i--;
                } else if (!session.isBatch) {
                    database.lobManager.adjustUsageCount(lobID, delta - 1);
                    lobUsageCount.remove(lobID);
                    createdLobs.remove(i);

                    i--;
                }
            }

            if (!lobUsageCount.isEmpty()) {
                Iterator it = lobUsageCount.keySet().iterator();

                while (it.hasNext()) {
                    long lobID = it.nextLong();
                    int  delta = lobUsageCount.get(lobID);

                    database.lobManager.adjustUsageCount(lobID, delta - 1);
                }

                lobUsageCount.clear();
            }

            return;
        } else {
            for (int i = 0; i < createdLobs.size(); i++) {
                long lobID = createdLobs.get(i);

                database.lobManager.deleteLob(lobID);
            }

            createdLobs.clear();
            lobUsageCount.clear();

            return;
        }
    }
1316791
public function updateFiles(string $commit, array $files)
    {
        $path = $this->buildFilesPath($commit);

        $builder = new MultipartStreamBuilder();

        foreach ($files as $file) {
            $builder->addResource($file->getName(), $file->getResource(), $file->getOptions());
        }

        $headers = ['Content-Type' => sprintf('multipart/form-data; boundary="%s"', $builder->getBoundary())];

        return $this->postRaw($path, $builder->build(), $headers);
    }
1317310
function updateXCConfigs(configItems, platformPath){
        xcconfigs.forEach(function(fileName){
            updateXCConfig(platformPath, fileName, configItems);
        });
    }
1260915
function updateConfigs (args, newVersion) {
  const dotgit = DotGitignore()
  Bump.pkgFiles.concat(Bump.lockFiles).forEach(function (filename) {
    let configPath = path.resolve(process.cwd(), filename)
    try {
      if (dotgit.ignore(configPath)) return
      let stat = fs.lstatSync(configPath)
      if (stat.isFile()) {
        let data = fs.readFileSync(configPath, 'utf8')
        let indent = detectIndent(data).indent
        let newline = detectNewline(data)
        let config = JSON.parse(data)
        checkpoint(args, 'bumping version in ' + filename + ' from %s to %s', [config.version, newVersion])
        config.version = newVersion
        writeFile(args, configPath, stringifyPackage(config, indent, newline))
        // flag any config files that we modify the version # for
        // as having been updated.
        configsToUpdate[filename] = true
      }
    } catch (err) {
      if (err.code !== 'ENOENT') console.warn(err.message)
    }
  })
}
268614
func (c *ConfigStorage) Commit() error {
	if !c.set {
		return nil
	}

	cfg, err := c.temporal.Config()
	if err != nil {
		return err
	}

	return c.ConfigStorer.SetConfig(cfg)
}
560713
public void setConfigurationSets(java.util.Collection<ConfigurationSet> configurationSets) {
        if (configurationSets == null) {
            this.configurationSets = null;
            return;
        }

        this.configurationSets = new com.amazonaws.internal.SdkInternalList<ConfigurationSet>(configurationSets);
    }
757302
public void updateConfigAll(AbstractInterfaceConfig config, String overridePath, List<ChildData> currentData)
        throws UnsupportedEncodingException {
        if (CommonUtils.isEmpty(currentData)) {
            if (LOGGER.isInfoEnabled(config.getAppName())) {
                LOGGER.infoWithApp(config.getAppName(), "Receive updateAll data is null");
            }
        } else {
            if (LOGGER.isInfoEnabled(config.getAppName())) {
                for (ChildData data : currentData) {
                    LOGGER.infoWithApp(config.getAppName(),
                        "Receive updateAll data: path=[" + data.getPath() + "], data=[" +
                            StringSerializer.decode(data.getData()) + "]" + ", stat=[" + data.getStat() + "]");
                }
            }
            List<ConfigListener> configListeners = configListenerMap.get(config);
            if (CommonUtils.isNotEmpty(configListeners)) {
                List<Map<String, String>> attributes = ZookeeperRegistryHelper.convertOverrideToAttributes(
                    config, overridePath, currentData);
                for (ConfigListener listener : configListeners) {
                    for (Map<String, String> attribute : attributes) {
                        listener.attrUpdated(attribute);
                    }
                }
            }
        }
    }