0% found this document useful (0 votes)
66 views26 pages

Simulado MCD 03

The document is a practice test for the Mulesoft Certified Developer Level 1 exam. It consists of 30 multiple choice questions testing knowledge of Mulesoft concepts and best practices. The questions cover topics like Mule application structure, scaling strategies, API configuration, application properties, metadata storage, and event processing components like routers.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
66 views26 pages

Simulado MCD 03

The document is a practice test for the Mulesoft Certified Developer Level 1 exam. It consists of 30 multiple choice questions testing knowledge of Mulesoft concepts and best practices. The questions cover topics like Mule application structure, scaling strategies, API configuration, application properties, metadata storage, and event processing components like routers.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 26

Simulado 03 - Mulesoft Certifield Developer – Level 1

1)

2)

3)

4)
5)

6)

7)

8)
9)

10)

11)

12)
13)

14)

15)

16)
17)

18)

19)

20)
21)

22)

23)

24)
25)

26)

27)

28)
29)

30)
Gabarito

1)

Explicação
Process section is must to get code compiled successfully in Anypoint Studio. Process section must have
one or more processors.

2)

Explicação
APIkit Router

The APIkit router is a key message processor that validates requests against the RAML definition, enriches
messages, for example by adding default values to the messages, and routes requests to a flow. "Bad
request" is returned if the request is invalid, for example, and "Not implemented" is returned if the RAML
resource that you request is not associated with a flow.
Hence correct answer is Validates requests against RAML API specifications and routes them to API
implementations

Mule Ref Doc : About Generating RAML-based Flows | MuleSoft Documentation

3)

Explicação
Mule applications can be scaled vertically by changing worker size. Mule applications can be scaled
horizontally by adding more workers.

Horizontal Scaling
Multiple workers of small vCore capacity helps to improve throughput of high frequency small payload type
applications. For example your application is a http API Proxy, and you have a lot of clients sending frequent
requests, but each request is small payload and utilizes only little cpu or memory. Horizontally scaling will
allow you to have more capacity as well as redundancy.

Vertical Scaling
Large single vCore workers are useful for high CPU intensive integrations or APIs. Ones that are processing
large payloads but small number of actual requests. If you want these single large payloads to be processed
even quicker, increase the vCore size.

Mule Ref Doc : https://docs.mulesoft.com/runtime-manager/cloudhub-architecture

4)

Explicação
Correct answer is Specify throttling , security and other policies

MuleSoft Doc Ref : https://docs.mulesoft.com/api-manager/2.x/api-gateway-capabilities-mule4

API Gateway is responsible for below functions.


1) Determine which traffic is authorized
2) Meter the traffic
3) Logs transaction
4) Apply throttling and other policies (Not specifying. These are specified in API Manager)

5)

Explicação
Organization Administrators can approve/revoke/delete SLA tier access requests via API Manager only.

Approve or Reject Access Requests


After users request access to your API instance from Anypoint Exchange, you can manually approve or
reject requests from API Manager.

Task Prerequisite
To manually approve or reject requests, you must have:
Configured the SLA tier for the application
The Organization Administrator, API Manager Environment Administrator, or the Manage Contracts
permission

Manually Approve Requests


To approve or reject requests to access your API:
In API Manager, click API Administration.
Click the name of the API instance to which you are requesting access.
From the configuration page for the API instance, click Contracts from the left menu.
The request appears:
Click either Approve or Reject to approve or reject the access request, respectively.

Mule Ref Doc : Approve or Reject Access Requests | MuleSoft Documentation

6)

Explicação
Application properties can be defined in .yaml or in .properties file.

Supported Files
The Configuration Properties support both YAML configuration files ( .yaml ) and Properties configuration files
( .properties ).  String  is the only supported type in both file formats. Use the format that you find easier to
read and edit.
YAML file example:
<configuration-properties file="ports.yaml"/>

Where  ports.yaml  is:


smtp:

port: "8957"

http:

port: "8081"

Properties file example:


<configuration-properties file="ports.properties"/>

Where  ports.properties  is:


smtp.port=8957

http.port=8081

MuleSoft Doc Ref : https://docs.mulesoft.com/mule-runtime/4.3/configuring-properties#supported_files


7)

Explicação
POM.xml contains info about the project and configuration details used by Maven to build the project.
pom.xml File
<project root>/pom.xml

Project Object Model file that defines settings for a Maven project describing an application. It includes all
settings necessary to build the application such as build plugin configurations. Note that the  pom.xml  exists
on a per-project basis and is distributed along with a project.

Mule Ref Doc : Maven Reference | MuleSoft Documentation

