fluent-plugin-cassandra-driver 0.0.10 → 0.0.11
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/VERSION +1 -1
- data/fluent-plugin-cassandra-driver.gemspec +2 -2
- data/lib/fluent/plugin/out_cassandra_driver.rb +3 -3
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 9f1ea6b627b92195b154a90ea5d60a12c2023122
|
4
|
+
data.tar.gz: 0d5e65927a56158df03c2f1c40c9ec76bef6b7b3
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: fa8af0eea953fef342c49d152d1c8073c4593621ca28a69e4dfb4e7738a67056e0f89466addb41c6db314099a39338ba13b8c84b82638b08505ba463a4ab603a
|
7
|
+
data.tar.gz: f34a085d57d8775211bdc4a09b9e26df450c8f06e5875fa84b37cbebcbe487e80ad73ec82101ec602a5d1b52f8c707a6d5a2ac7b04f68c92c1060bc5ee7ca8ca
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.0.
|
1
|
+
0.0.11
|
@@ -2,11 +2,11 @@
|
|
2
2
|
# DO NOT EDIT THIS FILE DIRECTLY
|
3
3
|
# Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
|
4
4
|
# -*- encoding: utf-8 -*-
|
5
|
-
# stub: fluent-plugin-cassandra-driver 0.0.
|
5
|
+
# stub: fluent-plugin-cassandra-driver 0.0.11 ruby lib
|
6
6
|
|
7
7
|
Gem::Specification.new do |s|
|
8
8
|
s.name = "fluent-plugin-cassandra-driver".freeze
|
9
|
-
s.version = "0.0.
|
9
|
+
s.version = "0.0.11"
|
10
10
|
|
11
11
|
s.required_rubygems_version = Gem::Requirement.new(">= 0".freeze) if s.respond_to? :required_rubygems_version=
|
12
12
|
s.require_paths = ["lib".freeze]
|
@@ -62,7 +62,7 @@ module Fluent
|
|
62
62
|
chunk.msgpack_each { |record|
|
63
63
|
$log.debug "Sending a new record to Cassandra: #{record.to_json}"
|
64
64
|
|
65
|
-
values =
|
65
|
+
values = build_insert_values(self.schema.keys, self.data_keys, record, self.pop_data_keys)
|
66
66
|
|
67
67
|
cql = "INSERT INTO #{self.columnfamily} (#{self.schema.keys.join(',')}) VALUES (#{values.length.times.map { '?' }.join(',')}) USING TTL #{self.ttl}"
|
68
68
|
|
@@ -85,7 +85,7 @@ module Fluent
|
|
85
85
|
cluster.connect(keyspace)
|
86
86
|
end
|
87
87
|
|
88
|
-
def
|
88
|
+
def build_insert_values(schema_keys, data_keys, record, pop_data_keys)
|
89
89
|
values = data_keys.map.with_index do |key, index|
|
90
90
|
value = pop_data_keys ? record.delete(key) : record[key]
|
91
91
|
type = self.schema[schema_keys[index]]
|
@@ -119,7 +119,7 @@ module Fluent
|
|
119
119
|
end
|
120
120
|
end
|
121
121
|
|
122
|
-
values
|
122
|
+
values
|
123
123
|
end
|
124
124
|
end
|
125
125
|
end
|