arkflow 0.1.0

High-performance Rust flow processing engine
Documentation
# Rust流处理引擎测试配置
# 这个配置文件用于测试engine.rs的功能

# 日志配置
logging:
  level: "debug"  # 设置为debug级别以查看更多日志信息
  json_format: false
  include_location: true

# 指标收集配置
metrics:
  enabled: true
  type_name: "prometheus"
  prefix: "rust_stream_engine_test"
  tags:
    env: "test"
    service: "engine_test"
  interval_secs: 5

# 流配置
streams:
  # 测试流配置 - 使用内存输入和标准输出
  - input:
      type: "memory"
      # 内存输入配置,提供一些测试消息
      messages:
          - '{"id": 1, "content": "测试消息1", "timestamp": 1625097600}'
          - '{"id": 2, "content": "测试消息2", "timestamp": 1625097601}'
          - '{"id": 3, "content": "测试消息3", "timestamp": 1625097602}'
          - '{"id": 4, "content": null, "timestamp": 1625097603}'
          - '{"id": 5, "content": "测试消息5", "timestamp": 1625097604}'

        
    # 处理管道配置
    pipeline:
      thread_num: 1
      processors:
        - type: "filter"
          condition_type: "content"
          condition: "null"
          invert: false

 

    # 输出配置 - 使用标准输出便于观察结果
    output:
      type: "stdout"
      append_newline: true
        

  # 第二个测试流 - 使用文件输入和文件输出
  # - input:
  #     type: "file"
  #     # 文件输入配置
  #     file:
  #       path: "./examples/test_input.txt"
  #       max_buffer: 65536
  #       delimiter: "\n"

  #   # 处理管道配置
  #   # pipeline:
  #   #   processors:
  #   #     # 简单的映射处理
  #   #     - mapping:
  #   #         script: |
  #   #           root.line = this
  #   #           root.line_length = len(this)
  #   #           root.processed = true

  #   # 输出配置
  #   output:
  #     file:
  #       path: "./examples/test_output.txt"
  #       append: false

  #   # 缓冲区配置
  #   buffer:
  #     memory:
  #       limit: 1000