fluent-plugin-grassland 0.0.1.1 → 0.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/LICENSE.txt +1 -1
- data/README.md +47 -0
- data/fluent-plugin-grassland.gemspec +2 -2
- data/test/plugin/test_out_grassland.rb +2 -2
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2e10bd0b1a85a01a7616dc21c1a9e9261b19f47e
|
4
|
+
data.tar.gz: bbd45daf68b7942c93a28df29d61d850b8ecda43
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b82c463cc33c0441c3e4720120de0620b7a929203b3b3dfd3e3c84936c9efcadcafdcaa4c5ba1280a2364b41ccda6e1b2f19eb1f3cf2ef5a5d620dd0750b9f36
|
7
|
+
data.tar.gz: ad963e16c0e017bdaa50535deee4ab3fbc62bfed396180e1916dfc5da07d2061fd9a13bf070e94c20cc8a3cd799f670fdcc77f9e96268a67c6fe15cca8aac6cb
|
data/LICENSE.txt
CHANGED
data/README.md
CHANGED
@@ -41,9 +41,56 @@ fluent-gemでインストールします。
|
|
41
41
|
|
42
42
|
__Fluentdの設定ファイルに以下を追記します。__
|
43
43
|
```
|
44
|
+
<source>
|
45
|
+
type forward
|
46
|
+
port 24224
|
47
|
+
bind 127.0.0.1
|
48
|
+
</source>
|
44
49
|
<match grassland.**>
|
45
50
|
type grassland
|
46
51
|
key xxxxxxxxxxxxxxxx
|
47
52
|
flush_interval 3
|
48
53
|
</match>
|
49
54
|
```
|
55
|
+
|
56
|
+
|
57
|
+
### PHP usage
|
58
|
+
|
59
|
+
__1. [fluent-logger-phpをインストール](https://github.com/fluent/fluent-logger-php)して下さい。__
|
60
|
+
```
|
61
|
+
cat > composer.json << EOF
|
62
|
+
{
|
63
|
+
"require": {
|
64
|
+
"fluent/logger": "v0.3.7"
|
65
|
+
}
|
66
|
+
}
|
67
|
+
EOF
|
68
|
+
curl -sS https://getcomposer.org/installer | php
|
69
|
+
php composer.phar install
|
70
|
+
```
|
71
|
+
|
72
|
+
__2. 実際にPHPに記載して下さい。__
|
73
|
+
```
|
74
|
+
<?php
|
75
|
+
require 'vendor/autoload.php';
|
76
|
+
use Fluent\Autoloader,
|
77
|
+
Fluent\Logger\FluentLogger;
|
78
|
+
|
79
|
+
Autoloader::register();
|
80
|
+
$logger = FluentLogger::open("localhost", "24224");
|
81
|
+
|
82
|
+
/*** ここまでがfluent-logger-php用の前準備 ***/
|
83
|
+
|
84
|
+
$param = array(
|
85
|
+
'cid' => 'お客様ID',
|
86
|
+
'dt' => 'データID',
|
87
|
+
'uid' => 'お客様のサービスのユーザID',
|
88
|
+
'pt' => '(optional)データの発生時刻(ISO 8601準拠の文字列か、Unix Timestamp)',
|
89
|
+
'd' => array(
|
90
|
+
'd1' => '集計を行いたいデータ',
|
91
|
+
'd2' => '(optional)集計を行いたいデータ',
|
92
|
+
'd3' => '(以降、同様に最大10個まで追加可能)'
|
93
|
+
)
|
94
|
+
);
|
95
|
+
$logger->post("grassland.data", $param);
|
96
|
+
```
|
@@ -4,12 +4,12 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
|
4
4
|
|
5
5
|
Gem::Specification.new do |spec|
|
6
6
|
spec.name = 'fluent-plugin-grassland'
|
7
|
-
spec.version = '0.0.
|
7
|
+
spec.version = '0.0.2'
|
8
8
|
spec.authors = ['Ripplation Inc.']
|
9
9
|
# spec.email = ['xxxxxx@ripplation.co.jp']
|
10
10
|
spec.description = 'Output filter plugin for Grassland'
|
11
11
|
spec.summary = 'Output filter plugin for Grassland'
|
12
|
-
spec.homepage = '
|
12
|
+
spec.homepage = 'http://www.ripplation.co.jp'
|
13
13
|
spec.license = 'MIT'
|
14
14
|
|
15
15
|
spec.files = `git ls-files`.split($/)
|
@@ -1,6 +1,6 @@
|
|
1
1
|
require 'helper'
|
2
2
|
|
3
|
-
class
|
3
|
+
class GrasslandOutputTest < Test::Unit::TestCase
|
4
4
|
def setup
|
5
5
|
Fluent::Test.setup
|
6
6
|
end
|
@@ -14,7 +14,7 @@ class KinesisAltOutputTest < Test::Unit::TestCase
|
|
14
14
|
# ]
|
15
15
|
|
16
16
|
def create_driver(conf = CONFIG, tag='test')
|
17
|
-
Fluent::Test::BufferedOutputTestDriver.new(Fluent::
|
17
|
+
Fluent::Test::BufferedOutputTestDriver.new(Fluent::GrasslandOutput, tag).configure(conf)
|
18
18
|
end
|
19
19
|
|
20
20
|
def test_configure
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: fluent-plugin-grassland
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ripplation Inc.
|
@@ -67,7 +67,7 @@ files:
|
|
67
67
|
- lib/fluent/plugin/out_grassland.rb
|
68
68
|
- test/helper.rb
|
69
69
|
- test/plugin/test_out_grassland.rb
|
70
|
-
homepage:
|
70
|
+
homepage: http://www.ripplation.co.jp
|
71
71
|
licenses:
|
72
72
|
- MIT
|
73
73
|
metadata: {}
|