finished refactoring client for additions to protocol

This commit is contained in:
Aidan Hahn 2019-05-23 16:10:43 -07:00
parent 11d8516417
commit 9eb18219cb
No known key found for this signature in database
GPG key ID: 327711E983899316
2 changed files with 19 additions and 5 deletions

View file

@ -94,8 +94,25 @@ public class JobServClient {
}
int newProcess = this.api.sendNewJobMessage(command);
// TODO: switch here for negative returns
System.out.printf("Process started, assigned pid is %d\n", newProcess);
switch(newProcess) {
case -1:
System.out.println(this.serversideTimeoutErrorMessage);
break;
case -2:
System.out.println("Server failed to create job, check server logs.");
break;
case -3:
// error logged by API Connector
break;
default:
System.out.printf("Process started, assigned pid is %d\n", newProcess);
break;
}
return;
}
/*