diff options
Diffstat (limited to 'src/main/java/org/onap/a1pesimulator/controller/RanEventConfigureController.java')
-rw-r--r-- | src/main/java/org/onap/a1pesimulator/controller/RanEventConfigureController.java | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/main/java/org/onap/a1pesimulator/controller/RanEventConfigureController.java b/src/main/java/org/onap/a1pesimulator/controller/RanEventConfigureController.java index 5efe07a..5b5037c 100644 --- a/src/main/java/org/onap/a1pesimulator/controller/RanEventConfigureController.java +++ b/src/main/java/org/onap/a1pesimulator/controller/RanEventConfigureController.java @@ -23,7 +23,7 @@ import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RestController; @RestController -@RequestMapping({"${restapi.version}/ran/eventConfig"}) +@RequestMapping({"${restapi.version}/ran/globalPMConfig"}) public class RanEventConfigureController { private final RanVesBrokerService ranVesBrokerService; @@ -33,16 +33,17 @@ public class RanEventConfigureController { } @GetMapping - public ResponseEntity<GlobalVesConfiguration> getEventConfig() { + public ResponseEntity<GlobalVesConfiguration> getGlobalPMConfig() { GlobalVesConfiguration config = new GlobalVesConfiguration(ranVesBrokerService.getGlobalVesInterval(), - ranVesBrokerService.getGlobalPmVesStructure()); + ranVesBrokerService.getGlobalPmVesStructure(), ranVesBrokerService.getGlobalReportingMethod()); return ResponseEntity.ok(config); } @PostMapping - public ResponseEntity<Void> setEventConfig(final @RequestBody GlobalVesConfiguration config) { + public ResponseEntity<Void> setGlobalPMConfig(final @RequestBody GlobalVesConfiguration config) { ranVesBrokerService.setGlobalPmVesStructure(config.getEvent()); ranVesBrokerService.setGlobalVesInterval(config.getInterval()); + ranVesBrokerService.setGlobalReportingMethod(config.getReportingMethod()); return ResponseEntity.ok().build(); } } |