Examples of CSGException


Examples of org.wso2.carbon.cloud.csg.common.CSGException

            try {
                prop.load(in);
            } catch (IOException e) {
                String msg = "Cloud not load properties from file '" + filePath + "'";
                log.error(msg, e);
                throw new CSGException(msg, e);
            }
        }
        return prop;
    }
View Full Code Here

Examples of org.wso2.carbon.cloud.csg.common.CSGException

    public CSGProxyService getCSGServiceProxy()
            throws CSGException {
        if (CSGConstant.JMS_MODE_OF_OPERATION.equals(operationMode)) {
            return new JMSCSGProxyService();
        } else {
            throw new CSGException("Operation mode " + operationMode + " doesn't support. Only a JMS based" +
                    " model is supported");
        }
    }
View Full Code Here

Examples of org.wso2.carbon.cloud.csg.common.CSGException

                replace(CSGConstant.CSG_AMQP_PASSWORD, passWord);
    }

    private void handleException(String msg) throws CSGException {
        log.error(msg);
        throw new CSGException(msg);
    }
View Full Code Here

Examples of org.wso2.carbon.cloud.csg.common.CSGException

        throw new CSGException(msg);
    }

    private void handleException(String msg, Throwable t) throws CSGException {
        log.error(msg, t);
        throw new CSGException(msg, t);
    }
View Full Code Here

Examples of org.wso2.carbon.cloud.csg.common.CSGException

        }
    }

    private void handleException(String msg, Throwable t) throws CSGException {
        log.error(msg, t);
        throw new CSGException(msg, t);
    }
View Full Code Here

Examples of org.wso2.carbon.cloud.csg.common.CSGException

        throw new CSGException(msg, t);
    }

    private void handleException(String msg) throws CSGException {
        log.error(msg);
        throw new CSGException(msg);
    }
View Full Code Here

Examples of org.wso2.carbon.cloud.csg.common.CSGException

                    resource.getProperty(CSGConstant.PASS_WORD)));
            bean.setPassWord(plainPassWord);

            return bean;
        } catch (CryptoException e) {
            throw new CSGException("Cloud not get the CSG server information from the resource: " +
                    resource,e);
        }
    }
View Full Code Here

Examples of org.wso2.carbon.cloud.csg.common.CSGException

                    csgServer.getPassWord().getBytes()));

            registry.put(CSGConstant.REGISTRY_SERVER_RESOURCE_PATH + "/" + csgServer.getName(),
                    resource);
        } catch (Exception e) {
            throw new CSGException("Error occurred while saving the content into registry", e);
        }
    }
View Full Code Here

Examples of org.wso2.carbon.cloud.csg.common.CSGException

        return f.exists();
    }

    public static OMNode getOMElementFromURI(String wsdlURI) throws CSGException {
        if (wsdlURI == null || "null".equals(wsdlURI)) {
            throw new CSGException("Can't create URI from a null value");
        }
        URL url;
        try {
            url = new URL(wsdlURI);
        } catch (MalformedURLException e) {
            throw new CSGException("Invalid URI reference '" + wsdlURI + "'");
        }
        URLConnection connection;
        connection = getURLConnection(url);
        if (connection == null) {
            throw new CSGException("Cannot create a URLConnection for given URL : " + url);
        }
        connection.setReadTimeout(getReadTimeout());
        connection.setConnectTimeout(getConnectTimeout());
        connection.setRequestProperty("Connection", "close"); // if http is being used
        InputStream inStream = null;
View Full Code Here

Examples of org.wso2.carbon.cloud.csg.common.CSGException

            return omFactory.createOMText(
                    new DataHandler(new SynapseBinaryDataSource(newInputStream,
                            newConnection.getContentType())), true);

        } catch (IOException e) {
            throw  new CSGException("Error when getting a stream from resource's content", e);
        }
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.