Latest [Nov 29, 2023] AD0-E718 Exam Questions – Valid AD0-E718 Dumps Pdf
AD0-E718 Practice Test Questions Answers Updated 50 Questions
NEW QUESTION # 10
An Adobe Commerce Architect is supporting deployment and building tools for on-premises Adobe Commerce projects. The tool is executing build scripts on a centralized server and using an SSH connection to deploy to project servers.
A client reports that users cannot work with Admin Panel because the site breaks every time they change interface locale.
Considering maintainability, which solution should the Architect implement?
- A. Modify project config.php file, configure 'admin_locales_for_deploy' value, and specify all required locales
- B. Adjust the tool's build script and specify required locales during 'setup:static-content:deploy' command
- C. Edit project env.php file, configure 'admin_locales_for.build' value, and specify all required locales
Answer: B
Explanation:
Explanation
To ensure that the Admin Panel works correctly and is maintainable, the Architect should adjust the tool's build script so that it specifies all of the required locales when executing the 'setup:static-content:deploy' command. This will ensure that the project is correctly configured for all supported locales and will also make sure that the build script does not need to be modified each time a new locale is added.
NEW QUESTION # 11
An Architect agrees to improve company coding standards and discourage using Helper classes in the code by introducing a new check with PHPCS.
The Architect creates the following:
* A new composer package under the AwesomeAgency\CodingStandard\ namespace
* The ruleset. xml file extending the Magento 2 Coding Standard
What should the Architect do to implement the new code rule?
A)
B)
C)
- A. Option A
- B. Option B
- C. Option C
Answer: C
Explanation:
To implement the new code rule, the Architect should create a new class that extends the \PHP_CodeSniffer\Sniffs\Sniff interface and implements the register() and process() methods. The register() method should return an array of tokens that the rule applies to, such as T_STRING for class names. The process() method should contain the logic to check if the class name contains Helper and report an error if so. The Architect should also add a reference to the new class in the ruleset.xml file under the <rule> element with a ref attribute. This will enable PHPCS to use the new rule when checking the code.
NEW QUESTION # 12
An Adobe Commerce Architect is reviewing api-functional test code. Some tests send errors to indicate that the customer address does not exist.
The test codes show the following:
Which steps should the Architect take to fix the test errors?
- A.

- B.

- C.

