// UGLY HACK
// This is all broken here, the conversions that happens (Repo REST DTO -> CRepo DTO -> Repo creation)
// is simply damn too stupid.
// All this should be removed, and do not use C* config classes anymore in REST API (see NEXUS-2505).
// For now, this is a "backdoor", using manual template when we have a CRepo object.
ManuallyConfiguredRepositoryTemplate template =
repositoryTemplateProvider.createManuallyTemplate(new CRepositoryCoreConfiguration(
repositoryTemplateProvider.getApplicationConfiguration(), config, null));
template.create();
getNexusConfiguration().saveConfiguration();
}
catch (ConfigurationException e) {
handleConfigurationException(e);