ExamGecko
Home / MuleSoft / MCD - Level 1
Ask Question

MuleSoft MCD - Level 1 Practice Test - Questions Answers, Page 8

Question list
Search

List of questions

Search

Related questions











Question 71

Report
Export
Collapse

Refer to the exhibit.

The error occurs when a project is run in Anypoint Studio. The project, which has a dependency that is not in the MuleSoft Maven repository, was created and successfully run on a different computer.

What is the next step to fix the error to get the project to run successfully?

MuleSoft MCD - Level 1 image Question 71 52626 09182024213609000000

Edit the dependency in the Mule project's pom.xml file
Edit the dependency in the Mule project's pom.xml file
Install the dependency to the computer's local Maven repository
Install the dependency to the computer's local Maven repository
Deploy the dependency to MuleSoft's Maven repository
Deploy the dependency to MuleSoft's Maven repository
Add the dependency to the MULE_HOME/bin folder
Add the dependency to the MULE_HOME/bin folder
Suggested answer: B

Explanation:

As dependency is not present in Mulesoft Maven repository, we need to install the dependency on computer's local Maven repository.

https://docs.mulesoft.com/mule-runtime/4.3/maven-reference

asked 18/09/2024
Joshin Ogele
35 questions

Question 72

Report
Export
Collapse

A web client submits a request to http://localhost:8081?flrstName=john. What is the correct DataWeave expression to access the firstName parameter?

#[attributes.queryParams.firstName]
#[attributes.queryParams.firstName]
#[message.queryParams.hrstName]
#[message.queryParams.hrstName]
#[message.inboundProperties.'http.query.params'.firstName]
#[message.inboundProperties.'http.query.params'.firstName]
#[attributes.'http.query.params'.firstName]
#[attributes.'http.query.params'.firstName]
Suggested answer: A
asked 18/09/2024
Latonya Ganison
27 questions

Question 73

Report
Export
Collapse

By default, what happens to a file after it is read using an FTP connector Read operation?

The file is deleted from the folder
The file is deleted from the folder
The file is moved to a different folder
The file is moved to a different folder
The file stays in the same folder unchanged
The file stays in the same folder unchanged
The file is renamed in the same folder
The file is renamed in the same folder
Suggested answer: C

Explanation:

File is not updated when FTP read operations is performed.

MuleSoft Doc Ref : https://docs.mulesoft.com/file-connector/1.3/file-read

asked 18/09/2024
Sriharsha Janga
43 questions

Question 74

Report
Export
Collapse

Refer to the exhibits.

MuleSoft MCD - Level 1 image Question 74 52629 09182024213609000000

MuleSoft MCD - Level 1 image Question 74 52629 09182024213609000000

The Validation component in the Try scope throws an error.

What response message is returned to a client request to the main flow's HTTP Listener?

The Validation component in the Try scope throws an error. What response message is returned to a client request to the main flow's HTTP Listener?

Success - main flow
Success - main flow
Error - main flow
Error - main flow
Error - Try scope
Error - Try scope
Validation Error
Validation Error
Suggested answer: A

Explanation:

Note that private flow has error scope defined as On Error Continue . So when error occurs in private flow , it is handled by this On Error Continue scope which sends success response back to main flow and does not throw back an error. So main continues normally and payload is set to Success - main flow.

Hence correct answer isSuccess - main flow

1) HTTP listener received request

2) The Flow Reference calls the child flow

3) The Is Number validator creates an Error Object because the payload isn't an integer. Child Flow execution stops

#[error.description] = ''payload is not a valid INTEGER value''

#[error.errorType] = VALIDATION:INVALID_NUMBER

4) The On Error Continue handles the errorThe payload is set to ''Error -- Sub Flow''

5) ''Error -- Sub Flow'' is returned to the main flow as if the child flow was a success. The Set Payload is executed. The payload is reset to ''Success -- Finished Main Flow''

