fluent-plugin-gcs 0.1.0 → 0.1.1

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ac0dec9f5eadfcf591d969f57d8c0299e8f9060e
4
- data.tar.gz: 6ca58b3c7a54526ac95d2711407491a7f8ccfed5
3
+ metadata.gz: 712de7c582c00ef25cd4c781daee6cfc537d9437
4
+ data.tar.gz: 40d2803153868f6792d1f157e669ea9ab8b757b4
5
5
  SHA512:
6
- metadata.gz: f8e0681f28757ee42a811f623afdd987bcd59006574356cab3b64001f57c45ae6e64fdfb2cf6cd94eab258f554a886c79d50c52e18f8d38cc70d7f73a0980a57
7
- data.tar.gz: cf27dad559db3e0306137cb395faf4268c96223d4da6dd2b06970ff2e060ecdc284a7cfaf7b4a5e158c855db6d59dbd903c337ad7ee9ec87ed7dcacb3cf85c61
6
+ metadata.gz: 8685cb9091a416bf6573c52fb675253eff9ed54a588a34af45baf9ca2f3556945f6b7ec1117f90fa2e54947c421626e2f44e3c1b08d9d873f72e329cf60a6f83
7
+ data.tar.gz: 687066ae6f1c8201bfe8e9b5a61c7ed9d1b765bc10b95ec5aa2305a272eaf6bb9d5fc4f606804737f51d753ba6567e554ed68fd20479c1ef69f411000dff3744
data/README.md CHANGED
@@ -1,5 +1,5 @@
1
1
  # fluent-plugin-gcs
2
- [![Build Status](https://travis-ci.org/daichirata/fluent-plugin-gcs.svg?branch=master)](https://travis-ci.org/daichirata/fluent-plugin-gcs) [![Code Climate](https://codeclimate.com/github/daichirata/fluent-plugin-gcs/badges/gpa.svg)](https://codeclimate.com/github/daichirata/fluent-plugin-gcs)
2
+ [![Gem Version](https://badge.fury.io/rb/fluent-plugin-gcs.svg)](https://badge.fury.io/rb/fluent-plugin-gcs) [![Build Status](https://travis-ci.org/daichirata/fluent-plugin-gcs.svg?branch=master)](https://travis-ci.org/daichirata/fluent-plugin-gcs) [![Code Climate](https://codeclimate.com/github/daichirata/fluent-plugin-gcs/badges/gpa.svg)](https://codeclimate.com/github/daichirata/fluent-plugin-gcs)
3
3
 
4
4
  Google Cloud Storage output plugin for [Fluentd](https://github.com/fluent/fluentd).
5
5
 
@@ -17,8 +17,8 @@ gem install fluent-plugin-gcs
17
17
 
18
18
  project YOUR_PROJECT
19
19
  keyfile YOUR_KEYFILE_PATH
20
- gcs_bucket YOUR_GCS_BUCKET_NAME
21
- gcs_object_key_format %{path}%{time_slice}_%{index}.%{file_extension}
20
+ bucket YOUR_GCS_BUCKET_NAME
21
+ object_key_format %{path}%{time_slice}_%{index}.%{file_extension}
22
22
  path logs/
23
23
  buffer_path /var/log/fluent/gcs
24
24
 
@@ -85,6 +85,7 @@ The format of GCS object keys. You can use several built-in variables:
85
85
  * %{file_extension}
86
86
  * %{uuid_flush}
87
87
  * %{hex_random}
88
+ * %{hostname}
88
89
 
89
90
  to decide keys dynamically.
90
91
 
@@ -96,8 +97,8 @@ to decide keys dynamically.
96
97
  * json - json
97
98
  * text - txt
98
99
  * `%{uuid_flush}` a uuid that is replaced everytime the buffer will be flushed
99
- * `%{hex_random}` a random hex string that is replaced for each buffer chunk, not assured to be unique.
100
- You can configure the length of string with a `hex_random_length` parameter (Default: 4).
100
+ * `%{hex_random}` a random hex string that is replaced for each buffer chunk, not assured to be unique. You can configure the length of string with a `hex_random_length` parameter (Default: 4).
101
+ * `%{hostname}` is set to the standard host name of the system of the running server.
101
102
 
102
103
  The default format is `%{path}%{time_slice}_%{index}.%{file_extension}`.
103
104
 
@@ -10,7 +10,7 @@ Gem::Specification.new do |spec|
10
10
  spec.email = ["hirata.daichi@gmail.com"]
11
11
  spec.summary = "Google Cloud Storage output plugin for Fluentd"
12
12
  spec.description = "Google Cloud Storage output plugin for Fluentd"
13
- spec.homepage = "https://github.com/daishirata/fluent-plugin-gcs"
13
+ spec.homepage = "https://github.com/daichirata/fluent-plugin-gcs"
14
14
  spec.license = "Apache-2.0"
15
15
 
16
16
  spec.files = `git ls-files -z`.split("\x0").reject do |f|
@@ -1,5 +1,5 @@
1
1
  module Fluent
2
2
  module GCSPlugin
3
- VERSION = "0.1.0"
3
+ VERSION = "0.1.1"
4
4
  end
5
5
  end
@@ -1,5 +1,6 @@
1
+ require "digest/md5"
1
2
  require "securerandom"
2
- require "digest"
3
+ require "socket"
3
4
 
4
5
  require "fluent/plugin/gcs/object_creator"
5
6
  require "fluent/plugin/gcs/version"
@@ -140,6 +141,7 @@ module Fluent
140
141
  tags = {
141
142
  "%{file_extension}" => @object_creator.file_extension,
142
143
  "%{hex_random}" => hex_random(chunk),
144
+ "%{hostname}" => Socket.gethostname,
143
145
  "%{index}" => i,
144
146
  "%{path}" => format_path(chunk),
145
147
  "%{time_slice}" => chunk.key,
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fluent-plugin-gcs
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Daichi HIRATA
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-11-27 00:00:00.000000000 Z
11
+ date: 2016-11-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: fluentd
@@ -141,7 +141,7 @@ files:
141
141
  - lib/fluent/plugin/gcs/object_creator.rb
142
142
  - lib/fluent/plugin/gcs/version.rb
143
143
  - lib/fluent/plugin/out_gcs.rb
144
- homepage: https://github.com/daishirata/fluent-plugin-gcs
144
+ homepage: https://github.com/daichirata/fluent-plugin-gcs
145
145
  licenses:
146
146
  - Apache-2.0
147
147
  metadata: {}