当前位置: 首页>>代码示例>>Java>>正文


Java StreamDefinitionException类代码示例

本文整理汇总了Java中org.wso2.carbon.databridge.commons.exception.StreamDefinitionException的典型用法代码示例。如果您正苦于以下问题:Java StreamDefinitionException类的具体用法?Java StreamDefinitionException怎么用?Java StreamDefinitionException使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


StreamDefinitionException类属于org.wso2.carbon.databridge.commons.exception包,在下文中一共展示了StreamDefinitionException类的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: publish

import org.wso2.carbon.databridge.commons.exception.StreamDefinitionException; //导入依赖的package包/类
public static void publish(String protocol, String host, String port, String username, String password,
        String streamId,String dataFileName, String testCaseFolderName, StreamDefinition streamDefinition,
        int events, int delay) throws MalformedStreamDefinitionException,
        StreamDefinitionException, DifferentStreamDefinitionAlreadyDefinedException,
        MalformedURLException, NoStreamDefinitionExistException, AuthenticationException,
        TransportException, SocketException, DataEndpointAgentConfigurationException, DataEndpointException,
        DataEndpointAuthenticationException, DataEndpointConfigurationException {

    String relativeFilePath = getTestDataFileLocation(testCaseFolderName, dataFileName);

    KeyStoreUtil.setTrustStoreParams();
    //create data publisher
    DataPublisher dataPublisher = new DataPublisher(protocol, "tcp://" + host + ":" + port, null, username,
            password);

    //Publish event for a valid stream
    publishEvents(dataPublisher, streamDefinition, relativeFilePath, events, delay);
    dataPublisher.shutdown();

}
 
开发者ID:wso2,项目名称:product-cep,代码行数:21,代码来源:Wso2EventClient.java

示例2: deleteColumnFamily

import org.wso2.carbon.databridge.commons.exception.StreamDefinitionException; //导入依赖的package包/类
public void deleteColumnFamily(String columnFamily) throws SummarizerException, AgentException, MalformedURLException, AuthenticationException, TransportException, StreamDefinitionException, NoStreamDefinitionExistException {
    log.info("Deleting CF " + columnFamily);
    newConnection().dropColumnFamily(keyspaceName, columnFamily, true);
    DateFormat dateFormat = new SimpleDateFormat("yyyy_MM_dd");
    Date date = new Date();
    String prevDate = dateFormat.format(date.getTime() - 1000 * 60 * 60 * 24);
    if (log.isDebugEnabled()) {
        log.debug("The column family dated " + prevDate + " was deleted successfully.");
    }
}
 
开发者ID:wso2,项目名称:carbon-commons,代码行数:11,代码来源:ColumnFamilyHandler.java


注:本文中的org.wso2.carbon.databridge.commons.exception.StreamDefinitionException类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。