6) ''Success -- Main Flow'' is returned to the requestor in the body of the HTTP request. HTTP Status Code: 200

As you can see, in the above example, because the error was caught by an On Error Continue scope in the child flow (RED in, GREEN out) when the Mule Message returns to the parent flow, the parent flow knows none-the-different that there was a failure because the on error continue returns a 200 success message. Note that because, to the mainFlow, the childFlow appeared to succeed, the processing of mainFlow resumed after the flow reference.

MuleSoft MCD - Level 1 image Question 74 explanation 52629 09182024213609000000

asked 18/09/2024
Jerin cherian
37 questions

Question 75

Report
Export
Collapse

Refer to the exhibit.

MuleSoft MCD - Level 1 image Question 75 52630 09182024213609000000

What is a valid expression for the Choice router's when expression to route events to the documenticShipping flow?

0#[ payload = 'US' ]
0#[ payload = 'US' ]
#[ payload == 'US' J
#[ payload == 'US' J
#[ if(payload = 'US') J
#[ if(payload = 'US') J
#[ if(payload == 'US') ]
#[ if(payload == 'US') ]
Suggested answer: B

Explanation:

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 anif/then/elsecode block in most programming languages.

Only one of the routes in the Choice router executes, meaning that the first expression that evaluates totruetriggers that route's execution and the others are not checked. If none of the expressions aretrue, then the default route executes.

Properties of <when>

PropertyDescription

Expression (expression)

Expression in DataWeave language to evaluate input. If the expression evaluates totrue, this routing option is used:

<when expression='#[vars.language == 'Spanish']' >

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

With respect to above information ,

Option 1 is the correct syntax as others are incorrect because of below reasons

* Single = is not the correct syntax to validate the condition. It should be ==

* If keyword is not required in when condition.

asked 18/09/2024
lakshmi govindu
43 questions

Question 76

Report
Export
Collapse

A web client submits a request to http://localhost:8081?accountType=personal. The query parameter is captured using a Set Variable transformer to a variable named accountType.

What is the correct DataWeave expression to log accountType?

Account Type: #[flowVars.accountType]
Account Type: #[flowVars.accountType]
Account Type: #[message.inboundProperties.accountType]
Account Type: #[message.inboundProperties.accountType]
Account Type: # [attributes.accountType]
Account Type: # [attributes.accountType]
Account Type: #[vars.accountType]
Account Type: #[vars.accountType]
Suggested answer: D

Explanation:

vars: Keyword for accessing a variable, for example, through a DataWeave expression in a Mule component, such as the Logger, or from an Input or Output parameter of an operation. If the name of your variable is myVar, you can access it like this: vars.myVar

Hence correct answer is Account Type: #[vars.accountType]

asked 18/09/2024
piera d'addelfio
33 questions

Question 77

Report
Export
Collapse

Refer to the exhibit. The Batch Job processes, filters and aggregates records, What is the expected output from the Logger component?

MuleSoft MCD - Level 1 image Question 77 52632 09182024213609000000

MuleSoft MCD - Level 1 image Question 77 52632 09182024213609000000

[10. 20, 30. 40, 50, 60]
[10. 20, 30. 40, 50, 60]
[10. 20] [30, 40] [50, 60]
[10. 20] [30, 40] [50, 60]
[20, 40, 60]
[20, 40, 60]
[20. 40] [60]
[20. 40] [60]
Suggested answer: D

Explanation:

* Batch scope has filter criteria which says paylod mod 2 = 0 whch means only 2, 4 and 6 will be in batch scope.

* So payload for each of these will be incremented by 10.

* Aggregator has batch size defined as 2. So it will process in batch of two records.

* Hence option 3 is correct answer.

[20,40]

[60]

Behavior with aggregator configured with fixed size

In this scenario, the batch step sends the processed records to an aggregator, which starts processing the records and buffering them until the configured aggregator's size is reached. After that, the aggregator sends the aggregated records to the stepping queue.

