Change rest method access to public 83/105983/1
authorBartosz Gardziejewski <bartosz.gardziejewski@nokia.com>
Wed, 15 Apr 2020 05:20:35 +0000 (07:20 +0200)
committerBartosz Gardziejewski <bartosz.gardziejewski@nokia.com>
Wed, 15 Apr 2020 05:20:57 +0000 (07:20 +0200)
Issue-ID: INT-1517
Signed-off-by: Bartosz Gardziejewski <bartosz.gardziejewski@nokia.com>
Change-Id: I8993d3c45c616890ea1fd08528557e6e25dcb3f8

netconfsimulator/src/main/java/org/onap/netconfsimulator/kafka/StoreController.java
netconfsimulator/src/main/java/org/onap/netconfsimulator/netconfcore/NetconfController.java

index 33bbdf7..2a196d9 100644 (file)
@@ -42,17 +42,17 @@ public class StoreController {
     }
 
     @GetMapping("/ping")
-    String ping() {
+    public String ping() {
         return "pong";
     }
 
     @GetMapping("cm-history")
-    List<MessageDTO> getAllConfigurationChanges() {
+    public List<MessageDTO> getAllConfigurationChanges() {
         return service.getAllMessages();
     }
 
     @GetMapping("/less")
-    List<MessageDTO> less(@RequestParam(value = "offset", required = false, defaultValue = "${spring.kafka.default-offset}") long offset) {
+    public List<MessageDTO> less(@RequestParam(value = "offset", required = false, defaultValue = "${spring.kafka.default-offset}") long offset) {
         return service.getLastMessages(offset);
     }
 
index cdb4a8f..05cee88 100644 (file)
@@ -58,12 +58,12 @@ class NetconfController {
     }
 
     @GetMapping(value = "get", produces = "application/xml")
-    ResponseEntity<String> getNetconfConfiguration() throws IOException, JNCException {
+    public ResponseEntity<String> getNetconfConfiguration() throws IOException, JNCException {
         return ResponseEntity.ok(netconfService.getCurrentConfiguration());
     }
 
     @GetMapping(value = "get/{model}/{container}", produces = "application/xml")
-    ResponseEntity<String> getNetconfConfiguration(@PathVariable String model,
+    public ResponseEntity<String> getNetconfConfiguration(@PathVariable String model,
                                                    @PathVariable String container)
             throws IOException {
         ResponseEntity<String> entity;
@@ -79,7 +79,7 @@ class NetconfController {
 
     @PostMapping(value = "edit-config", produces = "application/xml")
     @ResponseStatus(HttpStatus.ACCEPTED)
-    ResponseEntity<String> editConfig(@RequestPart("editConfigXml") MultipartFile editConfig)
+    public ResponseEntity<String> editConfig(@RequestPart("editConfigXml") MultipartFile editConfig)
             throws IOException, JNCException {
         log.info("Loading updated configuration");
         if (editConfig == null || editConfig.isEmpty()) {
@@ -91,7 +91,7 @@ class NetconfController {
     }
 
     @PostMapping("model/{moduleName}")
-    ResponseEntity<String> loadNewYangModel(@RequestBody MultipartFile yangModel,
+    public ResponseEntity<String> loadNewYangModel(@RequestBody MultipartFile yangModel,
                                             @RequestBody MultipartFile initialConfig, @PathVariable String moduleName)
             throws IOException {
         LoadModelResponse response = netconfModelLoaderService.loadYangModel(yangModel, initialConfig, moduleName);
@@ -101,7 +101,7 @@ class NetconfController {
     }
 
     @DeleteMapping("model/{modelName}")
-    ResponseEntity<String> deleteYangModel(@PathVariable String modelName)
+    public ResponseEntity<String> deleteYangModel(@PathVariable String modelName)
             throws IOException {
         LoadModelResponse response = netconfModelLoaderService.deleteYangModel(modelName);
         return ResponseEntity