8)

Explicação
Metadata is stored in application-types.xml flle located under src/main/resources.

Mule 4 applications contain an application-types.xml file, which is where metadata around your data types is
stored. For example, if you create a new CSV type, that metadata will be added to this file. This new file is
easy to share, commit, and merge when conflicts arise, which enables you to do more metadata-driven
development.

MuleSoft Doc Ref : https://docs.mulesoft.com/mule-runtime/4.3/intro-studio#metadata-storage

9)
Explicação
Gold is not valid category for connector types.

MuleSoft Doc Ref : https://docs.mulesoft.com/mule-runtime/3.7/anypoint-connectors#connector-support-


categories

10)

Explicação
WSDL is used to define the contract in case of SOAP . RAML/OAS is used to REST services

11)

Explicação
Pick First is not valid type. Rest all are valid type of event processor.

Choice Router :
The Choice router dynamically routes messages through a flow according to a set of DataWeave
expressions that evaluate message content. Each expression is associated with a different routing option.
The effect is to add conditional processing to a flow, similar to an  if / then / else  code block in most
programming languages.
Only one of the routes in the Choice router executes, meaning that the first expression that evaluates
to  true  triggers that route’s execution and the others are not checked. If none of the expressions are  true ,
then the default route executes.

Ref Doc : https://docs.mulesoft.com/mule-runtime/4.3/choice-router-concept

Round Robin :
The Round Robin router iterates through a list of two or more routes in order, but it only routes to one of the
routes each time it is executed. It keeps track of the previously selected route and never selects the same
route consecutively. For example, the first time Round Robin executes, it selects the first route. The next
time, it selects the second route. If the previously selected route is the last route in the list, Round Robin
jumps to the first route.

Ref Doc : https://docs.mulesoft.com/mule-runtime/4.3/round-robin

First Successful :
The First Successful router iterates through a list of configured processing routes until one of the routes
executes successfully. If any processing route fails execution (throws an error), the router executes the next
configured route.
If none of the configured routes execute successfully, the First Successful router throws an error.

Ref Doc : https://docs.mulesoft.com/mule-runtime/4.3/first-successful

12)

Explicação
Choice router finds the FIRST true condition, then distribute the event to the ONE matched route.

MuleSoft Doc Ref : https://docs.mulesoft.com/mule-runtime/4.1/choice-router-concept

The Choice router dynamically routes messages through a flow according to a set of DataWeave
expressions that evaluate message content. Each expression is associated with a different routing option.
The effect is to add conditional processing to a flow, similar to an if/then/else code block in most
programming languages.

Only one of the routes in the Choice router executes, meaning that the first expression that evaluates to true
triggers that route’s execution and the others are not checked. If none of the expressions are true, then the
default route executes.
13)

Explicação
Scatter-Gather Router
The Scatter-Gather component is a routing event processor that processes a Mule event through different
parallel processing routes that contain different event processors. Each route receives a reference to the
Mule event and executes a sequence of one or more event processors. Each of these routes uses a
separate thread to execute the event processors, and the resulting Mule event can be either the same Mule
event without modifications or a new Mule event with its own payload, attributes, and variables. The Scatter-
Gather component then combines the Mule events returned by each processing route into a new Mule event
that is passed to the next event processor only after every route completes successfully.

The Scatter-Gather component executes each route in parallel, not sequentially. Parallel execution of routes
can greatly increase the efficiency of your Mule application and may provide more information than
sequential processing.

The following diagram details the behavior of the Scatter-Gather component:

The Scatter-Gather
component receives
a Mule event and sends a reference of this Mule event to each processing route. Each of the processing
routes starts executing in parallel. After all processors inside a route finish processing, the route returns a
Mule event, which can be either the same Mule event without modifications or a new Mule event created by
the processors in the route as a result of the modifications applied. After all processing routes have finished
execution, the Scatter-Gather component creates a new Mule event that combines all resulting Mule events
from each route, and then passes the new Mule event to the next component in the flow.

Based on above explanation , correct answer is Entire event would be sent to each route in parallel.

14)

Explicação
Correct answer is Validation module's Is Null operation

Validate Null
Fails if the value is not null and not an instance of NullPayload

Studio Visual Editor

15)
Explicação
In case of an error , batch job completes in flight steps and stops further processing.

MuleSoft Doc Ref : Handling Errors During Batch Job | MuleSoft Documentation

The default is all processing will stop but we can change it by Max Failed Record field.

General -> Max Failed Records: Mule has three options for handling a record-level error: Finish
processing, Continue processing and Continue processing until the batch job accumulates a maximum
number of failed records. This behavior can be controlled by Max Failed Records.

