ExamGecko
Question list
Search
Search

List of questions

Search

Related questions











Question 19 - AD0-E716 discussion

Report
Export

An Adobe Commerce developer has created a process that exports a given order to some external accounting system. Launching this process using the Magento CLI with the command php bin/magento my_module:order: process --order_id=<order_id> is required.

Example: php bin/magento my_module:order:process --order_id=1245.

What is the correct way to configure the command?

A)

B)

C)

D)

A.
Option B
Answers
A.
Option B
B.
Option C
Answers
B.
Option C
C.
Option C
Answers
C.
Option C
D.
Option D
Answers
D.
Option D
Suggested answer: C

Explanation:

According to the How to use the Magento command-line interface (CLI) guide, to configure and run the Magento CLI, the developer needs to make the bin/magento file executable and then use it to run commands. To create a custom command, the developer needs to create a class that implements \Symfony\Component\Console\Command\Command and define its name, description, arguments, options, and logic. The developer also needs to register the command in the di.xml file of their module using the Magento\Framework\Console\CommandList argument. Therefore, option C is the correct answer, as it shows the correct class and di.xml code to configure the custom command. Verified

Reference: https://www.a2hosting.com/kb/installable-applications/optimization-and-configuration/magento1/using-the-magento-command-line-interface-cli/

asked 02/10/2024
Tanya Resto
40 questions
User
Your answer:
0 comments
Sorted by

Leave a comment first