exam questions

Exam AD0-E718 All Questions

View all questions & answers for the AD0-E718 exam

Exam AD0-E718 topic 1 question 7 discussion

Actual exam question from Adobe's AD0-E718
Question #: 7
Topic #: 1
[All AD0-E718 Questions]

An Architect working on a headless Adobe Commerce project creates a new customer attribute named my_attribute. Based on the attribute value of the customer, the results of GraphQl queries are modified using a plugin. The frontend application is communicating with Adobe Commerce through Varnish by Fastly, which is already caching the queries that will be modified. The Adobe Commerce Fastly extension is installed, and no other modifications are made to the application.
Which steps should the Architect take to make sure the vcl_hash function of Varnish also considers the newly created attribute?

  • A. Create a new class inheriting from Magento\Framework\GraphQl\Query\Resolver\IdentityInterface and returning the value of my_attribute from the getIdentities function. Then specify a @cache(cacheIdentity: Path\\To\\IdentityClass) directive for each GraphQL query to include the newly created IdentityClass to each query that adds the cache tags for each customer.
  • B. Create a new class inheriting from Magento\GraphQlCache\Model\CacheId\CacheIdFactorProviderInterface and returning the value of my_attribute from the getFactorValue function and my_attribute from getFactorName function. Then add this class through DI to the IdFactorProviders array of Magento\GraphQlCache\Model\CacheID\CacheIdCalculator.
  • C. Create a new class inheriting from Magento\Customer\CustomerData\SectionSourceInterface and returning the value of my_attribute from the getSectionData function. Then add this class through DI to the sectionSourceMap array of Magento\Customer\CustomerData\SectionPoolInterface.
Show Suggested Answer Hide Answer
Suggested Answer: B 🗳️

Comments

Chosen Answer:
This is a voting comment (?). It is better to Upvote an existing comment if you don't have anything to add.
Switch to a voting comment New
abhilash198
1 year, 7 months ago
Answer should be A https://developer.adobe.com/commerce/webapi/graphql/develop/identity-class/
upvoted 1 times
...
brightkhan
1 year, 9 months ago
ans should be A
upvoted 1 times
...
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.

Upvoting a comment with a selected answer will also increase the vote count towards that answer by one. So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.

SaveCancel
Loading ...
exam
Someone Bought Contributor Access for:
SY0-701
London, 1 minute ago