The code.ill.fr has been recreated and upgraded with the latest version this weekend, If you encounter any problem please inform the Helpdesk.

Commit 6c5d16ae authored by Locatelli's avatar Locatelli
Browse files

Start always ploty2, only nomadserver run offscreen plot

parent f7fed684
* Start always ploty2, only nomadserver run offscreen plot
4.0.23 25/06/2020
------
* Ploty2, pass instrument nomad server end point as argument
......
......@@ -90,30 +90,21 @@ public class PlotyInstance {
// nomad endpoint is build from selected instrument
nomadServerEndpoint = "tcp://" + SessionManager.getInstance(CommandZoneWrapper.SERVER_ID).getInstrumentName() + ":7000";
}
if (serverEndpoint.contentEquals(nomadServerEndpoint)) {
// Client on a same machine as server
try {
ploty = server.connect(PLOTY_NAME);
} catch (ConnectionTimeout e) {
System.err.println("Timeout while connecting " + PLOTY_NAME);
return false;
}
// Client on a different machine as server
List<Info> info = server.getApplicationInfos(PLOTY_NAME);
if (info.isEmpty() == false) {
server.killAllAndWaitFor(PLOTY_NAME);
}
else {
// Client on a different machine as server
List<Info> info = server.getApplicationInfos(PLOTY_NAME);
if (info.isEmpty() == false) {
server.killAllAndWaitFor(PLOTY_NAME);
}
// start ploty2 on remote
try {
String arg[] = {nomadServerEndpoint};
ploty = server.start(PLOTY_NAME, arg);
} catch (ConnectionTimeout e) {
System.err.println("Timeout while starting " + PLOTY_NAME);
return false;
}
// restart ploty2
try {
String arg[] = {nomadServerEndpoint};
ploty = server.start(PLOTY_NAME, arg);
} catch (ConnectionTimeout e) {
System.err.println("Timeout while starting " + PLOTY_NAME);
return false;
}
// Create the requester.
try {
plotRequester = Application.Requester.create(ploty, "plot_requester");
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment