Skip to content

Commit 083dd7d

Browse files
committed
fix: BucketOptions -> QueueOptions
1 parent 610c599 commit 083dd7d

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

packages/task-herder/src/TaskQueue.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import pLimit, { type LimitFunction } from 'p-limit'
22
import { CancelReason } from './CancelReason'
33
import { TaskRecord, type TaskOptions } from './TaskRecord'
44

5-
export interface BucketOptions {
5+
export interface QueueOptions {
66
/** The maximum number of tokens in the bucket controls the burst limit */
77
burstLimit: number
88
/** Rate at which tokens are added to the bucket (tokens per second) controls the sustained rate */
@@ -37,7 +37,7 @@ export class TaskQueue {
3737
private timeout: number | null = null
3838
private lastRefillTime: number = Date.now()
3939

40-
constructor(options: BucketOptions) {
40+
constructor(options: QueueOptions) {
4141
this.burstLimit = options.burstLimit
4242
this.sustainRate = options.sustainRate
4343
this.tokenCount = options.startingTokens ?? options.burstLimit

packages/task-herder/src/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
export { CancelReason } from './CancelReason'
2-
export { type BucketOptions, TaskQueue } from './TaskQueue'
2+
export { type QueueOptions, TaskQueue } from './TaskQueue'

0 commit comments

Comments
 (0)