Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix (Core): Changed job manager initialization to the InitServlet and processors discovery using CDI #30898

Conversation

jgambarios
Copy link
Contributor

@jgambarios jgambarios commented Dec 9, 2024

This pull request introduces several changes to improve the discovery and registration of JobProcessor implementations using CDI (Contexts and Dependency Injection).
The key changes include the addition of a new class for discovering job processors, modifications to the job processor factory to utilize CDI, and updates to the job queue manager to register discovered processors automatically also, the initialization of the Job Manager it is now done in the InitServlet.

Improvements to Job Processor Discovery and Registration:

Removal of Deprecated Scanner:

Updates to Job Processor Implementations:

  • Added @Dependent scope to various job processor implementations to ensure they are correctly managed by CDI:
    • FailSuccessJob
    • ImportContentletsProcessor [1] [2]
    • LargeFileReader

These changes enhance the flexibility and reliability of job processor discovery and instantiation in the system, leveraging CDI to manage dependencies and lifecycle.

This PR fixes: #30545

…hanged the processors discovery from Jandex to CDI.
…Migrate-JobProcessor-Discovery-from-Jandex-to-CDI

# Conflicts:
#	dotCMS/src/main/java/com/dotcms/rest/api/v1/content/dotimport/ContentImportHelper.java
…Migrate-JobProcessor-Discovery-from-Jandex-to-CDI

# Conflicts:
#	dotCMS/src/main/java/com/dotcms/rest/api/v1/content/dotimport/ContentImportHelper.java
@jgambarios jgambarios marked this pull request as ready for review December 10, 2024 15:32
@fabrizzio-dotCMS fabrizzio-dotCMS added this pull request to the merge queue Dec 10, 2024
Merged via the queue into main with commit 01d2b24 Dec 10, 2024
36 checks passed
@fabrizzio-dotCMS fabrizzio-dotCMS deleted the issue-30545-Refactor-Migrate-JobProcessor-Discovery-from-Jandex-to-CDI branch December 10, 2024 18:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Refactor: Migrate JobProcessor Discovery from Jandex to CDI
4 participants