[WFLY-3424] Correctly implement the ArtifactFactory to work better with CDI #10297
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
[WFLY-8942] Setup the correct context for @requestScope beans.
This contains two fixes in one commit. It didn't make sense to split the commits as they touch the same files. One would have deleted a file, the other would have added it back.
WFLY-3432
This converts the previously named
WildFlyArtifactFactory
to an MSC service and uses the correct call to theCreationalContext
to clean up the CDI bean rather than JBeret itself attempting to invoke the@PostConstruct
.Due note while the upgrade for JBeret (https://issues.jboss.org/browse/WFLY-9051) isn't required for this change to exist, it will be required for this change to actually work properly.
WFLY-8942
Activates and deactivates the
@RequestScope
context. Typically the request scope is a thread-local. However since batch jobs are ran in new thread(s) the context needs to be activated for all threads.