Answer: B
Explanation:
The test errors are caused by using the wrong customer ID and address ID in the request. The correct customer ID and address ID should be obtained from the response of the previous request to create a customer and an address. The test code should use $this->customer->getId() and $this->address->getId() instead of hard-coded values. Reference: https://devdocs.magento.com/guides/v2.4/get-started/web-api-functional-testing.html
NEW QUESTION # 13
A custom cron job has been added to an Adobe Commerce system to collect data for several reports. Its crontab. xml configuration is as follows:
The job is data intensive and runs for between 20 and 30 minutes each night.
Within a few days of deployment, it is noticed that the site's sitemap. xml file has not been updated since the new job was added.
What should be done to fix this issue?
- A. Create a new cron group for the reporting job. Specifying <use_separate_process>1/use_separate_process>
- B. Change the schedule of the sitemap_generate cron job to 30 o * * * so that it runs after the aacher_reporcmg_data job has completed.
- C. Break the data gathering job into a number of smaller jobs, so that each individual job runs for a maximum of 5 minutes.
Answer: A
Explanation:
This will ensure that the reporting job runs in its own process, separate from other cron jobs, and will not interfere with the sitemapgenerate cron job. This will ensure that the sitemapgenerate cron job runs as soon as the reporting job is finished, ensuring that the sitemap.xml is always up to date.
The issue is caused by the reporting job blocking the default cron group from running other jobs. By creating a new cron group for the reporting job and specifying <use_separate_process>1/use_separate_process>, the reporting job will run in a separate PHP process and will not affect the default cron group. This way, the sitemap_generate cron job will run as scheduled. Reference: https://devdocs.magento.com/guides/v2.4/config-guide/cron/custom-cron-ref.html
NEW QUESTION # 14
An Adobe Commerce Architect is setting up a Development environment for an on-premises project that will be used for developers to specifically test functionality, not performance, before being passed to the Testing team.
The Magento application must run with the following requirements:
1. Errors should be logged and hidden from the user
2. Cache mode can only be changed from Command Line
3. Static files should be created dynamically and then cached
Which Application Mode is required to achieve this?
- A. Production Mode
- B. Default Mode
- C. Developer Mode
Answer: C
Explanation:
Explanation
Developer Mode is the mode best suited to achieve the requirements set out by the Adobe Commerce Architect. In Developer Mode, errors are logged and hidden from the user, and the cache mode can only be changed from the command line. Additionally, static files are created dynamically and then cached, which is the desired behavior for this project.
NEW QUESTION # 15
While reviewing a newly developed pull request that refactors multiple custom payment methods, the Architect notices multiple classes that depend on \Magento\Framework\Encryption\EncryptorInterf ace to decrypt credentials for sensitive data. The code that is commonly repeated is as follows:
In each module, the user_secret config is declared as follows:
The Architect needs to recommend an optimal solution to avoid redundant dependency and duplicate code among the methods. Which solution should the Architect recommend?
- A. Add a plugin after the getvalue method of $sccpeConfig, remove the $encryptor from dependency and use it in the plugin to decrypt the value if the config name is 'user.secret?
- B. Create a common config service class vendor\Payment\Gateway\config\Config under Vendor.Payment and use it as a parent class for all of the Vender \EaymentModule\Gateway\Config\Config Classes and remove $sccpeConfig and $encryptor dependencies
- C. Replace all Vendor\PaymentModule\Gateway\Config\Config Classes With virtualTyp- Of Magento\Payxer.t\Gateway\Conflg\Config and Set <user_secret backend_Model="Magento\Config\Model\Config\Backend\Encrypted" /> under ccnfig.xml
Answer: B
Explanation:
To avoid redundant dependency and duplicate code among the methods, you need to use the following solution:
Create a standard controller route and mapping the internal URLs (such as news/article/view/id/1) to rewrites that are generated on save and then stored in the URL rewrites table. This solution will leverage the built-in URL rewrite functionality of Magento to handle the news requests. You can create a standard controller route that handles the internal URLs and loads the news article by its ID. Then, you can generate URL rewrites for each news article based on its date and URL key and store them in the URL rewrites table. This way, you can avoid using a custom router or a plugin and reduce the code complexity.
Reference:
https://devdocs.magento.com/guides/v2.4/extension-dev-guide/routing.html
https://devdocs.magento.com/guides/v2.4/extension-dev-guide/url-rewrite.html
NEW QUESTION # 16
An Adobe Commerce Architect needs to create a new customer segment condition to enable admins to specify an 'Average sales amount' condition for certain segments.
The Architect develops the custom condition under vendor\Module\Model\Segment\condition\AverageSalesAmount with all of its requirements:

