美文网首页程序员Go语言社区
基于Beanstalkd的goalng延时任务队列

基于Beanstalkd的goalng延时任务队列

作者: 打瞌睡滴花花 | 来源:发表于2020-11-15 20:45 被阅读0次

    beanstalkd-go

    描述

    • 简单快速的通用工作队列
    • 作为学习目的为初衷,用golang完全实现了 Beanstalk 功能
    • 协议说明

    里程碑

    • 2020-11-14 : 所有指令全部实现完成,但仅限内存。
    • 2020-11-15 : binlog持久化支持

    快速开始

    使用go get安装

    GO111MODULE=on GOPROXY=https://goproxy.cn/,direct go get -u -v github.com/sjatsh/beanstalkd-go
    

    手动编译

    make
    ./beanstalkd-go
    

    查看支持命令

    ./beanstalkd-go -h
    
    Usage of ./beanstalkd-go:
      -F    never fsync
      -L string
            set the log level, switch one in (panic, fatal, error, warn, waring, info, debug, trace) (default "warn")
      -V    increase verbosity
      -b string
            write-ahead log directory
      -f int
            fsync at most once every MS milliseconds (default is 50ms);use -f0 for "always fsync" (default 50)
      -l string
            listen on address (default is 0.0.0.0) (default "0.0.0.0")
      -p int
            listen on port (default is 11400) (default 11400)
      -s int
            set the size of each write-ahead log file (default is 10485760);will be rounded up to a multiple of 4096 bytes (default 10485760)
      -u string
            become user and group
      -v    show version information
      -z int
            set the maximum job size in bytes (default is 65535);max allowed is 1073741824 bytes (default 65535)
    

    第三方

    相关文章

      网友评论

        本文标题:基于Beanstalkd的goalng延时任务队列

        本文链接:https://www.haomeiwen.com/subject/egkobktx.html