Package org.apache.stratos.rest.endpoint.exception

Examples of org.apache.stratos.rest.endpoint.exception.RestAPIException


        } catch (AxisFault axisFault) {
            String errorMsg = "Error while getting CloudControllerServiceClient instance to connect to the "
                + "Cloud Controller. Cause: "+axisFault.getMessage();
            log.error(errorMsg, axisFault);
            throw new RestAPIException(errorMsg, axisFault);
        }
    }
View Full Code Here


                partitions = autoscalerServiceClient.getAvailablePartitions();

            } catch (RemoteException e) {
                String errorMsg = "Error while getting available partitions. Cause : " + e.getMessage();
                log.error(errorMsg, e);
                throw new RestAPIException(errorMsg, e);
            }
        }

        return PojoConverter.populatePartitionPojos(partitions);
    }
View Full Code Here

            } catch (RemoteException e) {
                String errorMsg = "Error while getting available partitions for deployment policy id " +
                    deploymentPolicyId+". Cause: "+e.getMessage();
                log.error(errorMsg, e);
                throw new RestAPIException(errorMsg, e);
            }
        }

        return PojoConverter.populatePartitionPojos(partitions);
    }
View Full Code Here

            } catch (RemoteException e) {
                String errorMsg = "Error while getting available partitions for deployment policy id " + deploymentPolicyId +
                        ", group id " + groupId+". Cause: "+e.getMessage();
                log.error(errorMsg, e);
                throw new RestAPIException(errorMsg, e);
            }
        }

        return PojoConverter.populatePartitionPojos(partitions);
    }
View Full Code Here

                partition = autoscalerServiceClient.getPartition(partitionId);

            } catch (RemoteException e) {
                String errorMsg = "Error while getting partition for id " + partitionId+". Cause: "+e.getMessage();
                log.error(errorMsg, e);
                throw new RestAPIException(errorMsg, e);
            }
        }

        return PojoConverter.populatePartitionPojo(partition);
    }
View Full Code Here

        } catch (AxisFault axisFault) {
            String errorMsg = "Error while getting AutoscalerServiceClient instance to connect to the "
                + "Autoscaler. Cause: "+axisFault.getMessage();
            log.error(errorMsg, axisFault);
            throw new RestAPIException(errorMsg, axisFault);
        }
    }
View Full Code Here

                autoscalePolicies = autoscalerServiceClient.getAutoScalePolicies();

            } catch (RemoteException e) {
                String errorMsg = "Error while getting available autoscaling policies. Cause : " + e.getMessage();
                log.error(errorMsg, e);
                throw new RestAPIException(errorMsg, e);
            }
        }
        return PojoConverter.populateAutoscalePojos(autoscalePolicies);
    }
View Full Code Here

            } catch (RemoteException e) {
                String errorMsg = "Error while getting information for autoscaling policy with id " +
                    autoscalePolicyId+".  Cause: "+e.getMessage();
                log.error(errorMsg, e);
                throw new RestAPIException(errorMsg, e);
            }
        }

        return PojoConverter.populateAutoscalePojo(autoscalePolicy);
    }
View Full Code Here

            try {
                deploymentPolicies = autoscalerServiceClient.getDeploymentPolicies();
            } catch (RemoteException e) {
                String errorMsg = "Error getting available deployment policies. Cause : " + e.getMessage();
                log.error(errorMsg, e);
                throw new RestAPIException(errorMsg, e);
            }
        }
       

View Full Code Here

            } catch (RemoteException e) {
                String errorMsg = "Error while getting available deployment policies for cartridge type " +
                    cartridgeType+". Cause: "+e.getMessage();;
                log.error(errorMsg, e);
                throw new RestAPIException(errorMsg, e);
            }
        }
       
        if(deploymentPolicies.length == 0) {
          String errorMsg = "Cannot find any matching deployment policy for Cartridge [type] "+cartridgeType;
            log.error(errorMsg);
            throw new RestAPIException(errorMsg);
        }

        return PojoConverter.populateDeploymentPolicyPojos(deploymentPolicies);
    }
View Full Code Here

TOP

Related Classes of org.apache.stratos.rest.endpoint.exception.RestAPIException

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.