Skip to content

Commit a07e303

Browse files
authored
Replace yajl-ruby with the json gem for JSON handling (#174)
Since the yajl-ruby gem depends on a deprecated Ruby C API, it cannot be installed with Ruby 4.1. Signed-off-by: Shizuo Fujita <fujita@clear-code.com>
1 parent 707a241 commit a07e303

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

lib/fluent/plugin/out_sql.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ def import(chunk, output)
9999
columns |= new_record.keys
100100
records << @model.new(new_record)
101101
rescue => e
102-
args = {error: e, table: @table, record: Yajl.dump(data)}
102+
args = {error: e, table: @table, record: JSON.generate(data)}
103103
@log.warn "Failed to create the model. Ignore a record:", args
104104
end
105105
}

0 commit comments

Comments
 (0)