def _merge_extra_settings()

in curator/actions/shrink.py [0:0]


    def _merge_extra_settings(self, extra_settings):
        self.loggit.debug('Adding extra_settings to shrink body: %s', extra_settings)
        # Pop these here, otherwise we could overwrite our default number of
        # shards and replicas
        if 'settings' in extra_settings:
            settings = extra_settings.pop('settings')
            try:
                self.settings.update(settings)
            except Exception as exc:
                raise ConfigurationError(
                    f"Unable to apply extra settings \"{{'settings':settings}}\" "
                    f"to shrink body. Exception: {exc}"
                ) from exc
        if extra_settings:
            try:  # Apply any remaining keys, should there be any.
                self.settings.update(extra_settings)
            except Exception as exc:
                raise ConfigurationError(
                    f'Unable to apply extra settings "{extra_settings}" '
                    f'to shrink body. Exception: {exc}'
                ) from exc