MuleSoft MCD - Level 1 image Question 77 explanation 52632 09182024213609000000

The batch job builds record blocks of the configured block size and sends them to their corresponding batch step for processing. Each batch step receives one or more record blocks and starts processing them in parallel. After the batch step processes a record, the batch step sends the record to the aggregator for further processing. The aggregator continues processing records until the number of aggregated records reaches the configured aggregator's size.

https://docs.mulesoft.com/mule-runtime/4.3/batch-processing-concept

asked 18/09/2024
Mitesh Patel
44 questions

Question 78

Report
Export
Collapse

Refer to the exhibits.

MuleSoft MCD - Level 1 image Question 78 52633 09182024213609000000

The input array of strings is processed by the batch job that processes, filters, and aggregates the values. What is the last message logged by the Logger component after the batch job completes processing?

[ ['A', 'C', 'D' ], ['E'] ]
[ ['A', 'C', 'D' ], ['E'] ]
[''E'']
[''E'']
[''D', 'E']
[''D', 'E']
[ 'A', 'C, 'D', 'E' ]
[ 'A', 'C, 'D', 'E' ]
Suggested answer: B

Explanation:

Logs would look like:

INFO 2021-06-09 19:14:56,039 [[MuleRuntime].uber.06: [validationtest].batch-job-validationtestBatch_Job-work-manager @6de10f3e] [processor: validationtestFlow/processors/1/route/0/route/0/aggregator/processors/0; event: bfb751e1-9939-11eb-9f69-02053763653a] org.mule.runtime.core.internal.processor.LoggerMessageProcessor:

[

''\''A\'''',

''\''C\'''',

''\''D\''''

]

----

INFO 2021-06-09 19:15:02,486 [[MuleRuntime].uber.06: [validationtest].batch-job-validationtestBatch_Job-work-manager @6de10f3e] [processor: validationtestFlow/processors/1/route/0/route/0/aggregator/processors/0; event: bfb751e1-9939-11eb-9f69-02053763653a] org.mule.runtime.core.internal.processor.LoggerMessageProcessor: [

''\''E\''''

]

Batch aggregator value is 3. Hence in first time it will print[''A'', ''C'', ''D'']and in next iteration it will print[ ''E'' ]

--------------------------------------------------------------------------------------------------------------------------------------------------

Correct answer is[ ''E'' ]

asked 18/09/2024
Michel van Klaveren
38 questions

Question 79

Report
Export
Collapse

Refer to the exhibit. The input array of strings is passed to the batch job, which does NOT do any filtering or aggregating. What payload is logged by the Logger component?

MuleSoft MCD - Level 1 image Question 79 52634 09182024213609000000

Summary report of processed records
Summary report of processed records
[ 'Apple', 'Banana' ]
[ 'Apple', 'Banana' ]
[ 'Apptel2', 'Bananal2' ]
[ 'Apptel2', 'Bananal2' ]
[ 'Apptel', 'Bananal', 2 ]
[ 'Apptel', 'Bananal', 2 ]
Suggested answer: A
asked 18/09/2024
Aejaz Rab
28 questions

Question 80

Report
Export
Collapse

Refer to the exhibits. A company has defined this Book data type and Book example to be used in APIs. What is valid RAML for an API that uses this Book data type and Book example?

MuleSoft MCD - Level 1 image Question 80 52635 09182024213609000000

A)

MuleSoft MCD - Level 1 image Question 80 52635 09182024213609000000

B)

MuleSoft MCD - Level 1 image Question 80 52635 09182024213609000000

C)

MuleSoft MCD - Level 1 image Question 80 52635 09182024213609000000

D)

MuleSoft MCD - Level 1 image Question 80 52635 09182024213609000000

Option A
Option A
Option B
Option B
Option C
Option C
Option D
Option D
Suggested answer: D
asked 18/09/2024
Cheikh Ndiaye
34 questions
Total 235 questions
Go to page: of 24