use of com.khartec.waltz.model.application.AppRegistrationResponse in project waltz by khartec.
the class ApplicationService method registerApp.
public AppRegistrationResponse registerApp(AppRegistrationRequest request, String username) {
checkNotEmpty(request.name(), "Cannot register app with no name");
AppRegistrationResponse response = applicationDao.registerApp(request);
if (response.registered()) {
EntityReference entityReference = ImmutableEntityReference.builder().id(response.id().get()).kind(EntityKind.APPLICATION).build();
entityAliasDao.updateAliases(entityReference, request.aliases());
entityTagDao.updateTags(entityReference, request.tags(), username);
}
return response;
}
Aggregations