Skip to content

Commit 6c5a58f

Browse files
authored
Merge pull request kubernetes-client#635 from bacongobbler/remove-net-keepalive
fix: remove dependency on net-keepalive
2 parents a3e1501 + a3e6c0a commit 6c5a58f

File tree

3 files changed

+6
-87
lines changed

3 files changed

+6
-87
lines changed

package-lock.json

Lines changed: 5 additions & 83 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,6 @@
6666
"isomorphic-ws": "^4.0.1",
6767
"js-yaml": "^3.13.1",
6868
"jsonpath-plus": "^0.19.0",
69-
"net-keepalive": "2.0.4",
7069
"openid-client": "^4.1.1",
7170
"request": "^2.88.0",
7271
"rfc4648": "^1.3.0",

src/watch.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
import byline = require('byline');
2-
import keepalive = require('net-keepalive');
32
import request = require('request');
43
import { Duplex } from 'stream';
54
import { KubeConfig } from './config';
@@ -115,8 +114,7 @@ export class Watch {
115114
req.on('error', doneCallOnce);
116115
req.on('socket', (socket) => {
117116
socket.setTimeout(30000);
118-
socket.setKeepAlive(true);
119-
keepalive.setKeepAliveInterval(socket, 30000);
117+
socket.setKeepAlive(true, 30000);
120118
});
121119
stream.on('error', doneCallOnce);
122120
stream.on('close', () => doneCallOnce(null));

0 commit comments

Comments
 (0)