Skip to content

Commit

Permalink
Merge pull request #1768 from igorcalabria/iss_1767
Browse files Browse the repository at this point in the history
  • Loading branch information
fusesource-ci authored Sep 17, 2019
2 parents e4bec25 + 23afe5b commit 84eb247
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 2 deletions.
10 changes: 10 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,16 @@

### 4.5-SNAPSHOT
#### Bugs
* Fix #1767: Removed fixed override for Okhttp client's `pingInterval`

#### Improvements

#### Dependency Upgrade

#### New Feature

### 4.5.2 (14-09-2019)
#### Bugs
* Fix #1759: Portforwarding is broken

#### Improvements
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ public class Config {
public static final Long DEFAULT_SCALE_TIMEOUT = 10 * 60 * 1000L;
public static final int DEFAULT_LOGGING_INTERVAL = 20 * 1000;
public static final Long DEFAULT_WEBSOCKET_TIMEOUT = 5 * 1000L;
public static final Long DEFAULT_WEBSOCKET_PING_INTERVAL = 1 * 1000L;
public static final Long DEFAULT_WEBSOCKET_PING_INTERVAL = 30 * 1000L;

public static final Integer DEFAULT_MAX_CONCURRENT_REQUESTS = 64;
public static final Integer DEFAULT_MAX_CONCURRENT_REQUESTS_PER_HOST = 5;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,6 @@ public WatchConnectionManager(final OkHttpClient client, final BaseOperation<T,
this.maxIntervalExponent = maxIntervalExponent;

this.clonedClient = client.newBuilder()
.pingInterval(30, TimeUnit.SECONDS)
.readTimeout(this.websocketTimeout, TimeUnit.MILLISECONDS)
.build();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -460,6 +460,13 @@ public void shouldBeUsedTokenSuppliedByProvider() throws Exception {
assertEquals("PROVIDER_TOKEN", config.getOauthToken());
}

@Test
public void shouldHonorDefaultWebsocketPingInterval() {
Config config = new ConfigBuilder().build();

assertEquals(30000L, config.getWebsocketPingInterval());
}

private void assertConfig(Config config) {
assertNotNull(config);
assertTrue(config.isTrustCerts());
Expand Down

0 comments on commit 84eb247

Please sign in to comment.