Skip to content

Commit e92e227

Browse files
committed
feat(sdk,core): drop the combined concurrency override client methods
The combined override and reset never ship; runtime management of the new named limits arrives with its own management API.
1 parent 658569e commit e92e227

2 files changed

Lines changed: 0 additions & 120 deletions

File tree

packages/core/src/v3/apiClient/index.ts

Lines changed: 0 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -1704,51 +1704,6 @@ export class ApiClient {
17041704
);
17051705
}
17061706

1707-
overrideQueueCombinedConcurrencyLimit(
1708-
queue: RetrieveQueueParam,
1709-
concurrencyLimit: number,
1710-
requestOptions?: ZodFetchOptions
1711-
) {
1712-
const type = typeof queue === "string" ? "id" : queue.type;
1713-
const value = typeof queue === "string" ? queue : queue.name;
1714-
1715-
const encodedValue = encodeURIComponent(value.replace(/\//g, "%2F"));
1716-
1717-
return zodfetch(
1718-
QueueItem,
1719-
`${this.baseUrl}/api/v1/queues/${encodedValue}/concurrency/combined/override`,
1720-
{
1721-
method: "POST",
1722-
headers: this.#getHeaders(false),
1723-
body: JSON.stringify({
1724-
type,
1725-
concurrencyLimit,
1726-
}),
1727-
},
1728-
mergeRequestOptions(this.defaultRequestOptions, requestOptions)
1729-
);
1730-
}
1731-
1732-
resetQueueCombinedConcurrencyLimit(queue: RetrieveQueueParam, requestOptions?: ZodFetchOptions) {
1733-
const type = typeof queue === "string" ? "id" : queue.type;
1734-
const value = typeof queue === "string" ? queue : queue.name;
1735-
1736-
const encodedValue = encodeURIComponent(value.replace(/\//g, "%2F"));
1737-
1738-
return zodfetch(
1739-
QueueItem,
1740-
`${this.baseUrl}/api/v1/queues/${encodedValue}/concurrency/combined/reset`,
1741-
{
1742-
method: "POST",
1743-
headers: this.#getHeaders(false),
1744-
body: JSON.stringify({
1745-
type,
1746-
}),
1747-
},
1748-
mergeRequestOptions(this.defaultRequestOptions, requestOptions)
1749-
);
1750-
}
1751-
17521707
subscribeToRun<TRunTypes extends AnyRunTypes>(
17531708
runId: string,
17541709
options?: {

packages/trigger-sdk/src/v3/queues.ts

Lines changed: 0 additions & 75 deletions
Original file line numberDiff line numberDiff line change
@@ -172,81 +172,6 @@ export function overrideConcurrencyLimit(
172172
return apiClient.overrideQueueConcurrencyLimit(queue, concurrencyLimit, $requestOptions);
173173
}
174174

175-
/**
176-
* Overrides the combined concurrency limit of a queue: the cap on concurrent runs across
177-
* all of its `concurrencyKey` values.
178-
*
179-
* @param queue - The ID of the queue, or the type and name
180-
* @param concurrencyLimit - The combined concurrency limit to apply
181-
* @returns The updated queue state
182-
*/
183-
export function overrideCombinedConcurrencyLimit(
184-
queue: RetrieveQueueParam,
185-
concurrencyLimit: number,
186-
requestOptions?: ApiRequestOptions
187-
): ApiPromise<QueueItem> {
188-
const apiClient = apiClientManager.clientOrThrow();
189-
190-
const $requestOptions = mergeRequestOptions(
191-
{
192-
tracer,
193-
name: "queues.overrideCombinedConcurrencyLimit()",
194-
icon: "queue",
195-
attributes: {
196-
...flattenAttributes({ queue }),
197-
...accessoryAttributes({
198-
items: [
199-
{
200-
text: typeof queue === "string" ? queue : queue.name,
201-
variant: "normal",
202-
},
203-
],
204-
style: "codepath",
205-
}),
206-
},
207-
},
208-
requestOptions
209-
);
210-
211-
return apiClient.overrideQueueCombinedConcurrencyLimit(queue, concurrencyLimit, $requestOptions);
212-
}
213-
214-
/**
215-
* Resets the combined concurrency limit of a queue back to its declared value.
216-
*
217-
* @param queue - The ID of the queue, or the type and name
218-
* @returns The updated queue state
219-
*/
220-
export function resetCombinedConcurrencyLimit(
221-
queue: RetrieveQueueParam,
222-
requestOptions?: ApiRequestOptions
223-
): ApiPromise<QueueItem> {
224-
const apiClient = apiClientManager.clientOrThrow();
225-
226-
const $requestOptions = mergeRequestOptions(
227-
{
228-
tracer,
229-
name: "queues.resetCombinedConcurrencyLimit()",
230-
icon: "queue",
231-
attributes: {
232-
...flattenAttributes({ queue }),
233-
...accessoryAttributes({
234-
items: [
235-
{
236-
text: typeof queue === "string" ? queue : queue.name,
237-
variant: "normal",
238-
},
239-
],
240-
style: "codepath",
241-
}),
242-
},
243-
},
244-
requestOptions
245-
);
246-
247-
return apiClient.resetQueueCombinedConcurrencyLimit(queue, $requestOptions);
248-
}
249-
250175
/**
251176
* Resets the concurrency limit of a queue to the base value.
252177
*

0 commit comments

Comments
 (0)