The default value is Zero which corresponds to Finish processing.

The value -1, corresponds to Continue processing.

The value +ve integer, corresponds to Continue processing until the batch job accumulates a maximum
number of failed records.

16)

Explicação
MuleSoft Doc Ref : https://docs.mulesoft.com/api-manager/2.x/policy-mule3-tutorial-manage-an-api#to-add-
the-tier

Steps to create SLA Tier are as follows:


1) In API Manager, in API Administration, click a version.
2) Check that the API supports resource-level policies: On the API version details page, in Status, click
Configure Endpoint, and check that Type is RAML.
3) Choose the SLA Tiers, and click Add SLA Tier. Set up limit on SLA tier.

17)

Explicação
Root element is always required while creating XML response in DataWeave transformation.
Mule Ref Doc : Select XML Elements | MuleSoft Documentation

18)

Explicação
You can define your own DataWeave functions using the fun declaration in the header of a DataWeave
script. Sample is as below. ----------------------------------------
%dw 2.0

output application/json

fun toUpper(aString) = upper(aString)

---

toUpper("hello")

MuleSoft Doc Ref : https://docs.mulesoft.com/mule-runtime/4.1/dataweave-functions

19)

Explicação
One cloudhub worker can host one Mule application only.

CloudHub Workers
Workers are dedicated instances of Mule runtime engine that run your integration applications on CloudHub.
Workers have the following characteristics:
Capacity
Each worker has a specific amount of capacity to process data. Select the size of your workers when
configuring an application.

Isolation
Each worker runs in a separate container from every other application.

Manageability
Each worker is deployed and monitored independently.
Locality
Each worker runs in a specific worker cloud, such as the US, EU, or Asia-Pacific.
The memory capacity and processing power of a worker depends on how you configure it at the application
level.
Worker sizes have different compute, memory, and storage capacities.

Mule Ref Doc : CloudHub Architecture | MuleSoft Documentation

20)

Explicação
Debugger can be used to debug applications to see event data moving from one flow to other.

Studio Visual Debugger


Anypoint Studio Visual Debugger allows you to run your application in Debug mode, setting breakpoints to
stop execution to check the contents of an event at a previously-specified event processor.

When you run your application in Debug mode, the application stops immediately after executing the event
processor with the breakpoint. Using the Mule Debugger View, you can browse through the contents of the
message as it exists at that point in the flow, and evaluate a Dataweave expression against the captured
event.

The Visual Debugger is completely distinct from the Java Debugger contained in Studio; in fact, you may run
both debuggers concurrently on your application.

When debugging on your local machine, Studio Visual Debugger listens for incoming TCP connections on
localhost port 6666. This port must be available on your machine. This means not blocked by a firewall or
other security software.

Mule Ref Doc : Studio Visual Debugger | MuleSoft Documentation

21)

Explicação
Correct answer is PUT as it replaces the original version of the resource, whereas the PATCH method
supplies a set of instructions to modify the resource.
What is PUT?
PUT method is used to update resource available on the server. Typically, it replaces whatever exists at the
target URL with something else. You can use it to make a new resource or overwrite an existing one. PUT
requests that the enclosed entity must be stored under the supplied requested URI (Uniform Resource
Identifier).

GET
The  GET  method requests a representation of the specified resource. Requests using  GET  should only
retrieve data.

POST
The  POST  method submits an entity to the specified resource, often causing a change in state or side
effects on the server.

PATCH
The  PATCH  method applies partial modifications to a resource.

Ref Doc : HTTP request methods - HTTP | MDN (mozilla.org)

22)

Explicação
Its primary function is to design and develop fully functional Mule applications in a hosted development
environment which is the correct answer.

Flow Designer
In Flow Designer, you create Mule applications to integrate systems into workflows. You create them as
projects that have one or more flows. A project contains the flows for one Mule application. A flow consists of
a sequence of cards, with each card representing a core component, connector, module, or API. Each card
receives input data, carries out a specific task that makes use of the input data, and then sends the output
data from that task to the next card in the flow. The final card in a flow is usually one that sends a notification
that the Mule application has completed its task or that sends data.

Mule Ref Doc : Flow Designer | MuleSoft Documentation

23)
Explicação
Correct answer is Creates reusable APIs and assets designed to be consumed by other business units.

An application network is pretty simple; it is a way to connect applications, data and devices through APIs
that exposes some or all of their assets and data on the network. That network allows other consumers from
other parts of the business to come in and discover and use those assets. Building an application network
involves developing reusable assets and then encouraging those in the business to reuse and self-serve
those assets. Then, they can get used and reused in different ways inside the organization. Connections can
then be built between these assets. It is necessary to allow development teams in the business to build what
is needed — to self-serve the reusable assets created by others to in order to develop something new — and
then expose it to the rest of the organization to be reused.

