We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent b443a03 commit 20e2db8Copy full SHA for 20e2db8
frontend/server/src/main/java/org/pytorch/serve/wlm/WorkerLifeCycle.java
@@ -380,10 +380,15 @@ public void terminate() {
380
@Override
381
public void run() {
382
try (Scanner scanner = new Scanner(is, StandardCharsets.UTF_8.name())) {
383
- while (scanner.hasNext()) {
+ while (scanner.hasNextLine()) {
384
String result = scanner.nextLine();
385
- if (result == null && !isRunning.get()) {
386
- break;
+ if (result == null) {
+ if (isRunning.get()) {
387
+ continue;
388
+ }
389
+ else {
390
+ break;
391
392
}
393
394
Matcher matcher = METRIC_PATTERN.matcher(result);
0 commit comments