Skip to content

Commit a7fb794

Browse files
authored
Merge pull request #605 from libp2p/defaults/update-concurrency
Update default concurrency parameter
2 parents f006c07 + e1453da commit a7fb794

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

dht_options.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ var defaults = func(o *config) error {
117117
o.maxRecordAge = time.Hour * 36
118118

119119
o.bucketSize = defaultBucketSize
120-
o.concurrency = 3
120+
o.concurrency = 10
121121
o.resiliency = 3
122122

123123
o.v1CompatibleMode = true
@@ -281,7 +281,7 @@ func BucketSize(bucketSize int) Option {
281281

282282
// Concurrency configures the number of concurrent requests (alpha in the Kademlia paper) for a given query path.
283283
//
284-
// The default value is 3.
284+
// The default value is 10.
285285
func Concurrency(alpha int) Option {
286286
return func(c *config) error {
287287
c.concurrency = alpha

dht_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,8 @@ import (
2424
"github.com/stretchr/testify/assert"
2525
"github.com/stretchr/testify/require"
2626

27-
pb "github.com/libp2p/go-libp2p-kad-dht/pb"
2827
test "github.com/libp2p/go-libp2p-kad-dht/internal/testing"
28+
pb "github.com/libp2p/go-libp2p-kad-dht/pb"
2929

3030
"github.com/ipfs/go-cid"
3131
u "github.com/ipfs/go-ipfs-util"

0 commit comments

Comments
 (0)