Skip to content
This repository was archived by the owner on Apr 25, 2025. It is now read-only.

Commit ef2ffa7

Browse files
committed
[FAB-8956] Reference correct config sections
Change-Id: Iff2e46ba4ac7413267e7c1e65cac3fa184ccdab2 Signed-off-by: Divyank Katira <Divyank.Katira@securekey.com>
1 parent 6ab7137 commit ef2ffa7

File tree

8 files changed

+12
-12
lines changed

8 files changed

+12
-12
lines changed

pkg/core/config/config.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -573,21 +573,21 @@ func (c *Config) getTimeout(tType core.TimeoutType) time.Duration {
573573
case core.OrdererResponse:
574574
timeout = c.configViper.GetDuration("client.orderer.timeout.response")
575575
case core.ChannelConfigRefresh:
576-
timeout = c.configViper.GetDuration("client.global.timeout.cache.channelConfig")
576+
timeout = c.configViper.GetDuration("client.global.cache.channelConfig")
577577
case core.ChannelMembershipRefresh:
578-
timeout = c.configViper.GetDuration("client.global.timeout.cache.channelMembership")
578+
timeout = c.configViper.GetDuration("client.global.cache.channelMembership")
579579
case core.CacheSweepInterval: // EXPERIMENTAL - do we need this to be configurable?
580580
timeout = c.configViper.GetDuration("client.cache.interval.sweep")
581581
if timeout == 0 {
582582
timeout = defaultCacheSweepInterval
583583
}
584584
case core.ConnectionIdle:
585-
timeout = c.configViper.GetDuration("client.global.timeout.cache.connectionIdle")
585+
timeout = c.configViper.GetDuration("client.global.cache.connectionIdle")
586586
if timeout == 0 {
587587
timeout = defaultConnIdleTimeout
588588
}
589589
case core.EventServiceIdle:
590-
timeout = c.configViper.GetDuration("client.global.timeout.cache.eventServiceIdle")
590+
timeout = c.configViper.GetDuration("client.global.cache.eventServiceIdle")
591591
if timeout == 0 {
592592
timeout = defaultEventServiceIdleTimeout
593593
}

pkg/core/config/config_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -389,8 +389,8 @@ func TestTimeouts(t *testing.T) {
389389
configImpl.configViper.Set("client.global.timeout.query", "7h")
390390
configImpl.configViper.Set("client.global.timeout.execute", "8h")
391391
configImpl.configViper.Set("client.global.timeout.resmgmt", "118s")
392-
configImpl.configViper.Set("client.global.timeout.cache.connectionIdle", "1m")
393-
configImpl.configViper.Set("client.global.timeout.cache.eventServiceIdle", "2m")
392+
configImpl.configViper.Set("client.global.cache.connectionIdle", "1m")
393+
configImpl.configViper.Set("client.global.cache.eventServiceIdle", "2m")
394394
configImpl.configViper.Set("client.orderer.timeout.response", "6s")
395395

396396
t1 := configImpl.TimeoutOrDefault(api.EndorserConnection)

test/fixtures/config/config_pkcs11_test.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ client:
6060
resmgmt: 60s
6161
cache:
6262
connectionIdle: 30s
63-
eventServiceIdle: 30s
63+
eventServiceIdle: 2m
6464
channelConfig: 60s
6565
channelMembership: 30s
6666

test/fixtures/config/config_revoke_test.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ client:
6161
resmgmt: 60s
6262
cache:
6363
connectionIdle: 30s
64-
eventServiceIdle: 500ms
64+
eventServiceIdle: 2m
6565
channelConfig: 60s
6666
channelMembership: 30s
6767

test/fixtures/config/config_test.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ client:
6161
resmgmt: 60s
6262
cache:
6363
connectionIdle: 30s
64-
eventServiceIdle: 500ms
64+
eventServiceIdle: 2m
6565
channelConfig: 60s
6666
channelMembership: 30s
6767

test/fixtures/config/config_test_local.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ client:
6363
resmgmt: 60s
6464
cache:
6565
connectionIdle: 30s
66-
eventServiceIdle: 500ms
66+
eventServiceIdle: 2m
6767
channelConfig: 60s
6868
channelMembership: 30s
6969

test/fixtures/config/config_test_no_orderer.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ client:
6161
resmgmt: 60s
6262
cache:
6363
connectionIdle: 30s
64-
eventServiceIdle: 30s
64+
eventServiceIdle: 2m
6565
channelConfig: 60s
6666
channelMembership: 30s
6767

test/fixtures/config/config_test_no_orderer_local.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ client:
6363
resmgmt: 60s
6464
cache:
6565
connectionIdle: 30s
66-
eventServiceIdle: 30s
66+
eventServiceIdle: 2m
6767
channelConfig: 60s
6868
channelMembership: 30s
6969

0 commit comments

Comments
 (0)