ExamGecko
Question list
Search
Search

List of questions

Search

Related questions











Question 69 - AD0-E103 discussion

Report
Export

A custom AEM application contains a service component that needs to access the JCR repository within the activate method. The activate method uses ResourceResolverFactory.getServiceResourceResolver(…) without specifying a sub service name.

What should a developer do to make sure the user service mapping for the service component is available?

A.
Create a field of type ServiceUserMapped and annotate it with @Reference.
Answers
A.
Create a field of type ServiceUserMapped and annotate it with @Reference.
B.
Wait for the service ServiceUserMapper via BundleContext.getServiceReference(…).
Answers
B.
Wait for the service ServiceUserMapper via BundleContext.getServiceReference(…).
C.
Create a field of type ServiceUserMapped and annotate it with @Reference using ReferencePolicy.DYNAMIC.
Answers
C.
Create a field of type ServiceUserMapped and annotate it with @Reference using ReferencePolicy.DYNAMIC.
D.
Create a field of type ServiceUserMapper and annotate it with @Reference using ReferencePolicy.STATIC.
Answers
D.
Create a field of type ServiceUserMapper and annotate it with @Reference using ReferencePolicy.STATIC.
Suggested answer: A
asked 02/10/2024
Brandon Walters
36 questions
User
Your answer:
0 comments
Sorted by

Leave a comment first