Mule Ref Doc : What is an application network? | MuleSoft

24)

Explicação
Correct answer is Creates a mock service for an API

API Notebook is an open source, shareable web application for API documentation, interactive API tutorial
and example generatation, and a client for your API endpoints. Using API Notebook, you can make requests
and quickly transform the responses into readable format. However it cannot be used to mock service for an
API.

MuleSoft Doc Ref : https://docs.mulesoft.com/api-manager/1.x/api-notebook-concept

25)

Explicação
Correct answer is client-id-required
client-id-required enforces clients to add client_id and client_secret.

Please refer to below steps.


1) Add a section called traits: at the root level to define query parameters:
traits:

- client-id-required:
queryParameters:

client_id:

type: string

client_secret:

type: string

2) Reference the trait in each of the methods to specify that each of the methods require these query
parameters. After each method in the RAML file, add is: [client-id-required]. For example:
/users:

get:

is: [client-id-required]

description: Gets a list of JSONPlaceholder users.

26)

Explicação
Correct answer is Publish consume: Synchronous. Publish: Asynchronous.

Publish Messages and Consume Replies Using the JMS Connector :

Anypoint Connector for JMS (JMS Connector) Publish consume operation enables you to publish a
message to any specified destination, and then consume the message reply on a different specified
destination. Request and reply is a very common pattern between applications.

When using this operation, the  JMSReplyTo  header of the outgoing message contains the ID of the
destination on which your application waits to consume a response. The destination might be a well-known
destination or a temporary destination created with the purpose of receiving a single response message.

The result of the operation is the message received as a response, with the same structure as invoking the
Consume operation.

Mule Ref Doc : Publish Messages and Consume Replies Using the JMS Connector | MuleSoft
Documentation

Publish Messages Using the JMS Connector :


The Anypoint Connector for JMS (JMS Connector) Publish operation enables you to create a new JMS
message and send it to the specified destination, whether it is a queue or a topic. Using the operation, you
can configure not only the content of the message, but also any necessary headers.

Mule Ref Doc : Publish Messages Using the JMS Connector | MuleSoft Documentation
27)

Explicação
Correct answer is As query parameters in the HTTP Request operation

HTTP Request Connector


The HTTP Request Connector provides the most practical way to consume an external HTTP service. When
sending HTTP requests, you can choose what method to use (GET, POST, etc) and may include a body,
headers, attachments, query parameters, form parameters and URI parameters. The response is then
received by the connector and is passed on to the next element in your flow.

Mule Ref Doc : HTTP Connector 1.6 - Mule 4 | MuleSoft Documentation

You can dynamically pass query parameters by following below steps


In General > Request > Query Parameters, click the plus icon (+) to add a parameter to a request. Type a
name and value for the parameter or use a DataWeave expression to define the name and value.

28)

Explicação
Correct answer is Array of Mule event objects

List Files Using the File Connector


Use the  List  operation to list the files and folders in the path pointed to by the  directoryPath  parameter.
The  List  operation returns an array of messages in which:
Each message holds the file’s content in its payload.

The file’s attributes section carries the file’s metadata (such as name, creation time, and size).

The payload is empty if the element is a folder.

The  List  operation requires the  directoryPath  parameter, which represents the relative path of the directory
to list, unless you specify the full path of the directory. The path is relative to the working directory value
defined in the configuration referenced by the  config-ref  parameter. If no configuration is referenced, the
working directory defaults to the value of the  user.home  system property. If the system property is not set,
the connector fails to initialize.

For an example of setting a configuration, see File Connection Settings.

Next is an example of a  List  operation that references a file configuration and thus uses a relative path:
<file:list config-ref="File_Config" directoryPath="relativePath" />

As mentioned earlier, this returns an array of messages. In Anypoint Studio, DataSense displays the
metadata for the operation’s output:

29)
Explicação
Core (dw::Core) This module contains core DataWeave functions for data transformations. It is automatically
imported into any DataWeave script.

30)

Explicação
Correct answer is Specify throttling , security and other policies
MuleSoft Doc Ref : https://docs.mulesoft.com/api-manager/2.x/api-gateway-capabilities-mule4

API Gateway is responsible for below functions.


1) Determine which traffic is authorized
2) Meter the traffic
3) Logs transaction
4) Apply throttling and other policies (Not specifying. These are specified in API Manager)

You might also like