@Test void testCreatePortAlias() { PortAliasRequestBody requestBody = new PortAliasRequestBody(); dataEngineResource.createOrUpdatePortAlias(SERVER_NAME, USER, requestBody); verify(dataEngineRestServices, times(1)).createOrUpdatePortAlias(SERVER_NAME, USER, requestBody); }
@PostMapping(path = "/port-aliases") public GUIDResponse createOrUpdatePortAlias(@PathVariable("userId") String userId, @PathVariable("serverName") String serverName, @RequestBody PortAliasRequestBody portAliasRequestBody) { return restAPI.createOrUpdatePortAlias(userId, serverName, portAliasRequestBody); }
DataEngineResource { @PostMapping(path = "/port-aliases") public GUIDResponse createOrUpdatePortAlias(@PathVariable("userId") String userId, @PathVariable("serverName") String serverName, @RequestBody PortAliasRequestBody portAliasRequestBody) { return restAPI.createOrUpdatePortAlias(userId, serverName, portAliasRequestBody); } }
DataEngineResource { @PostMapping(path = "/port-aliases") public GUIDResponse createOrUpdatePortAlias(@PathVariable("userId") String userId, @PathVariable("serverName") String serverName, @RequestBody PortAliasRequestBody portAliasRequestBody) { return restAPI.createOrUpdatePortAlias(userId, serverName, portAliasRequestBody); } DataEngineResource(); }
DataEngineResource { @PostMapping(path = "/port-aliases") public GUIDResponse createOrUpdatePortAlias(@PathVariable("userId") String userId, @PathVariable("serverName") String serverName, @RequestBody PortAliasRequestBody portAliasRequestBody) { return restAPI.createOrUpdatePortAlias(userId, serverName, portAliasRequestBody); } DataEngineResource(); @PostMapping(path = "/registration") GUIDResponse createExternalDataEngine(@PathVariable("serverName") String serverName,
                                                 @PathVariable("userId") String userId,
                                                 @RequestBody DataEngineRegistrationRequestBody requestBody); @GetMapping(path = "/registration/{qualifiedName}") GUIDResponse getExternalDataEngineByQualifiedName(@PathVariable String serverName,
                                                             @PathVariable String userId,
                                                             @PathVariable String qualifiedName); @PostMapping(path = "/schema-types") GUIDResponse createOrUpdateSchemaType(@PathVariable("userId") String userId,
                                                 @PathVariable("serverName") String serverName,
                                                 @RequestBody SchemaTypeRequestBody requestBody); @PostMapping(path = "/port-implementations") GUIDResponse createOrUpdatePortImplementation(@PathVariable("userId") String userId,
                                                         @PathVariable("serverName") String serverName,
                                                         @RequestBody PortImplementationRequestBody portImplementationRequestBody); @PostMapping(path = "/port-aliases") GUIDResponse createOrUpdatePortAlias(@PathVariable("userId") String userId,
                                                @PathVariable("serverName") String serverName,
                                                @RequestBody PortAliasRequestBody portAliasRequestBody); @PostMapping(path = "/processes") GUIDListResponse createOrUpdateProcesses(@PathVariable("userId") String userId,
                                                    @PathVariable("serverName") String serverName,
                                                    @RequestBody ProcessesRequestBody processesRequestBody); @PostMapping(path = "/processes/{processGuid}/ports") GUIDResponse addPortsToProcess(@PathVariable("userId") String userId,
                                          @PathVariable("serverName") String serverName,
                                          @PathVariable("processGuid") String processGuid,
                                          @RequestBody PortListRequestBody portListRequestBody); @PostMapping(path = "/lineage-mappings") VoidResponse addLineageMappings(@PathVariable("userId") String userId,
                                           @PathVariable("serverName") String serverName,
                                           @RequestBody LineageMappingsRequestBody lineageMappingsRequestBody); @GetMapping(path = "/topics/in-topic-connection") ConnectionResponse getInTopicConnection(@PathVariable String                        serverName,
                                                   @PathVariable String                        userId); }
DataEngineResource { @PostMapping(path = "/port-aliases") public GUIDResponse createOrUpdatePortAlias(@PathVariable("userId") String userId, @PathVariable("serverName") String serverName, @RequestBody PortAliasRequestBody portAliasRequestBody) { return restAPI.createOrUpdatePortAlias(userId, serverName, portAliasRequestBody); } DataEngineResource(); @PostMapping(path = "/registration") GUIDResponse createExternalDataEngine(@PathVariable("serverName") String serverName,
                                                 @PathVariable("userId") String userId,
                                                 @RequestBody DataEngineRegistrationRequestBody requestBody); @GetMapping(path = "/registration/{qualifiedName}") GUIDResponse getExternalDataEngineByQualifiedName(@PathVariable String serverName,
                                                             @PathVariable String userId,
                                                             @PathVariable String qualifiedName); @PostMapping(path = "/schema-types") GUIDResponse createOrUpdateSchemaType(@PathVariable("userId") String userId,
                                                 @PathVariable("serverName") String serverName,
                                                 @RequestBody SchemaTypeRequestBody requestBody); @PostMapping(path = "/port-implementations") GUIDResponse createOrUpdatePortImplementation(@PathVariable("userId") String userId,
                                                         @PathVariable("serverName") String serverName,
                                                         @RequestBody PortImplementationRequestBody portImplementationRequestBody); @PostMapping(path = "/port-aliases") GUIDResponse createOrUpdatePortAlias(@PathVariable("userId") String userId,
                                                @PathVariable("serverName") String serverName,
                                                @RequestBody PortAliasRequestBody portAliasRequestBody); @PostMapping(path = "/processes") GUIDListResponse createOrUpdateProcesses(@PathVariable("userId") String userId,
                                                    @PathVariable("serverName") String serverName,
                                                    @RequestBody ProcessesRequestBody processesRequestBody); @PostMapping(path = "/processes/{processGuid}/ports") GUIDResponse addPortsToProcess(@PathVariable("userId") String userId,
                                          @PathVariable("serverName") String serverName,
                                          @PathVariable("processGuid") String processGuid,
                                          @RequestBody PortListRequestBody portListRequestBody); @PostMapping(path = "/lineage-mappings") VoidResponse addLineageMappings(@PathVariable("userId") String userId,
                                           @PathVariable("serverName") String serverName,
                                           @RequestBody LineageMappingsRequestBody lineageMappingsRequestBody); @GetMapping(path = "/topics/in-topic-connection") ConnectionResponse getInTopicConnection(@PathVariable String                        serverName,
                                                   @PathVariable String                        userId);  }