---
schema_version: "1"
id: be9f80feb4c92d670257bb34943b27ac15f2839203edd24eb2956dbf0fbcd876
title: wait
collection: mulesoft
version: current
locale: en-us
portal_url: https://docs.salesforce.com/mulesoft/current/en-us/dataweave/2.3/dw-runtime-functions-wait.md
canonical_url: https://docs.mulesoft.com/dataweave/2.3/dw-runtime-functions-wait
source_site: docs.mulesoft.com
content_type: documentation
content_hash: 833cd8b5fc8399429427c41f27c894cca48abb24cfadab03da1321224fde0f5c
description: MuleSoft Documentation Site
release: "2.3"
latest: false
---
---
product: DataWeave
version: 2.3
---

# wait

> For the full documentation index, see: https://docs.mulesoft.com/llms.txt

## wait(T, Number): T

Stops the execution for the specified timeout (in milliseconds).

> [!WARNING] Stopping the execution will block the thread used, potentially causing slowness, low
> performance and potentially freezes of the entire runtime. This operation is intented for limited
> functional testing purposes and should not be used in production application, performance testing
> or with multiple applications deployed.

### Parameters

<table><colgroup><col> <col></colgroup><thead><tr><th>Name</th><th>Description</th></tr></thead><tbody><tr><td><p><code>value</code></p></td><td><p>Input of any type.</p></td></tr><tr><td><p><code>timeout</code></p></td><td><p>The number of milliseconds to wait.</p></td></tr></tbody></table>

### Example

This example waits 2000 milliseconds (2 seconds) to execute.

#### Source

```DataWeave
%dw 2.0
import * from dw::Runtime
output application/json
---
{ "user" : 1 } wait 2000
```

#### Output

```JSON
{ "user": 1 }
```
