Magento 2's architecture uses code to bootstrap a custom module that resides in app/code.
What two files are required to make a module usable? (Choose two.)
A. Helper/Data.php
B. etc/config.xml
C. etc/module.xml
D. registration.php
You are implementing a before plugin in MyCompany_Magic. It will intercept the same method that MyCompany_Admission is already intercepting using a before plugin: Topmenu::getBlockHtml
Which two actions are required to ensure the new plugin will execute last? (Choose two.)
A. Include a sortOrder="20" on the new plugin in MyCompany_Magic's etc/di.xml file
B. Configure plugin sequencing for both plugins in MyCompany_Magic's etc/plugin_sequence.xml file
C. Set a sortOrder="10" for MyCompany_Admission's plugin in MyCompany_Magic's etc/di.xml
D. Add MyCompany_Admission as a dependency in MyCompany_Magic's etc/module.xml file
What scopes are available for customer attributes?
A. Global only
B. Website only
C. Global and Website
D. Global, Website and Store
What is a valid use case for an around plugin?
A. The execution of the pluginized method must be suppressed
B. The arguments of the before plugins must be modified
C. The arguments of the after plugins must be modified
D. The execution of the before and after plugins must be suppressed
You have created a module with a custom ACL resource and want to restrict access to resources of your module.
Which three items are restricted based on ACL role permissions? (Choose three.)
A. CLI Commands
B. Webapi resources
C. Storefront login
D. System configuration sections
E. Adminhtml controllers
You have been asked to display details from the customer's latest order on the customer's account dashboard (customer/account/). You create a new custom template to show the information.
How do you obtain an order repository so you can fetch an order?
A. Create a view model and specify an OrderRepositoryInterface argument in the _construct method
B. In your template, add the following: $orderRepository=ObjectManager::getInstance()->get(OrderRepositoryInterface::class);
C. In your block, add a method with the following: return ObjectManager::getInstance()->get(OrderRepositoryInterface::class);
D. In your template, add the following: $orderRepository = new OrderRepository();
How do you add a foreign key to an existing table created by another module?
A. Create etc/db_schema.xml file with the table node and constraint child node
B. Run the command bin/magento setup:db-schema:upgrade [table]
C. This can only be done with raw SQL in a Schema Patch file
D. Create the etc/db_constraints.xml file and specify foreign key there in the constraint node
Where do you change the frontName for the admin router?
A. app/etc/config.xml
B. app/etc/env.php
C. app/etc/local.xml
D. composer.json
What happens when a category's is_anchor attribute is set to 1?
A. Products without a specified category will be associated with this category
B. The customer will see all products from all children of the category
C. This is the default category for a website
D. The category will always be visible in the menu
You have configured an event observer to watch the checkout_submit_all_after event using this XML:
What is the required class definition for the event observer?
A. B. C. D.