Which two steps should the Architect complete to fix the problem? (Choose two.) A)
B)
C)
D)
E)
- A. Option C
- B. Option B
- C. Option D
- D. Option A
- E. Option E
Answer: B,E
Explanation:
According to the Adobe Commerce Developer Guide1, to create a new customer segment condition, the custom condition class must implement the Magento\CustomerSegment\Model\Segment\Condition\Combine\Interface interface. The class must also have a constructor that accepts an array of data and a context object that contains the required dependencies. Therefore, option B is correct because the constructor is missing the context object parameter. Option E is also correct because the class does not implement the required interface. The other options are not relevant for this problem.
NEW QUESTION # 17
An Adobe Commerce Architect is asked by a merchant using B2B features to help with a configuration issue.
The Architect creates a test Company Account and wants to create Approval Rules for orders. The Approval Rules tab does not appear in the Company section in the Customer Account Menu when the Architect logs in using the Company Administrator account.
Which two steps must be taken to fix this issue? (Choose two.)
- A. Set 'Enable B2B Quote" in the B2B Admin to TRUE
- B. Make sure that the 'Purchase Order' payment method is active
- C. Set 'Enable Purchase Orders' in the B2B Admin to TRUE
- D. Set Enable Purchase Orders' on the Company Record to TRUE
- E. Merchant needs to log out of frontend and then log back in to load new permissions
Answer: C,D
Explanation:
Enabling Purchase Orders at both the B2B Admin and the Company Record levels is necessary for Approval Rules to appear in the Company section of the Customer Account Menu. When 'Enable Purchase Orders' is set to TRUE, the system assumes that the company will be making purchases using purchase orders, and the Approval Rules tab becomes visible.
To create Approval Rules for orders, the Architect needs to enable Purchase Orders both in the B2B Admin and on the Company Record. This will allow the Company Administrator to access the Approval Rules tab in the Customer Account Menu and create rules based on various criteria. The Purchase Order payment method and the B2B Quote feature are not required for this functionality. Reference: https://docs.magento.com/user-guide/customers/account-dashboard-approval-rules.html
NEW QUESTION # 18
An Architect is investigating a merchant's Adobe Commerce production environment where all customer session data is randomly being lost. Customer session data has been configured to be persisted using Redis, as are all caches (except full page cache, which is handled via Varnish).
After an initial review, the Architect is able to replicate the loss of customer session data by flushing the Magento cache storage, either via the Adobe Commerce Admin Panel or running bin/iuagento cache: flush on the command line. Refreshing all the caches in the Adobe Commerce Admin Panel or running bin/magento cache: clean on the command line does not cause session data to be lost.
What should be the next step?
- A. Check app/etc/evn.php and make sure that the Redis configuration for caches and session data use different database numbers.
- B. Educate the merchant to not flush cache storage and only refresh the caches in future.
- C. Set the 'Stores > Configuration' option for "Store Session Data Separately' to 'Yes' in the Adobe Commerce Admin Panel.
Answer: A
Explanation:
Checking app/etc/env.php and making sure that the Redis configuration for caches and session data use different database numbers is the next step. This is because using the same database number for both caches and session data can cause session data to be lost when flushing the cache storage. By using different database numbers, the session data can be isolated from the cache data and avoid being overwritten. See Use Redis for session storage in the Adobe Commerce Help Center1. Reference: https://experienceleague.adobe.com/docs/commerce-operations/configuration-guide/cache/redis/redis-session.html?lang=en1
NEW QUESTION # 19
The development of an Adobe Commerce website is complete. The website is ready to be rolled out on the production environment.
An Architect designed the system to run in a distributed architecture made up of multiple backend webservers that process requests behind a Load Balancer.
After deploying the system and accessing the website for the first time, users cannot access the Customer Dashboard after logging in. The website keeps redirecting users to the sign-in page even though the users have successfully logged in. The Architect determines that the session is not being saved properly.
In the napp/etc/env.php\ the session is configured as follows:
What should the Architect do to correct this issue?
- A. Increase the session size with the command config:set system/security/max_session_size_admin
- B. Utilize the Remote Storage module to synchronize sessions between the servers
- C. Update the session host value to a shared Redis instance
Answer: C
NEW QUESTION # 20
An Architect wants to create an Integration Test that does the following:
* Adds a product using a data fixture
* Executes $this->someLogic->execute($product) on the product
* Checks if the result is true.
Sthis->someLogic has the correct object assigned in the setup () method-Product creation and the tested logic must be executed in the context of two different store views with IDs of 3 and 4, which have been created and are available for the test.
How should the Architect meet these requirements?
- A. Create two test Classes With one test method each. Use the @magentoExecuteInStoreContext 3 and
@magentoExecuteInStoreContext 4 annotations on the class level. - B. Create one test class with two test methods. Use the @magentoStoreContext 3 annotation in one method and @magentoStoreContext 4 in the other one.
- C. Create one test class with one test method. Use the \Magento\testFramework\ store\Executionstorecontext class once in the fixture and another time in the test.
Answer: A
Explanation:
Explanation
The best approach for the Architect to meet the requirements is Option B. Create two test Classes With one test method each. Use the @magentoExecuteInStoreContext 3 and @magentoExecuteInStoreContext 4 annotations on the class level. This will ensure that the fixture is executed in the context of Store View 3, and the tested logic is executed in the context of Store View 4. This approach allows for more granular control of the store views and reduces the complexity of the test.
NEW QUESTION # 21
An Adobe Commerce Architect is asked by a merchant using B2B features to help with a configuration issue.
The Architect creates a test Company Account and wants to create Approval Rules for orders. The Approval Rules tab does not appear in the Company section in the Customer Account Menu when the Architect logs in using the Company Administrator account.
Which two steps must be taken to fix this issue? (Choose two.)
- A. Set 'Enable B2B Quote" in the B2B Admin to TRUE
- B. Make sure that the 'Purchase Order' payment method is active
- C. Set 'Enable Purchase Orders' in the B2B Admin to TRUE
- D. Set Enable Purchase Orders' on the Company Record to TRUE
- E. Merchant needs to log out of frontend and then log back in to load new permissions
Answer: C,D
Explanation:
Explanation
Enabling Purchase Orders at both the B2B Admin and the Company Record levels is necessary for Approval Rules to appear in the Company section of the Customer Account Menu. When 'Enable Purchase Orders' is set to TRUE, the system assumes that the company will be making purchases using purchase orders, and the Approval Rules tab becomes visible.
NEW QUESTION # 22
An Architect working on a headless Adobe Commerce project creates a new customer attribute named my_attribure. Based on the attribute value of the customer, the results of GraphQI 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)
B)
C)
- A. Option C
- B. Option B
- C. Option A
Answer: B
Explanation:
Option B is the correct way to make sure the vcl_hash function of Varnish also considers the newly created attribute. The Architect should create a new module that depends on Magento_Fastly and declare a plugin for \Magento\Fastly\Model\Config::getVclSnippets() method. The plugin should add a new snippet to the result array with the type 'recv' and the content 'set req.http.my_attribute = req.http.X-Magento-Vary;'. This will append the value of the customer attribute to the hash key used by Varnish for caching. Option A is incorrect because it modifies the core file of Magento_Fastly module, which is not recommended and can cause issues during upgrades. Option C is incorrect because it uses the wrong type and content for the snippet, which will not affect the vcl_hash function. Reference: https://devdocs.magento.com/cloud/cdn/fastly-vcl-bypass-to-origin.html According to the Adobe Commerce Developer Guide2, to make sure the vcl_hash function of Varnish also considers the newly created attribute, the Architect should use a plugin for Magento\Customer\Model\Context::getVaryString method and add the attribute value to the vary string. This will ensure that Varnish caches different versions of GraphQL queries based on the attribute value of the customer. Therefore, option B is correct. Option A is not correct because it does not affect the vcl_hash function. Option C is not correct because it does not use a plugin for the getVaryString method.
NEW QUESTION # 23
A merchant notices that product price changes do not update on the storefront.
The index management page in the Adobe Commerce Admin Panel shows the following:
* All indexes are set to 'update by schedule'
* Their status is 'ready'
* There are no items in the backlog
* The indexes were last updated 1 minute ago
A developer verifies that updating and saving product prices adds the relevant product IDs into the catalog_product_price_cl changelog table.
Which two steps should the Architect recommend to the developer to resolve this issue? (Choose two.)
- A. Make sure that no custom or third-party modules modify the changelog and indexing process.
- B. Make sure that the version_id for the price indexer in the mview_state table is not higher than the last entry for the same column in the changelog table and re-synchronize.
- C. Invalidate the catalog_product_price indexer in the Adobe Commerce Admin Panel so that it is fully reindexed next time the cron runs.
- D. Manually reindex the catalog_product_price index from the Command line:bin\magentor indexer:reindex catalog_product_price.
- E. Reduce the frequency of the cron job to 5 minutes so the items have more time to process.
Answer: C,D
NEW QUESTION # 24
An Adobe Commerce Architect needs to set up two websites on a single Adobe Commerce instance with base URLs: example.com and website2.example.com.
How should the Architect configure this project so that both websites can use the same customer base?
- A. Change Session Cookie attribute to "SameSite=None"
- B. Disable Session Validation for "HTTP_X_FORWARDED_FOR" header
- C. Set Cookie Domain for both websites to ".example.com"
Answer: C
Explanation:
By setting the same cookie domain for both websites, the customer base can be shared between both websites, as the customer will be authenticated by the same cookie across both sites. This will ensure that customers don't have to log in twice when switching between the two sites.
Setting Cookie Domain for both websites to ".example.com" will allow both websites to use the same customer base. This is because the cookie domain determines which websites can access the customer information stored in the cookie. By using a common domain, both websites can share the same customer cookie. See Multiple websites or stores in the Adobe Commerce Help Center1. Reference: https://experienceleague.adobe.com/docs/commerce-operations/configuration-guide/multi-sites/ms-overview.html?lang=en1
NEW QUESTION # 25
An Adobe Commerce store owner sets up a custom customer attribute "my.attribute" (type int).
An Architect needs to display customer-specific content on the home page to Customers with "my.attribute" greater than 3. The website is running Full Page Cache.
Using best practices, which two steps should the Architect take to implement these requirements? (Choose two.)
- A. Add a new context value of "my.attribute" to Magento\Framework\App\Http\Context
- B. Add a custom block and a phtml template with the content to the cmsjndexjndex.xml layout
- C. Use customer-data JS library to retrieve "my.attribute" value
- D. Create a Customer Segment and use "my.attribute" in the conditions
- E. Add a dynamic block with the content to the Home Page
Answer: B,C
Explanation:
To display customer-specific content on the home page to Customers with "my.attribute" greater than 3, you need to use the following steps:
Use customer-data JS library to retrieve "my.attribute" value. The customer-data JS library allows you to access the customer data stored in the local storage of the browser. You can use the get() method to get the value of "my.attribute" for the current customer.
Add a new context value of "my.attribute" to Magento\Framework\App\Http\Context. The HTTP context is a mechanism that allows you to vary the cache of a page based on some parameters. By adding a new context value of "my.attribute", you can cache separate versions of the home page for customers with different values of "my.attribute".
Add a custom block and a phtml template with the content to the cms_index_index.xml layout. This step will create a block that will display the customer-specific content on the home page. You can use the phtml template to check the value of "my.attribute" and render the content accordingly.
Reference:
https://devdocs.magento.com/guides/v2.3/extension-dev-guide/cache/page-caching/public-content.html
https://devdocs.magento.com/guides/v2.3/howdoi/checkout/checkout_customize.html
NEW QUESTION # 26
An Adobe Commerce Architect is supporting deployment and building tools for on-premises Adobe Commerce projects. The tool is executing build scripts on a centralized server and using an SSH connection to deploy to project servers.
A client reports that users cannot work with Admin Panel because the site breaks every time they change interface locale.
Considering maintainability, which solution should the Architect implement?
- A. Adjust the tool's build script and specify required locales during 'setup:static-content:deploy' command
- B. Modify project config.php file, configure 'admin_locales_for_deploy' value, and specify all required locales
- C. Edit project env.php file, configure 'admin_locales_for.build' value, and specify all required locales
Answer: C
Explanation:
Editing project env.php file, configuring 'admin_locales_for.build' value, and specifying all required locales is the solution that the Architect should implement. This is because this configuration allows the tool to generate static content for different locales during the build phase, which improves performance and avoids breaking the site when changing interface locale. See Deploy static view files in the Adobe Commerce Help Center1. Reference: https://experienceleague.adobe.com/docs/commerce-operations/configuration-guide/cli/static-view/static-view-file-deployment.html?lang=en1
NEW QUESTION # 27
A custom cron job has been added to an Adobe Commerce system to collect data for several reports. Its crontab. xml configuration is as follows:
The job is data intensive and runs for between 20 and 30 minutes each night.
Within a few days of deployment, it is noticed that the site's sitemap. xml file has not been updated since the new job was added.
What should be done to fix this issue?
- A. Change the schedule of the sitemap_generate cron job to 30 o * * * so that it runsafter the aacher_reporcmg_datajob has completed.
- B. Create a new cron group for the reporting job. Specifying
<use_separate_process>1/use_separate_process> - C. Break the data gathering job into a number of smaller jobs, so that each individual job runs for a maximum of 5 minutes.
Answer: B
Explanation:
Explanation
This will ensure that the reporting job runs in its own process, separate from other cron jobs, and will not interfere with the sitemapgenerate cron job. This will ensure that the sitemapgenerate cron job runs as soon as the reporting job is finished, ensuring that the sitemap.xml is always up to date.
NEW QUESTION # 28
An external system integrates functionality of a product catalog search using Adobe Commerce GraphQL API. The Architect creates a new attribute my_attribute in the admin panel with frontend type select.
Later, the Architect sees that Productinterface already has the field my_atcribute, but returns an mc value. The Architect wants this field to be a new type that contains both option id and label.
To meet this requirement, an Adobe Commerce Architect creates a new module and file etc/schema.graphqls that declares as follows:
After calling command setup:upgrade, the introspection of Productlnterface field xy_attribute remains int. What prevented the value type of field my_attribute from changing?
- A. The interface Productlnterface is already declared in Magento.CatalogGraphQI module. Extending requires use of the keyword -xceni before a new declaration of Productlnterface.
- B. The Magento.CatalogGraphQI module occurs later in sequence than the Magento.GraphQI module and merging output of dynamic attributes schema reader overrides types declared in schema.graphqls
- C. The fields of Productlnterface are checked during processing schema.graphqls files. If they have a corresponding attribute, then the backendjype of product attribute is set for field type.
Answer: B
Explanation:
products query is a GraphQL query that returns information about products that match specified search criteria. It also shows how to use ProductInterface fields to retrieve product data.
https://devdocs.magento.com/guides/v2.3/graphql/queries/products.html
The Magento.CatalogGraphQI module occurs later in sequence than the Magento.GraphQI module and merging output of dynamic attributes schema reader overrides types declared in schema.graphqls. The dynamic attributes schema reader is responsible for adding product attributes to the Productinterface based on the backend type of the attribute. Since the attribute my_attribute has a backend type of int, the field my_attribute in the Productinterface will also have a type of int, regardless of the custom type declared in the schema.graphqls file. To avoid this, the Architect should either change the backend type of the attribute to match the custom type, or use a different name for the field that does not conflict with the attribute name. Reference: https://devdocs.magento.com/guides/v2.4/graphql/develop/create-graphqls-file.html
NEW QUESTION # 29
A company has an Adobe Commerce store. An attribute named "my.attribute" (type "text") is created to save each product's global ID that is shared between multiple systems.
Several months after going live, the values of "my.attribute" are all integer. This causes a problem for the other systems when those systems receive this data.
An Adobe Commerce Architect needs to recommend a solution to change the type of "my.attribute" from textXo int Which two steps should the Architect take to achieve this? (Choose two.)
- A. Write a plugin for \Magento\Eav\Model\Entity\Attrlbute\Backend\AbstractBackend::afterLoad() and load data from "catalog_product_entity_int"
- B. Migrate data from table "catalog_product_entity_text" to "catalog.producLentityjnt" for the attribute.id
- C. Run the Command bin/magentc indexer: reset catalog_product_attribute
- D. Go to Admin > Stores > Attributes > Product, edit "my.attribute" and update type from "text' to "inf
- E. Create a Data Patch and update 'my.attribute' type from "text" to "inf
Answer: B,E
Explanation:
Explanation
Option A is correct because it will migrate data from one table to another based on the attribute id, which is required when changing the attribute type . Option D is correct because it will create a data patch that will update 'my.attribute' type from "text" to "int", which is a recommended way of changing the attribute type programmatically4.
NEW QUESTION # 30
A company wants to build an Adobe Commerce website to sell their products to customers in their country.
The taxes in their country are highly complex and require customization to Adobe Commerce. An Architect is trying to solve this problem by creating a custom tax calculator that will handle the calculation of taxes for all orders in Adobe Commerce.
How should the Architect add the taxes for all orders?
- A. Declare a new total collector in "etc/sales.xml" in a custom module
- B. Write a before plugin to \Magento\Quote\Model\QuoteManagement::placeOrder() and add the custom tax to the quote
- C. Add a new observer to the event 'sales_quote_collect_totals_before" and add the custom tax to the quote
Answer: A
Explanation:
Explanation
you can create tax rules in Magento 2 by going to Stores > Taxes > Tax Rules and choosing or adding tax rates. However, this may not be enough for complex tax scenarios that require customization.
https://amasty.com/knowledge-base/how-to-configure-tax-calculation-in-magento-2.html
NEW QUESTION # 31
An Adobe Commerce Architect notices that queue consumers close TCP connections too often on Adobe Commerce Cloud server leading to delays in processing messages.
The Architect needs to make sure that consumers do not terminate after processing available messages in the queue when CRON job is running these consumers.
How should the Architect meet this requirement?
- A. Set CONSUMER_WAIT_FOR_MAX_MESSAGES variable true in deployment stage.
- B. Increase multiple_process limit to spawn more processes for each consumer.
- C. Change max_messages from 10,000 to 1,000 for CRON_CONSUMER_RUNNERvariable.
Answer: A
Explanation:
The best way to meet this requirement is to set the CONSUMERWAITFORMAXMESSAGES variable to true in the deployment stage. This variable will ensure that the consumer will not terminate when there are no more messages in the queue and will instead wait until a new message is available, preventing it from closing the connection prematurely. Additionally, the multiple_processes limit can be increased to spawn more processes for each consumer, which will help ensure that messages can be processed faster.
Setting CONSUMER_WAIT_FOR_MAX_MESSAGES variable true in deployment stage will make sure that consumers do not terminate after processing available messages in the queue when CRON job is running these consumers. This will prevent consumers from closing TCP connections too often and improve performance. See Start message queue consumers in the Adobe Commerce Help Center1. Reference: https://experienceleague.adobe.com/docs/commerce-operations/configuration-guide/message-queues/consumers.html?lang=en2 https://experienceleague.adobe.com/docs/commerce-operations/configuration-guide/cli/start-message-queues.html1
NEW QUESTION # 32
A company has an Adobe Commerce store. An attribute named "my.attribute" (type "text") is created to save each product's global ID that is shared between multiple systems.
Several months after going live, the values of "my.attribute" are all integer. This causes a problem for the other systems when those systems receive this data.
An Adobe Commerce Architect needs to recommend a solution to change the type of "my.attribute" from textXo int Which two steps should the Architect take to achieve this? (Choose two.)
- A. Write a plugin for \Magento\Eav\Model\Entity\Attrlbute\Backend\AbstractBackend::afterLoad() and load data from "catalog_product_entity_int"
- B. Migrate data from table "catalog_product_entity_text" to "catalog.producLentityjnt" for the attribute.id
- C. Run the Command bin/magentc indexer: reset catalog_product_attribute
- D. Go to Admin > Stores > Attributes > Product, edit "my.attribute" and update type from "text' to "inf
- E. Create a Data Patch and update 'my.attribute' type from "text" to "inf
Answer: B,E
Explanation:
Option A is correct because it will migrate data from one table to another based on the attribute id, which is required when changing the attribute type14. Option D is correct because it will create a data patch that will update 'my.attribute' type from "text" to "int", which is a recommended way of changing the attribute type programmatically4.
To change the type of "my.attribute" from text to int, the Architect should take two steps: A) Migrate data from table "catalog_product_entity_text" to "catalog_product_entity_int" for the attribute_id. This step will move the existing values of the attribute from the text table to the int table, which corresponds to the new type. D) Create a Data Patch and update 'my.attribute' type from "text" to "int". This step will update the attribute metadata in the database and reflect the new type. Option B is incorrect because the Admin panel does not allow changing the type of an existing attribute. Option C is incorrect because writing a plugin for \Magento\Eav\Model\Entity\Attribute\Backend\AbstractBackend::afterLoad() will not change the type of the attribute, but only load data from a different table. Option E is incorrect because running the command bin/magento indexer:reset catalog_product_attribute will not change the type of the attribute, but only reset the indexer status. Reference: https://devdocs.magento.com/guides/v2.4/extension-dev-guide/attributes.html
NEW QUESTION # 33
A company wants to build an Adobe Commerce website to sell their products to customers in their country.
The taxes in their country are highly complex and require customization to Adobe Commerce. An Architect is trying to solve this problem by creating a custom tax calculator that will handle the calculation of taxes for all orders in Adobe Commerce.
How should the Architect add the taxes for all orders?
- A. Declare a new total collector in "etc/sales.xml" in a custom module
- B. Write a before plugin to \Magento\Quote\Model\QuoteManagement::placeOrder() and add the custom tax to the quote
- C. Add a new observer to the event 'sales_quote_collect_totals_before" and add the custom tax to the quote
Answer: A
Explanation:
you can create tax rules in Magento 2 by going to Stores > Taxes > Tax Rules and choosing or adding tax rates.
However, this may not be enough for complex tax scenarios that require customization.
https://amasty.com/knowledge-base/how-to-configure-tax-calculation-in-magento-2.html
To add a new total to the order, the Architect should declare a new total collector in the "etc/sales.xml" file of a custom module.
This file defines the order of calculation and rendering of totals.
The Architect should also implement a model class that extends \Magento\Quote\Model\Quote\Address\Total\AbstractTotal and overrides the collect() and fetch() methods to handle the logic of adding the custom tax to the quote and order.
Reference: https://devdocs.magento.com/guides/v2.4/howdoi/checkout/checkout_new_total.html
NEW QUESTION # 34
......
AD0-E718 dumps Sure Practice with 50 Questions: https://www.test4engine.com/AD0-E718_exam-latest-braindumps.html
Get New AD0-E718 Certification – Valid Exam Dumps Questions: https://drive.google.com/open?id=1QwTPyCoT1tTQaNOALgLffi0bcslXBZ0C