Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
F
fluent-plugin-wendelin
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Ekaterina
fluent-plugin-wendelin
Commits
89ad9b03
Commit
89ad9b03
authored
Jul 03, 2020
by
Ekaterina
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add: out_wendelin_formatted.rb
parent
ea3550ee
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
55 additions
and
0 deletions
+55
-0
lib/fluent/plugin/out_wendelin_formatted.rb
lib/fluent/plugin/out_wendelin_formatted.rb
+55
-0
No files found.
lib/fluent/plugin/out_wendelin_formatted.rb
0 → 100644
View file @
89ad9b03
# Fluentd output plugin to ingest data to Wendelin system
# Copyright (C) 2015 Nexedi SA and Contributors.
# Kirill Smelkov <kirr@nexedi.com>
#
# This program is free software: you can Use, Study, Modify and Redistribute
# it under the terms of the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# This plugin hooks into Fluentd in a way similiar to out_forward and
# out_secure_forward and outputs event stream to a Wendelin HTTP endpoint.
require
'fluent/plugin/formatter'
require_relative
'out_wendelin'
module
Fluent::Plugin
class
WendelinOutputFormatted
<
WendelinOutput
Fluent
::
Plugin
.
register_output
(
'wendelin_formatted'
,
self
)
helpers
:formatter
config_section
:format
do
config_set_default
:@type
,
'single_value'
end
def
configure
(
conf
)
super
@formatter
=
formatter_create
end
def
formatted_to_msgpack_binary?
@formatter_configs
.
first
[
:@type
]
==
'msgpack'
end
def
format
(
tag
,
time
,
record
)
@formatter
.
format
(
tag
,
time
,
record
)
end
def
write
(
chunk
)
super
end
end
end
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment