Expand my Community achievements bar.

Learn about Edge Delivery Services in upcoming GEM session
SOLVED

graphQl support for rendering multi lingual content and caching strategy

Avatar

Level 3

We are using GraphQL persistent queries (GET with query variables) and want to cache the response at Dispatcher / CDN level. Need some info around 2 usecases which we are trying to achieve via graphql - 

 

1) Achieve Multi language support via graphql
2) Cache grapql response with respect to different language and variables respectively..

1 Accepted Solution

Avatar

Correct answer by
Employee Advisor

@nidhigurani 

Unfortunately, AEM MSM does not support Content Fragments as of yet. But it supports MSM in Assets. And hence we can add Content Fragments to Language Translation as part of Assets.

Please find below link, by far the best tutorial I could find for this:
https://experienceleague.adobe.com/docs/experience-manager-learn/sites/content-fragments/content-fra...

 

View solution in original post

3 Replies

Avatar

Employee Advisor

Hi @anika_agarwal 

1. You will have to elaborate on first question, what kind of support are you expecting out of graphql for multi language support. Elaborate on usecase.

2. For Caching Graphql Queries - use Persisted Queries. Below are few documentation that should help you with Cach Configuration and leveraging on Persisted Queries:

 

https://kiransg.com/2022/02/01/caching-aem-graphql-queries-with-content-fragment/

https://experienceleague.adobe.com/docs/experience-manager-cloud-service/content/headless/graphql-ap...

https://experienceleague.adobe.com/docs/experience-manager-learn/getting-started-with-aem-headless/g...

 

Avatar

Employee

Hi @krati_garg 

Requirement here is that we need content on the basis of locale. For ref , on EN locale we need content in english language from and on HI locale we need content in hindi

Avatar

Correct answer by
Employee Advisor

@nidhigurani 

Unfortunately, AEM MSM does not support Content Fragments as of yet. But it supports MSM in Assets. And hence we can add Content Fragments to Language Translation as part of Assets.

Please find below link, by far the best tutorial I could find for this:
https://experienceleague.adobe.com/docs/experience-manager-learn/sites/content-fragments/content-fra...