Package org.apache.ambari.server.controller.spi

Examples of org.apache.ambari.server.controller.spi.SystemException


 
  @Override
  public RequestStatus createResources(Request request) throws SystemException,
      UnsupportedPropertyException, ResourceAlreadyExistsException,
      NoSuchParentResourceException {
    throw new SystemException("Cannot create repositories.", null);
  }
View Full Code Here


 
  @Override
  public RequestStatus deleteResources(Predicate predicate)
      throws SystemException, UnsupportedPropertyException,
      NoSuchResourceException, NoSuchParentResourceException {
    throw new SystemException("Cannot delete repositories.", null);
  }
View Full Code Here

      throws SystemException, UnsupportedPropertyException, NoSuchResourceException, NoSuchParentResourceException {

    RequestStatusResponse response = null;
    Set<Map<String, Object>> propertyMaps = getPropertyMaps(request.getProperties().iterator().next(), predicate);
    if (propertyMaps.size() > 1) {
      throw new SystemException("Single update request cannot modify multiple clusters.", null);
    }
    for (Map<String, Object> propertyMap : propertyMaps) {
      final ClusterRequest clusterRequest = getRequest(propertyMap);
      response = modifyResources(new Command<RequestStatusResponse>() {
        @Override
View Full Code Here

      String hostStatus;
      try {
        hostStatus = calculateHostStatus(response);
      } catch (AmbariException e) {
        throw new SystemException("", e);
      }

      // TODO : properly handle more than one cluster
      if (response.getClusterName() != null
          && !response.getClusterName().isEmpty()) {
View Full Code Here

 
  @Override
  public RequestStatus createResources(Request request) throws SystemException,
      UnsupportedPropertyException, ResourceAlreadyExistsException,
      NoSuchParentResourceException {
    throw new SystemException("Cannot create repositories.", null);
  }
View Full Code Here

 
  @Override
  public RequestStatus deleteResources(Predicate predicate)
      throws SystemException, UnsupportedPropertyException,
      NoSuchResourceException, NoSuchParentResourceException {
    throw new SystemException("Cannot delete repositories.", null);
  }
View Full Code Here

      if (hostname.equalsIgnoreCase("localhost")) {
        return InetAddress.getLocalHost().getCanonicalHostName();
      }
      return InetAddress.getByName(hostname).getCanonicalHostName();
    } catch (Exception e) {
      throw new SystemException("Error getting hostname.", e);
    }
  }
View Full Code Here

      if (hostname.equalsIgnoreCase("localhost")) {
        return InetAddress.getLocalHost().getHostAddress();
      }
      return InetAddress.getByName(hostname).getHostAddress();
    } catch (Exception e) {
      throw new SystemException("Error getting ip address.", e);
    }
  }
View Full Code Here

      notifyUpdate(Resource.Type.Service, startRequest, startPredicate);
      requestStages.persist();
      return requestStages.getRequestStatusResponse();

    } catch (NoSuchResourceException e) {
      throw new SystemException("Attempted to modify a non-existing service",  e);
    }
  }
View Full Code Here

      try {
        //todo: properly handle non system exceptions
        setConfigurationsOnCluster(clusterName, type, entry.getValue());
      } catch (AmbariException e) {
        throw new SystemException("Unable to set configurations on cluster.", e);
      }
    }
  }
View Full Code Here

TOP

Related Classes of org.apache.ambari.server.controller.spi.SystemException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.