Hi @ayoub_tabai
Below are potential causes and solutions, including a recommended deployment process that involves using both mvn clean install -PautoInstallPackage and mvn clean install -PautoInstallBundle.
Potential Causes and Solutions
Bundles and Components Not Active
Check the OSGi console (http://localhost:4502/system/console/bundles) to ensure all bundles are active. Activate any bundles in the "Installed" or "Resolved" state.
Sling Resource Resolver Cache
Restart the Sling Resource Resolver via the Felix console (http://localhost:4502/system/console/resolver).
Log Files
Review the AEM error logs (error.log) and OSGi logs (/crx-quickstart/logs). Look for errors or warnings that indicate missing dependencies or incorrect configurations.
Recommended Deployment Process
To avoid issues and ensure a smooth deployment, it is recommended to first deploy your content package and then deploy the OSGi bundles separately. This approach can help isolate and troubleshoot potential issues more effectively.
Step 1: Deploy the Content Package
Use mvn clean install -PautoInstallPackage to deploy the entire content package, which includes code, configurations, and content.
Step 2: Deploy the OSGi Bundles
After deploying the content package, use mvn clean install -PautoInstallBundle to deploy only the OSGi bundles. This ensures that the Java code is correctly installed and activated.
Hope this Helps.