simple_flow一个简单的流式计算框架

simple_flow

simple realtime flow computation

简介

simple_flow 是一个简单的实时流计算框架,由两部分组成,一个是agent,一个是flow_server, agent负责将数据实时传输给flow_server,flow_server负责对实时流的处理

特点

  • linux only
  • 继承simple系列的传统,简洁实用
  • 安全,可靠 -- 采用拉模式,对数据源系统依赖,影响小

依赖

构建 && 测试

  make && make test # 此步骤会生成一个agent和一个测试用的flow_server
  ./bin/flow_server_test # start flow_server to receive flow
  ./bin/fileagent localhost 3491 /tmp/test.log # usage: ./bin/fileagent flow_server_ip flow_server_port file_path

代码示例

#include <fstream>
#include "simple_log.h"
#include "flow_handler.h"
#include "flow_server.h"

class LogFlowHandler : public FlowHandler {

public:
    int do_handle(char *flow_bytes, int size) {
        std::string receive_flow = std::string(flow_bytes, size);
        LOG_DEBUG("start handle the size:%d, flows %s", size, receive_flow.c_str());
        return 0;
    }
};

int main() {
    FlowServer flow_server;
    flow_server.start(3491, new LogFlowHandler());
    return 1;
}

 

  项目地址: https://github.com/hongliuliao/simple_flow

 

 

  • 0
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
最新版本,请从Simpleflow官方站点下载 http://www.simpleflow.com.cn 此版本已不是最新版本,请注意查看最新版本 &times;&times;&times;&times;&times;&times;&times;&times;&times;&times;&times;&times;&times;&times;&times;&times;&times;&times;&times;&times;&times;&times;&times;&times; 如果SimpleFlow并不能满足你对工作流的需求,请留言,你所需要的工作流的功能,谢谢 如果你想了解如何使用Simpleflow进行工作流开发,请随时与我交流 希望您在免费下载的同时,留下你的MSN,或加Simpleflow@163.com &times;&times;&times;&times;&times;&times;&times;&times;&times;&times;&times;&times;&times;&times;&times;&times;&times;&times;&times;&times;&times;&times;&times;&times; Simpleflow 工作流开发套件 CS版 如果你有一定的BS开发功底,可以很简单的改造成BS,因为所有流程驱动都是用后台类驱动。 Simpleflow的最终目的是开发成CS、BS并行的工作流套件。目前正在努力中。。。 同一个流程实例,按用户喜好,既可以在CS审批,也可以在BS审批。 如果这个套件对您有帮助,请多关注并支持Simpleflow,同时,希望能够加Simpleflow为MSN好友 如果您有更好的点子或功能需求,请随时与Simpleflowf交流 QQ:935139121 MSN Simpleflow@163.com 关于Simpleflow的信息,请关注 Simpleflow的Blog http://blog.csdn.net/simpleflow/ Simpleflow的发布空间 http://download.csdn.net/user/simpleflow 此数据包中的内容 1.Application.nsf 工作流应用库(工作流运行库,三个流程定义中,外出申请可以实际运行,其它为示意流程,不能实际运行) 2.Process.nsf 流程定义库(附加三个经过测试的简单流程定义) 3.Organization.nsf 组织库(附加一个模拟企业的人员及组织信息,您可以在个人信息档中更改NotesID,进行测试) 4.FlowArchive/Archive_Out.nsf 外出流程的归档库 --------------------------------------------------------------------------- 配置 数据库签名 请用管理员[SysAdmin]角色登陆,并配置每个库的 系统设置档,并更新相关路径信息。 (原来没有参数的栏位,目前不需配置,因为目前还没用到) regist users文档用于在你的测试服务器上注册符合Organization.nsf的Notes 用户 用户需要注册在根Cert /World下 ------------------------------------------------------------------------------ ================================================================================== 版权声明 Simpleflow一个免费套件,且没有收费的计划 如果您想将Simpleflow应用于生产环境,请邮件告知Simpleflow@163.com,开发团队只想了解Simpleflow的应用情况 并请及时反馈测试与使用过程中发生的问题。 Simpleflow开发团队保留所有权利 =====================================================================================
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值