Skip to content

Commit 3428734

Browse files
committed
update...
1 parent 6b39728 commit 3428734

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

runner_impl.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -55,10 +55,10 @@ func WithSequentialParallelism() RunnerOption {
5555
// This is a concurrency rate-limiter for when the number of tasks
5656
// can be high. At any point, there are at most `max`
5757
// task (goroutines) running concurrently.
58-
func WithMaxParallelism(max int) RunnerOption {
58+
func WithMaxParallelism(mx int) RunnerOption {
5959
var permit Permits = noopPermit{}
60-
if max >= 1 {
61-
permit = newSemaphorePermit(max)
60+
if mx >= 1 {
61+
permit = newSemaphorePermit(mx)
6262
}
6363
return runnerOptionFunc(func(r *taskRunner) {
6464
r.permits = permit

scheduler_impl.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -52,12 +52,12 @@ func WithSchedulerPoolSize(size int) SchedulerOption {
5252
})
5353
}
5454

55-
func WithSchedulerMaxPoolSize(max int) SchedulerOption {
56-
if max < 1 {
55+
func WithSchedulerMaxPoolSize(mx int) SchedulerOption {
56+
if mx < 1 {
5757
panic("Max pool size cannot be < 1")
5858
}
5959
return schedulerOptionFunc(func(s *schedulerImpl) {
60-
s.maxPoolSize = max
60+
s.maxPoolSize = mx
6161
})
6262
}
6363

0 commit comments

Comments
 (0)