Sha256: bfdcaf4dab8079224bc5c3c752bdfc11e63b01bf3aaf9505140f6fa2b747a2c8

Contents?: true

Size: 1.45 KB

Versions: 6

Compression:

Stored size: 1.45 KB

Contents

Feature: Receives Observed's input and send it to Fluentd

  In order to pass data from Observed to Fluentd

  I want to configure Observed to use observed-fluentd plugin

  Scenario: Write configuration files for Observed and Fluentd, then run Fluentd, and then run Observed
    Given a file named "test.rb" with:
    """
    require 'observed'
    require 'observed/http'
    require 'observed/fluentd'

    include Observed

    observe 'myservice', via: 'http', with: {
      method: 'get',
      url: 'http://google.com/',
      timeout_in_milliseconds: 3000,
    }

    report /myservice.*/, via: 'fluentd', with: {
      host: 'localhost',
      port: 24224,
      tag: 'debug.myservice'
    }

    run 'myservice'
    """
    Given a file named "fluent.conf" with:
    """
    <source>
      type forward
    </source>

    <match debug.**>
      type file
      path fluent.out
      time_slice_format foo
      utc
      flush_interval 1s
    </match>
    """
    When I run `pwd`
    When I run `fluentd -d pid_file -c fluent.conf`
#    When I start my daemon with "fluentd -c tmp/aruba/fluent.conf"
    When I run `sleep 3`
    When I run `ruby test.rb`
    #Then a daemon called "fluentd" should be running
    When I run `sleep 3`
    When I run the command "kill $(cat tmp/aruba/pid_file)"
    When I run `cat fluent.out.foo_0.log`
    Then the output should contain:
    """
    elapsed_time
    """
    Then the output should contain:
    """
    debug.myservice
    """

Version data entries

6 entries across 6 versions & 2 rubygems

Version Path
observed-fluentd-0.2.0 features/plugin.feature
observed-0.2.0 plugins/observed-fluentd/features/plugin.feature
observed-0.2.0.rc2 plugins/observed-fluentd/features/plugin.feature
observed-0.2.0.rc1 plugins/observed-fluentd/features/plugin.feature
observed-0.1.1 plugins/observed-fluentd/features/plugin.feature
observed-fluentd-0.1.0 features/plugin.feature