Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ protected ResponseEntity<Object> handleStudyException(StudyException exception)
SECURITY_ANALYSIS_NOT_FOUND,
SENSITIVITY_ANALYSIS_NOT_FOUND,
SHORT_CIRCUIT_ANALYSIS_NOT_FOUND,
NON_EVACUATED_ENERGY_NOT_FOUND,
DYNAMIC_SIMULATION_NOT_FOUND,
DYNAMIC_MAPPING_NOT_FOUND,
EQUIPMENT_NOT_FOUND,
Expand All @@ -59,7 +58,6 @@ protected ResponseEntity<Object> handleStudyException(StudyException exception)
LOADFLOW_RUNNING,
SECURITY_ANALYSIS_RUNNING,
SENSITIVITY_ANALYSIS_RUNNING,
NON_EVACUATED_ENERGY_RUNNING,
DYNAMIC_SIMULATION_RUNNING,
SHORT_CIRCUIT_ANALYSIS_RUNNING,
VOLTAGE_INIT_RUNNING,
Expand Down Expand Up @@ -93,7 +91,6 @@ protected ResponseEntity<Object> handleStudyException(StudyException exception)
GET_MODIFICATIONS_FAILED,
GET_NETWORK_ELEMENT_FAILED,
SENSITIVITY_ANALYSIS_ERROR,
NON_EVACUATED_ENERGY_ERROR,
SHORT_CIRCUIT_ANALYSIS_ERROR,
NODE_BUILD_ERROR, URI_SYNTAX,
CREATE_VOLTAGE_INIT_PARAMETERS_FAILED,
Expand Down
3 changes: 0 additions & 3 deletions src/main/java/org/gridsuite/study/server/StudyException.java
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,6 @@ public enum Type {
SENSITIVITY_ANALYSIS_RUNNING,
SENSITIVITY_ANALYSIS_NOT_FOUND,
SENSITIVITY_ANALYSIS_ERROR,
NON_EVACUATED_ENERGY_RUNNING,
NON_EVACUATED_ENERGY_NOT_FOUND,
NON_EVACUATED_ENERGY_ERROR,
SHORT_CIRCUIT_ANALYSIS_NOT_FOUND,
SHORT_CIRCUIT_ANALYSIS_ERROR,
LOADFLOW_NOT_FOUND,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@
import org.gridsuite.study.server.dto.elasticsearch.EquipmentInfos;
import org.gridsuite.study.server.dto.modification.ModificationType;
import org.gridsuite.study.server.dto.modification.ModificationsSearchResultByNode;
import org.gridsuite.study.server.dto.nonevacuatedenergy.NonEvacuatedEnergyParametersInfos;
import org.gridsuite.study.server.dto.sensianalysis.SensitivityAnalysisCsvFileInfos;
import org.gridsuite.study.server.dto.sensianalysis.SensitivityFactorsIdsByGroup;
import org.gridsuite.study.server.dto.sequence.NodeSequenceType;
Expand Down Expand Up @@ -2211,97 +2210,6 @@ public ResponseEntity<Void> invalidateShortCircuitStatus(@Parameter(description
return ResponseEntity.ok().build();
}

@PostMapping(value = "/studies/{studyUuid}/root-networks/{rootNetworkUuid}/nodes/{nodeUuid}/non-evacuated-energy/run")
@Operation(summary = "run sensitivity analysis non evacuated energy on study")
@ApiResponses(value = {@ApiResponse(responseCode = "200", description = "The sensitivity analysis non evacuated energy has started")})
public ResponseEntity<UUID> runNonEvacuatedEnergy(@Parameter(description = "studyUuid") @PathVariable("studyUuid") UUID studyUuid,
@PathVariable("rootNetworkUuid") UUID rootNetworkUuid,
@Parameter(description = "nodeUuid") @PathVariable("nodeUuid") UUID nodeUuid,
@RequestHeader(HEADER_USER_ID) String userId) {
studyService.assertIsNodeNotReadOnly(nodeUuid);
return ResponseEntity.ok().body(studyService.runNonEvacuatedEnergy(studyUuid, nodeUuid, rootNetworkUuid, userId));
}

@GetMapping(value = "/studies/{studyUuid}/root-networks/{rootNetworkUuid}/nodes/{nodeUuid}/non-evacuated-energy/result")
@Operation(summary = "Get a sensitivity analysis non evacuated energy result on study")
@ApiResponses(value = {@ApiResponse(responseCode = "200", description = "The sensitivity analysis non evacuated energy result"),
@ApiResponse(responseCode = "204", description = "No sensitivity analysis non evacuated energy has been done yet"),
@ApiResponse(responseCode = "404", description = "The sensitivity analysis non evacuated energy has not been found")})
public ResponseEntity<String> getNonEvacuatedEnergyResult(@Parameter(description = "study UUID") @PathVariable("studyUuid") UUID studyUuid,
@PathVariable("rootNetworkUuid") UUID rootNetworkUuid,
@Parameter(description = "nodeUuid") @PathVariable("nodeUuid") UUID nodeUuid) {
String result = rootNetworkNodeInfoService.getNonEvacuatedEnergyResult(nodeUuid, rootNetworkUuid);
return result != null ? ResponseEntity.ok().body(result) :
ResponseEntity.noContent().build();
}

@GetMapping(value = "/studies/{studyUuid}/root-networks/{rootNetworkUuid}/nodes/{nodeUuid}/non-evacuated-energy/status")
@Operation(summary = "Get the sensitivity analysis non evacuated energy status on study")
@ApiResponses(value = {@ApiResponse(responseCode = "200", description = "The sensitivity analysis non evacuated energy status"),
@ApiResponse(responseCode = "204", description = "No sensitivity analysis non evacuated energy has been done yet"),
@ApiResponse(responseCode = "404", description = "The sensitivity analysis status non evacuated energy has not been found")})
public ResponseEntity<String> getNonEvacuatedEnergyStatus(@Parameter(description = "Study UUID") @PathVariable("studyUuid") UUID studyUuid,
@PathVariable("rootNetworkUuid") UUID rootNetworkUuid,
@Parameter(description = "nodeUuid") @PathVariable("nodeUuid") UUID nodeUuid) {
String result = rootNetworkNodeInfoService.getNonEvacuatedEnergyStatus(nodeUuid, rootNetworkUuid);
return result != null ? ResponseEntity.ok().body(result) :
ResponseEntity.noContent().build();
}

@PutMapping(value = "/studies/{studyUuid}/root-networks/{rootNetworkUuid}/nodes/{nodeUuid}/non-evacuated-energy/stop")
@Operation(summary = "stop sensitivity analysis non evacuated energy on study")
@ApiResponses(value = {@ApiResponse(responseCode = "200", description = "The sensitivity analysis non evacuated energy has been stopped")})
public ResponseEntity<Void> stopNonEvacuatedEnergy(@Parameter(description = "Study uuid") @PathVariable("studyUuid") UUID studyUuid,
@PathVariable("rootNetworkUuid") UUID rootNetworkUuid,
@Parameter(description = "nodeUuid") @PathVariable("nodeUuid") UUID nodeUuid,
@RequestHeader(HEADER_USER_ID) String userId) {
rootNetworkNodeInfoService.stopNonEvacuatedEnergy(studyUuid, nodeUuid, rootNetworkUuid, userId);
return ResponseEntity.ok().build();
}

@GetMapping(value = "/studies/{studyUuid}/non-evacuated-energy/parameters")
@Operation(summary = "Get sensitivity analysis non evacuated energy parameters on study")
@ApiResponses(value = {@ApiResponse(responseCode = "200", description = "The sensitivity analysis non evacuated energy parameters")})
public ResponseEntity<NonEvacuatedEnergyParametersInfos> getNonEvacuatedEnergyParametersInfos(
@PathVariable("studyUuid") UUID studyUuid) {
return ResponseEntity.ok().body(studyService.getNonEvacuatedEnergyParametersInfos(studyUuid));
}

@PostMapping(value = "/studies/{studyUuid}/non-evacuated-energy/parameters")
@Operation(summary = "set sensitivity analysis non evacuated energy parameters on study, reset to default ones if empty body")
@ApiResponses(value = {@ApiResponse(responseCode = "200", description = "The sensitivity analysis parameters non evacuated energy are set")})
public ResponseEntity<Void> setNonEvacuatedEnergyParametersInfos(
@PathVariable("studyUuid") UUID studyUuid,
@RequestBody(required = false) NonEvacuatedEnergyParametersInfos nonEvacuatedEnergyParametersInfos,
@RequestHeader(HEADER_USER_ID) String userId) {
studyService.setNonEvacuatedEnergyParametersInfos(studyUuid, nonEvacuatedEnergyParametersInfos, userId);
return ResponseEntity.ok().build();
}

@PostMapping(value = "/studies/{studyUuid}/non-evacuated-energy/provider")
@Operation(summary = "set sensitivity analysis non evacuated energy provider for the specified study, no body means reset to default provider")
@ApiResponses(value = {@ApiResponse(responseCode = "200", description = "The sensitivity analysis non evacuated energy provider is set")})
public ResponseEntity<Void> setNonEvacuatedEnergyProvider(@PathVariable("studyUuid") UUID studyUuid,
@RequestBody(required = false) String provider,
@RequestHeader("userId") String userId) {
studyService.updateNonEvacuatedEnergyProvider(studyUuid, provider, userId);
return ResponseEntity.ok().build();
}

@GetMapping(value = "/studies/{studyUuid}/non-evacuated-energy/provider")
@Operation(summary = "Get sensitivity analysis non evacuated energy provider for a specified study, empty string means default provider")
@ApiResponses(value = {@ApiResponse(responseCode = "200", description = "The sensitivity analysis non evacuated energy provider is returned")})
public ResponseEntity<String> getNonEvacuatedEnergyProvider(@PathVariable("studyUuid") UUID studyUuid) {
return ResponseEntity.ok().body(studyService.getNonEvacuatedEnergyProvider(studyUuid));
}

@GetMapping(value = "/non-evacuated-energy-default-provider")
@Operation(summary = "get sensitivity analysis non evacuated energy default provider value")
@ApiResponses(@ApiResponse(responseCode = "200", description = "The sensitivity analysis non evacuated energy default provider has been found"))
public ResponseEntity<String> getDefaultNonEvacuatedEnergyProvider() {
return ResponseEntity.ok().body(studyService.getDefaultNonEvacuatedEnergyProvider());
}

@GetMapping(value = "/servers/infos")
@Operation(summary = "Get the information of all backend servers (if not filter with view parameter)")
@ApiResponses(value = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,6 @@ public enum ComputationType {
SENSITIVITY_ANALYSIS("Sensitivity analysis", "sensitivityAnalysisResultUuid",
NotificationService.UPDATE_TYPE_SENSITIVITY_ANALYSIS_STATUS, NotificationService.UPDATE_TYPE_SENSITIVITY_ANALYSIS_RESULT,
NotificationService.UPDATE_TYPE_SENSITIVITY_ANALYSIS_FAILED),
NON_EVACUATED_ENERGY_ANALYSIS("Non evacuated energy analysis", "nonEvacuatedEnergyResultUuid",
NotificationService.UPDATE_TYPE_NON_EVACUATED_ENERGY_STATUS, NotificationService.UPDATE_TYPE_NON_EVACUATED_ENERGY_RESULT,
NotificationService.UPDATE_TYPE_NON_EVACUATED_ENERGY_FAILED),
SHORT_CIRCUIT("Short circuit analysis", "shortCircuitAnalysisResultUuid",
NotificationService.UPDATE_TYPE_SHORT_CIRCUIT_STATUS, NotificationService.UPDATE_TYPE_SHORT_CIRCUIT_RESULT,
NotificationService.UPDATE_TYPE_SHORT_CIRCUIT_FAILED),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,6 @@ public class DeleteNodeInfos {

private List<UUID> sensitivityAnalysisResultUuids = new ArrayList<>();

private List<UUID> nonEvacuatedEnergyResultUuids = new ArrayList<>();

private List<UUID> shortCircuitAnalysisResultUuids = new ArrayList<>();

private List<UUID> oneBusShortCircuitAnalysisResultUuids = new ArrayList<>();
Expand Down Expand Up @@ -78,10 +76,6 @@ public void addSensitivityAnalysisResultUuid(UUID sensitivityAnalysisResultUuid)
sensitivityAnalysisResultUuids.add(sensitivityAnalysisResultUuid);
}

public void addNonEvacuatedEnergyResultUuid(UUID nonEvacuatedEnergyResultUuid) {
nonEvacuatedEnergyResultUuids.add(nonEvacuatedEnergyResultUuid);
}

public void addShortCircuitAnalysisResultUuid(UUID shortCircuitAnalysisResultUuid) {
shortCircuitAnalysisResultUuids.add(shortCircuitAnalysisResultUuid);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ public class InvalidateNodeInfos {
private Set<UUID> loadFlowResultUuids = new HashSet<>();
private Set<UUID> securityAnalysisResultUuids = new HashSet<>();
private Set<UUID> sensitivityAnalysisResultUuids = new HashSet<>();
private Set<UUID> nonEvacuatedEnergyResultUuids = new HashSet<>();
private Set<UUID> shortCircuitAnalysisResultUuids = new HashSet<>();
private Set<UUID> oneBusShortCircuitAnalysisResultUuids = new HashSet<>();
private Set<UUID> voltageInitResultUuids = new HashSet<>();
Expand Down Expand Up @@ -70,10 +69,6 @@ public List<UUID> getSensitivityAnalysisResultUuids() {
return sensitivityAnalysisResultUuids.stream().toList();
}

public List<UUID> getNonEvacuatedEnergyResultUuids() {
return nonEvacuatedEnergyResultUuids.stream().toList();
}

public List<UUID> getShortCircuitAnalysisResultUuids() {
return shortCircuitAnalysisResultUuids.stream().toList();
}
Expand Down Expand Up @@ -118,10 +113,6 @@ public void addSensitivityAnalysisResultUuid(UUID sensitivityAnalysisResultUuid)
sensitivityAnalysisResultUuids.add(sensitivityAnalysisResultUuid);
}

public void addNonEvacuatedEnergyResultUuid(UUID nonEvacuatedEnergyResultUuid) {
nonEvacuatedEnergyResultUuids.add(nonEvacuatedEnergyResultUuid);
}

public void addShortCircuitAnalysisResultUuid(UUID shortCircuitAnalysisResultUuid) {
shortCircuitAnalysisResultUuids.add(shortCircuitAnalysisResultUuid);
}
Expand Down Expand Up @@ -164,7 +155,6 @@ public void add(InvalidateNodeInfos invalidateNodeInfos) {
loadFlowResultUuids.addAll(invalidateNodeInfos.getLoadFlowResultUuids());
securityAnalysisResultUuids.addAll(invalidateNodeInfos.getSecurityAnalysisResultUuids());
sensitivityAnalysisResultUuids.addAll(invalidateNodeInfos.getSensitivityAnalysisResultUuids());
nonEvacuatedEnergyResultUuids.addAll(invalidateNodeInfos.getNonEvacuatedEnergyResultUuids());
shortCircuitAnalysisResultUuids.addAll(invalidateNodeInfos.getShortCircuitAnalysisResultUuids());
oneBusShortCircuitAnalysisResultUuids.addAll(invalidateNodeInfos.getOneBusShortCircuitAnalysisResultUuids());
voltageInitResultUuids.addAll(invalidateNodeInfos.getVoltageInitResultUuids());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,6 @@ public class NodeModificationInfos {

private UUID sensitivityAnalysisUuid;

private UUID nonEvacuatedEnergyUuid;

private UUID shortCircuitAnalysisUuid;

private UUID oneBusShortCircuitAnalysisUuid;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,6 @@ public class RootNetworkNodeInfo {

private UUID sensitivityAnalysisResultUuid;

private UUID nonEvacuatedEnergyResultUuid;

private UUID dynamicSimulationResultUuid;

private UUID dynamicSecurityAnalysisResultUuid;
Expand All @@ -67,7 +65,6 @@ public RootNetworkNodeInfoEntity toEntity() {
.voltageInitResultUuid(voltageInitResultUuid)
.securityAnalysisResultUuid(securityAnalysisResultUuid)
.sensitivityAnalysisResultUuid(sensitivityAnalysisResultUuid)
.nonEvacuatedEnergyResultUuid(nonEvacuatedEnergyResultUuid)
.dynamicSimulationResultUuid(dynamicSimulationResultUuid)
.dynamicSecurityAnalysisResultUuid(dynamicSecurityAnalysisResultUuid)
.stateEstimationResultUuid(stateEstimationResultUuid)
Expand Down

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

Loading