git-svn-id: http://svn.research-infrastructures.eu/public/d4science/gcube/trunk/vre-management/VREModeler@8596 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
4153d838f7
commit
7491ee3434
|
@ -76,17 +76,24 @@ public class DeployVRE extends Thread{
|
|||
while (resRelatedGHN.next()) GHNList.add(resRelatedGHN.getString(1));
|
||||
|
||||
|
||||
if (deployManagerOnVRE(firstGHNId) && createVRE(GHNList, firstGHNId)){
|
||||
DBInterface.ExecuteUpdate("UPDATE VRE SET STATUS='"+ModelerService.DEPLOYED+"' WHERE VRE.id='"+this.resourceId+"';");
|
||||
logger.info("Deploying of the VRE with id "+this.resourceId+" FINISHED");
|
||||
if (!deployManagerOnVRE(firstGHNId)){
|
||||
if (!createVRE(GHNList, firstGHNId)){
|
||||
DBInterface.ExecuteUpdate("UPDATE VRE SET STATUS='"+ModelerService.DEPLOYED+"' WHERE VRE.id='"+this.resourceId+"';");
|
||||
logger.info("Deploying of the VRE with id "+this.resourceId+" FINISHED");
|
||||
}
|
||||
else{
|
||||
logger.info("Deploying of the VRE with id "+this.resourceId+" FAILED on second step");
|
||||
throw new Exception("Error Deployng the VRE failed on second step");
|
||||
}
|
||||
}else{
|
||||
logger.info("Deploying of the VRE with id "+this.resourceId+" FAILED");
|
||||
throw new Exception("Error Deployng the VRE");
|
||||
getResource().setReportSecondStep("FAILED");
|
||||
logger.info("Deploying of the VRE with id "+this.resourceId+" FAILED on first step");
|
||||
throw new Exception("Error Deployng the VRE filed on first step");
|
||||
}
|
||||
}catch(Exception e){
|
||||
try {
|
||||
DBInterface.ExecuteUpdate("UPDATE VRE SET STATUS='"+ModelerService.FAILED+"' WHERE VRE.id='"+this.resourceId+"';");
|
||||
} catch (GCUBEFault e1) {
|
||||
} catch (Exception e1) {
|
||||
logger.error("impossible to update the VRE Status");
|
||||
e1.printStackTrace();
|
||||
}
|
||||
|
@ -145,6 +152,7 @@ public class DeployVRE extends Thread{
|
|||
System.out.println("---------");
|
||||
}while (!isDeploymentStatusFinished(report) && attempt<10);
|
||||
}catch(Exception e){e.printStackTrace(); throw e;}
|
||||
System.out.println( "is something failed in the first step?"+isSomethingFailed(report));
|
||||
return isSomethingFailed(report);
|
||||
}
|
||||
};
|
||||
|
@ -303,6 +311,7 @@ public class DeployVRE extends Thread{
|
|||
getResource().setReportSecondStep(report);
|
||||
|
||||
}while (!isDeploymentStatusFinished(report) && attempt<20);
|
||||
System.out.println( "is something failed in the second step?"+isSomethingFailed(report));
|
||||
return isSomethingFailed(report);
|
||||
}
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue