/** * {@inheritDoc} */ @Nonnull @Override public List<CatalogMappingDto> getCatalogNames() { if (connectorManager.getCatalogs().isEmpty()) { throw new MetacatNotFoundException("Unable to locate any catalogs"); } return connectorManager.getCatalogs().stream() .map(catalog -> new CatalogMappingDto(catalog.getCatalogName(), catalog.getType())) .distinct() .collect(Collectors.toList()); }
throw new AlreadyExistsException(e.getMessage()); } catch (MetacatNotFoundException e) { log.error(e.getMessage(), e); throw new NoSuchObjectException(e.getMessage()); } catch (MetacatPreconditionFailedException e) { log.error(e.getMessage(), e);
throw new AlreadyExistsException(e.getMessage()); } catch (MetacatNotFoundException e) { log.error(e.getMessage(), e); throw new NoSuchObjectException(e.getMessage()); } catch (MetacatPreconditionFailedException e) { log.error(e.getMessage(), e);
throw new MetacatNotFoundException("URI not found more than once");
.disableOnReadMetadataIntercetor(false) .build()); return table.orElseThrow(() -> new MetacatNotFoundException("Unable to find view: " + name));
collectRequestExceptionMetrics(tags, e.getClass().getSimpleName()); log.error(e.getMessage(), e); throw new MetacatNotFoundException( String.format("Unable to locate for %s. Details: %s", name, e.getMessage())); } catch (InvalidMetaException | IllegalArgumentException e) {
case MVIEW: if (!this.mViewService.exists(name)) { throw new MetacatNotFoundException(name.toString()); throw new MetacatNotFoundException("Unsupported qualifiedName type {}" + name);
return new MetacatUnAuthorizedException(message); case 404: //NOT_FOUND return new MetacatNotFoundException(message); case 409: //CONFLICT return new MetacatAlreadyExistsException(message);
case MVIEW: if (!this.mViewService.exists(name)) { throw new MetacatNotFoundException(name.toString()); throw new MetacatNotFoundException("Unsupported qualifiedName type {}" + name);