import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
+import org.springframework.web.bind.annotation.RequestHeader;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;
* @return ResponseEntity response entity having module response as json string.
*/
@PostMapping("/v1/ch/{cmHandleId}/modules")
- public ResponseEntity<String> getModuleReferences(@PathVariable("cmHandleId") final String cmHandleId,
+ public ResponseEntity<String> getModuleReferences(@PathVariable final String cmHandleId,
@RequestBody final Object moduleReferencesRequest) {
delay(moduleReferencesDelayMs);
final String moduleResponseContent = getModuleResourceResponse(cmHandleId,
*/
@PostMapping("/v1/ch/{cmHandleId}/moduleResources")
public ResponseEntity<String> retrieveModuleResources(
- @PathVariable("cmHandleId") final String cmHandleId,
+ @PathVariable final String cmHandleId,
@RequestBody final Object moduleResourcesReadRequest) {
delay(moduleResourcesDelayMs);
final String moduleResourcesResponseContent = getModuleResourceResponse(cmHandleId,
}
/**
- * Get resource data from passthrough operational or running for a cm handle.
+ * Create resource data from passthrough operational or running for a cm handle.
*
* @param cmHandleId The identifier for a network function, network element, subnetwork,
* or any other cm object by managed Network CM Proxy
@PathVariable("datastoreName") final String datastoreName,
@RequestParam(value = "resourceIdentifier") final String resourceIdentifier,
@RequestParam(value = "options", required = false) final String options,
- @RequestParam(value = "topic", required = false) final String topic) {
+ @RequestParam(value = "topic", required = false) final String topic,
+ @RequestHeader(value = "Authorization", required = false) final String authorization) {
+ log.info("DMI AUTH HEADER: {}", authorization);
delay(dataForCmHandleDelayMs);
final String sampleJson = ResourceFileReaderUtil.getResourceFileContent(applicationContext.getResource(
ResourceLoader.CLASSPATH_URL_PREFIX + "data/operational/ietf-network-topology-sample-rfc8345.json"));