- Can I use SonataMediaExtendedBundle directly in Laravel, or is it only for Symfony?
- This bundle is designed for Symfony, not Laravel. Laravel projects using media management typically rely on alternatives like VichUploaderBundle, Spatie Media Library, or custom solutions. If you’re using Symfony within Laravel (e.g., via Lumen or Symfony integration), ensure compatibility with Symfony 3.x–5.x.
- What versions of SonataMediaBundle does this bundle support, and will it work with v5+?
- The bundle explicitly supports SonataMediaBundle v2.3, 3.0, and 4.0. There’s no evidence it works with v5+, and the lack of updates since 2021 suggests it may break with newer versions. Test thoroughly if upgrading SonataMediaBundle.
- How do I install this bundle in a Symfony project with existing SonataMediaBundle?
- Run `composer require anacona16/sonata-media-extended-bundle`, then add the bundle to `config/bundles.php`. Configure it in `sonata_media.yaml` by extending existing providers, formats, or Twig extensions. No database migrations are required unless you add custom providers with new schemas.
- What specific gaps in SonataMediaBundle does this bundle fill? Are there alternatives?
- The bundle’s purpose isn’t clearly documented, but it likely adds custom providers (e.g., cloud storage), new media formats (e.g., WebP), or Twig extensions. Alternatives include forking SonataMediaBundle, using VichUploaderBundle, or leveraging Sonata’s built-in extensibility via services for custom providers.
- Is this bundle actively maintained? What are the risks of using it in production?
- The bundle hasn’t been updated since December 2021, raising risks like compatibility issues with newer Symfony or SonataMediaBundle versions. Security vulnerabilities in dependencies (e.g., Symfony components) may also go unpatched. Use at your own risk or fork it for maintenance.
- Does this bundle add runtime overhead or require database changes?
- The bundle itself shouldn’t add significant runtime overhead, but custom providers (e.g., cloud storage) may introduce latency. No database schema changes are documented, but providers like AWS S3 or Cloudinary could require additional tables or configurations.
- How do I configure custom media providers or formats with this bundle?
- Extend the `sonata_media.providers` or `sonata_media.formats` sections in `config/packages/sonata_media.yaml`. For example, add a custom provider under `providers` with the full class name (e.g., `SonataMediaExtendedBundle:Provider:CustomProvider`). Refer to SonataMediaBundle’s documentation for provider structure.
- Will this bundle work with Symfony 6.x or PHP 8.1+?
- No, the bundle is untested with Symfony 6.x or PHP 8.1+. It likely targets PHP 7.2–8.0 based on SonataMediaBundle’s support. If you’re on newer versions, consider alternatives like VichUploaderBundle or API Platform, which have better modern support.
- Are there conflicts with other Sonata bundles like SonataAdminBundle?
- No conflicts are documented, but since the bundle extends SonataMediaBundle, ensure your `bundles.php` and configuration don’t duplicate or override settings. Test thoroughly if using multiple Sonata bundles to avoid namespace or service container clashes.
- How can I test this bundle before deploying to production?
- Since there are no tests or CI/CD pipelines, manually test custom providers, formats, and Twig extensions in a staging environment. Use Symfony’s debug toolbar to check for errors, and verify media uploads, thumbnails, and metadata handling match your requirements. Backup your database before testing.