You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
//the "main-branch" queue will have a concurrency limit of 10
115
+
//this triggered run will use that queue
116
+
name: "main-branch",
117
+
concurrencyLimit: 10,
118
+
},
119
+
},
120
+
});
121
+
122
+
returnResponse.json(handle);
123
+
} else {
124
+
//triggered with the default (concurrency of 1)
125
+
const handle =awaitgeneratePullRequest.trigger({
126
+
payload: data,
127
+
});
128
+
returnResponse.json(handle);
129
+
}
130
+
}
131
+
```
132
+
133
+
## Concurrency keys and per-tenant queuing
134
+
135
+
If you're building an application where you want to run tasks for your users, you might want a separate queue for each of your users. (It doesn't have to be users, it can be any entity you want to separately limit the concurrency for.)
136
+
137
+
You can do this by using `concurrencyKey`. It creates a separate queue for each value of the key.
0 commit comments