Skip to content

Commit 970ed2b

Browse files
authored
Merge pull request #900 from yue9944882/feat/exec-resize
Feat: Implementing resizable/error exec stream
2 parents 0a0e37c + cdfedcf commit 970ed2b

File tree

1 file changed

+9
-1
lines changed
  • util/src/main/java/io/kubernetes/client

1 file changed

+9
-1
lines changed

util/src/main/java/io/kubernetes/client/Exec.java

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -349,7 +349,7 @@ static int parseExitCode(ApiClient client, InputStream inputStream) {
349349
return -1;
350350
}
351351

352-
protected static class ExecProcess extends Process {
352+
public static class ExecProcess extends Process {
353353
private final WebSocketStreamHandler streamHandler;
354354
private int statusCode = -1;
355355
private boolean isAlive = true;
@@ -425,6 +425,14 @@ public InputStream getErrorStream() {
425425
return getInputStream(2);
426426
}
427427

428+
public InputStream getConnectionErrorStream() {
429+
return getInputStream(3);
430+
}
431+
432+
public OutputStream getResizeStream() {
433+
return streamHandler.getOutputStream(4);
434+
}
435+
428436
private synchronized InputStream getInputStream(int stream) {
429437
if (!input.containsKey(stream)) {
430438
input.put(stream, streamHandler.getInputStream(stream));

0 commit comments

Comments
 (0)