Skip to content

Commit 085f068

Browse files
committed
fix(plc4go): increase response grab timeout to avoid edge cases on slow machines
1 parent 670623b commit 085f068

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

plc4go/pkg/api/cache/PlcConnectionCache.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ func NewPlcConnectionCache(driverManager plc4go.PlcDriverManager, withConnection
5252
driverManager: driverManager,
5353
maxLeaseTime: maxLeaseTime,
5454
maxWaitTime: maxLeaseTime * 5,
55-
responseGrabTimeout: 10 * time.Millisecond,
55+
responseGrabTimeout: 5 * time.Second,
5656
cacheLock: lock.NewCASMutex(),
5757
connections: make(map[string]*connectionContainer),
5858
tracer: nil,
@@ -75,7 +75,7 @@ func WithMaxLeaseTime(maxLeaseTime time.Duration) WithConnectionCacheOption {
7575

7676
func WithMaxWaitTime(maxWaitTime time.Duration) WithConnectionCacheOption {
7777
return func(plcConnectionCache *plcConnectionCache) {
78-
plcConnectionCache.maxLeaseTime = maxWaitTime
78+
plcConnectionCache.maxWaitTime = maxWaitTime
7979
}
8080
}
8181

0 commit comments

Comments
 (0)