Deal of The Day! Hurry Up, Grab the Special Discount - Save 25% - Ends In 00:00:00 Coupon code: SAVE25
Welcome to Pass4Success

- Free Preparation Discussions

Adobe AD0-E722 Exam - Topic 7 Question 58 Discussion

An Adobe Commerce Architect creates a stopword for the Italian locale named stopwordsjtJT.csv and changes the stopword directory to the following: /app/code/Custovendor/Elasticsearch/etc/stopwords/What is the correct approach to change the stopwords directory inside the custom module?
A) Add stopwords to the stopwordsDirectory and CustomerVendor_Elasticsearch to the stopword sModule parameter Of the \Magento\Elasticsearch\SearchAdapter\Query\Preprocessor\Stopwords ClflSS Via di.xml
B) Add a new ClaSS implementing \Magento\Framework\Setup\Patch\PatchInterface to modify the default Value Of elasticsearch\customer\stopwordspath in core.conf ig_data table.
C) Add stopwords to the stopwordsDirectory parameter of the\Hagento\Elasticsearch\Model\Adapter\Document\DirectoryBuilder ClaSS Via stopwords/it.xml and Adobe Commerce will automatically detect the current module.

Adobe AD0-E722 Exam - Topic 7 Question 58 Discussion

Actual exam question for Adobe's AD0-E722 exam
Question #: 58
Topic #: 7
[All AD0-E722 Questions]

An Adobe Commerce Architect creates a stopword for the Italian locale named stopwordsjtJT.csv and changes the stopword directory to the following: /app/code/Custovendor/Elasticsearch/etc/stopwords/

What is the correct approach to change the stopwords directory inside the custom module?

Show Suggested Answer Hide Answer
Suggested Answer: A

According to the Adobe Commerce documentation, the correct approach to change the stopwords directory inside a custom module is to use dependency injection to override the default values of the stopwordsDirectory and stopwordsModule parameters of the MagentoElasticsearchSearchAdapterQueryPreprocessorStopwords class. The stopwordsDirectory parameter specifies the relative path of the stopwords directory from the module directory, while the stopwordsModule parameter specifies the name of the module that contains the stopwords directory. By adding these parameters to the di.xml file of the custom module, the Architect can change the location of the stopwords files without modifying the core code or database.


To change the directory from your module

Configure Elasticsearch stopwords

Contribute your Thoughts:

0/2000 characters
France
8 hours ago
I vaguely recall that adding a new class implementing PatchInterface was a way to make changes, but I’m not confident if that applies here.
upvoted 0 times
...
Julieta
6 days ago
I’m a bit confused about the differences between the classes mentioned in the options. I thought we only needed to change the stopwordsDirectory in one place.
upvoted 0 times
...
Amalia
11 days ago
This question seems similar to one we practiced where we had to adjust stopword settings. I feel like option A might be the right approach, but I could be mixing it up.
upvoted 0 times
...
Zana
16 days ago
I think I remember something about modifying the stopwords directory in the XML configuration, but I'm not entirely sure which class to reference.
upvoted 0 times
...

Save Cancel