public function loadFiles(string $path, $extension = 'yml')
    {
        $finder = new Finder();
        $finder->in($path)->name('*.'.$extension)->files();
        $loader = new YamlFileLoader($this->container, new FileLocator($path));
        foreach ($finder as $file) {
            $loader->load($file->getFilename());
        }
    }
public function loadFiles(string $path, $extension = 'yml')
    {
        $finder = new Finder();
        $finder->in($path)->name('*.'.$extension)->files();
        $loader = new YamlFileLoader($this->container, new FileLocator($path));
        foreach ($finder as $file) {
            $loader->load($file->getFilename());
        }
    }
@param string $path
@param string $extension

@throws \Exception