Skip to content

Commit

Permalink
FSvms now goes around all agent caching
Browse files Browse the repository at this point in the history
This seesm to be better then to try to store soem fake FS agents (as
session agents) and deal with them.
  • Loading branch information
judovana committed Jun 10, 2022
1 parent 1c1e879 commit 71055fe
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -153,6 +153,11 @@ private static ResponseWithPort getResponse(
nativeAgent = new CallDecompilerAgent(actualListenPort, hostname);
} else {
VmInfo vmInfo = vmManager.findVmFromPid(vmId);
VmDecompilerStatus status = new VmDecompilerStatus();
status.setHostname("localhost");
status.setListenPort(vmPid);
status.setVmId(vmId);
vmInfo.setVmDecompilerStatus(status);
nativeAgent = FsAgent.get(vmInfo);
}
String reply = nativeAgent.submitRequest(requestBody);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,9 @@ public VmInfo(String vmId, int vmPid, String vmName, Type type, List<File> cp) {
}

public VmDecompilerStatus getVmDecompilerStatus() {
if (getType() == Type.FS) {
return vmDecompilerStatus;
}
if (vmDecompilerStatus != null) {
KnownAgents.getInstance().verifyAgents();
List<KnownAgent> found = KnownAgents.getInstance().findAgents(
Expand Down

0 comments on commit 71055fe

Please sign in to comment.