def validate(self):
        """ Validate the contents of the configuration file. Will return None if validation is successful or
        raise an error if not.
        """
        if not isinstance(self._data, dict):
            raise TypeError('freight forwarder configuration file must be a dict.')

        current_log_level = logger.get_level()

        if self._verbose:
            logger.set_level('DEBUG')
        else:
            logger.set_level('ERROR')

        logger.info('Starting configuration validation', extra={"formatter": 'config-start'})

        # copy config dict to allow config data to stay in its original state.
        config_data = self._data.copy()

        try:
            self._walk_tree(config_data, ROOT_SCHEME)
        except ConfigValidationException as e:
            e.log_error()
            raise

        logger.info("Config validation passed.", extra={'formatter': 'config-success'})

        logger.set_level(current_log_level)