fluent-plugin-newrelic 1.1.10 → 1.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/merge-to-master.yml +40 -0
- data/.github/workflows/pr.yml +28 -0
- data/.github/workflows/repolinter.yml +31 -0
- data/README.md +19 -5
- data/lib/fluent/plugin/out_newrelic.rb +4 -1
- data/lib/newrelic-fluentd-output/version.rb +1 -1
- metadata +6 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: aa7f85405e5ce666734d15281351981ca8d702e75efafc4b70221a5967c04426
|
4
|
+
data.tar.gz: cf1c6e0c8d5bb12f5f3c2af3adf05c414eb79ae80b700c70ab606b5ba3235c1c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e543ee72fc1808b59c121b85bc14df698c7eaeb8c762276a806f8171d07beccab88fb246f6d05277fb739602137ee77324013cf6aa87467b7528a8b89c345080
|
7
|
+
data.tar.gz: d7bcfaf304976556e14b666a5068d6cb16db89f1188712a5964e0ac25a3e5b808bf53144cbf8160bb71272c654ea35d245d395e393d43ad5bc43eabd49bf4d4b
|
@@ -0,0 +1,40 @@
|
|
1
|
+
name: New Relic Fluentd Output Plugin - Merge to master
|
2
|
+
|
3
|
+
on:
|
4
|
+
push:
|
5
|
+
branches:
|
6
|
+
- master
|
7
|
+
|
8
|
+
jobs:
|
9
|
+
ci:
|
10
|
+
name: Continuous Delivery pipeline
|
11
|
+
runs-on: ubuntu-18.04
|
12
|
+
|
13
|
+
steps:
|
14
|
+
- name: Checkout code
|
15
|
+
uses: actions/checkout@v2
|
16
|
+
|
17
|
+
- name: Setup Ruby, bundler and install dependencies
|
18
|
+
uses: ruby/setup-ruby@v1
|
19
|
+
with:
|
20
|
+
ruby-version: ruby-2.7.2
|
21
|
+
bundler-cache: true # runs 'bundle install' and caches installed gems automatically
|
22
|
+
|
23
|
+
- name: Run unit tests
|
24
|
+
run: bundle exec rake
|
25
|
+
|
26
|
+
- name: Publish Unit Test Results
|
27
|
+
uses: EnricoMi/publish-unit-test-result-action@v1.5
|
28
|
+
if: always()
|
29
|
+
with:
|
30
|
+
github_token: ${{ secrets.GITHUB_TOKEN }}
|
31
|
+
files: '**/TEST-*.xml'
|
32
|
+
|
33
|
+
- name: Build gem
|
34
|
+
run: gem build newrelic-fluentd-output.gemspec
|
35
|
+
|
36
|
+
- name: Publish fluent-plugin-newrelic to rubygems.org
|
37
|
+
env:
|
38
|
+
GEM_HOST_API_KEY: ${{ secrets.GEM_HOST_API_KEY }}
|
39
|
+
run: |
|
40
|
+
gem push fluent-plugin-newrelic-*.gem
|
@@ -0,0 +1,28 @@
|
|
1
|
+
name: New Relic Fluentd Output Plugin - Pull Request
|
2
|
+
|
3
|
+
on: [pull_request]
|
4
|
+
|
5
|
+
jobs:
|
6
|
+
ci:
|
7
|
+
name: Continuous Integration pipeline
|
8
|
+
runs-on: ubuntu-18.04
|
9
|
+
|
10
|
+
steps:
|
11
|
+
- name: Checkout code
|
12
|
+
uses: actions/checkout@v2
|
13
|
+
|
14
|
+
- name: Setup Ruby, bundler and install dependencies
|
15
|
+
uses: ruby/setup-ruby@v1
|
16
|
+
with:
|
17
|
+
ruby-version: ruby-2.5.8
|
18
|
+
bundler-cache: true # runs 'bundle install' and caches installed gems automatically
|
19
|
+
|
20
|
+
- name: Run unit tests
|
21
|
+
run: bundle exec rake
|
22
|
+
|
23
|
+
- name: Publish Unit Test Results
|
24
|
+
uses: EnricoMi/publish-unit-test-result-action@v1.5
|
25
|
+
if: always()
|
26
|
+
with:
|
27
|
+
github_token: ${{ secrets.GITHUB_TOKEN }}
|
28
|
+
files: '**/TEST-*.xml'
|
@@ -0,0 +1,31 @@
|
|
1
|
+
# NOTE: This file should always be named `repolinter.yml` to allow
|
2
|
+
# workflow_dispatch to work properly
|
3
|
+
name: Repolinter Action
|
4
|
+
|
5
|
+
# NOTE: This workflow will ONLY check the default branch!
|
6
|
+
# Currently there is no elegant way to specify the default
|
7
|
+
# branch in the event filtering, so branches are instead
|
8
|
+
# filtered in the "Test Default Branch" step.
|
9
|
+
on: [push, workflow_dispatch]
|
10
|
+
|
11
|
+
jobs:
|
12
|
+
repolint:
|
13
|
+
name: Run Repolinter
|
14
|
+
runs-on: ubuntu-latest
|
15
|
+
steps:
|
16
|
+
- name: Test Default Branch
|
17
|
+
id: default-branch
|
18
|
+
uses: actions/github-script@v2
|
19
|
+
with:
|
20
|
+
script: |
|
21
|
+
const data = await github.repos.get(context.repo)
|
22
|
+
return data.data && data.data.default_branch === context.ref.split('/').slice(-1)[0]
|
23
|
+
- name: Checkout Self
|
24
|
+
if: ${{ steps.default-branch.outputs.result == 'true' }}
|
25
|
+
uses: actions/checkout@v2
|
26
|
+
- name: Run Repolinter
|
27
|
+
if: ${{ steps.default-branch.outputs.result == 'true' }}
|
28
|
+
uses: newrelic/repolinter-action@v1
|
29
|
+
with:
|
30
|
+
config_url: https://raw.githubusercontent.com/newrelic/.github/main/repolinter-rulesets/community-plus.yml
|
31
|
+
output_type: issue
|
data/README.md
CHANGED
@@ -1,3 +1,5 @@
|
|
1
|
+
[![Community Project header](https://github.com/newrelic/opensource-website/raw/master/src/images/categories/Community_Project.png)](https://opensource.newrelic.com/oss-category/#community-project)
|
2
|
+
|
1
3
|
# fluent-plugin-newrelic
|
2
4
|
|
3
5
|
A [Fluentd](https://fluentd.org/) output plugin that sends logs to New Relic
|
@@ -29,12 +31,12 @@ For more info, review [Fluentd's official documentation](https://docs.fluentd.or
|
|
29
31
|
|
30
32
|
### Required plugin configuration
|
31
33
|
|
32
|
-
|
34
|
+
This plugin must be configured with either a New Relic API Insert key, or a New Relic License key.
|
35
|
+
If both types of keys are specified, the API Insert key will take precedence.
|
36
|
+
|
37
|
+
To specify an API Insert key, either set the `api_key` property in the configuration, or set the `NEW_RELIC_API_KEY` environment variable. If both are specified, the configuration property will take precedence.
|
33
38
|
|
34
|
-
|
35
|
-
|---|---|
|
36
|
-
| api_key | your New Relic API Insert key |
|
37
|
-
| license_key | your New Relic License key |
|
39
|
+
To specify a license key, either set the `license_key` property in the configuration, or set the `NEW_RELIC_LICENSE_KEY` environment variable. If both are specified, the configuration property will take precedence.
|
38
40
|
|
39
41
|
### Optional plugin configuration
|
40
42
|
|
@@ -84,6 +86,18 @@ Example using License key:
|
|
84
86
|
Getting your New Relic license key:
|
85
87
|
`https://rpm.newrelic.com/accounts/<ACCOUNT_ID>`
|
86
88
|
|
89
|
+
**A note about vulnerabilities**
|
90
|
+
|
91
|
+
As noted in our [security policy](../../security/policy), New Relic is committed to the privacy and security of our customers and their data. We believe that providing coordinated disclosure by security researchers and engaging with the security community are important means to achieve our security goals.
|
92
|
+
|
93
|
+
If you believe you have found a security vulnerability in this project or any of New Relic's products or websites, we welcome and greatly appreciate you reporting it to New Relic through [HackerOne](https://hackerone.com/newrelic).
|
94
|
+
|
95
|
+
If you would like to contribute to this project, review [these guidelines](https://opensource.newrelic.com/code-of-conduct/).
|
96
|
+
|
97
|
+
## License
|
98
|
+
newrelic-fluentd-output is licensed under the [Apache 2.0](http://apache.org/licenses/LICENSE-2.0.txt) License.
|
99
|
+
|
100
|
+
|
87
101
|
## Copyright
|
88
102
|
|
89
103
|
* Copyright(c) 2019 - New Relic
|
@@ -33,7 +33,7 @@ module Fluent
|
|
33
33
|
config_param :license_key, :string, :default => nil
|
34
34
|
|
35
35
|
DEFAULT_BUFFER_TYPE = 'memory'.freeze
|
36
|
-
MAX_PAYLOAD_SIZE =
|
36
|
+
MAX_PAYLOAD_SIZE = 1000000 # bytes
|
37
37
|
|
38
38
|
config_section :buffer do
|
39
39
|
config_set_default :@type, DEFAULT_BUFFER_TYPE
|
@@ -50,6 +50,9 @@ module Fluent
|
|
50
50
|
|
51
51
|
def configure(conf)
|
52
52
|
super
|
53
|
+
|
54
|
+
@api_key ||= ENV["NEW_RELIC_API_KEY"]
|
55
|
+
@license_key ||= ENV["NEW_RELIC_LICENSE_KEY"]
|
53
56
|
if @api_key.nil? && @license_key.nil?
|
54
57
|
raise Fluent::ConfigError.new("'api_key' or 'license_key' parameter is required")
|
55
58
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: fluent-plugin-newrelic
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- New Relic Logging Team
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2021-05-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: fluentd
|
@@ -102,6 +102,9 @@ extensions: []
|
|
102
102
|
extra_rdoc_files: []
|
103
103
|
files:
|
104
104
|
- ".dockerignore"
|
105
|
+
- ".github/workflows/merge-to-master.yml"
|
106
|
+
- ".github/workflows/pr.yml"
|
107
|
+
- ".github/workflows/repolinter.yml"
|
105
108
|
- ".gitignore"
|
106
109
|
- DEVELOPER.md
|
107
110
|
- Dockerfile
|
@@ -146,7 +149,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
146
149
|
- !ruby/object:Gem::Version
|
147
150
|
version: '0'
|
148
151
|
requirements: []
|
149
|
-
rubygems_version: 3.1.
|
152
|
+
rubygems_version: 3.1.4
|
150
153
|
signing_key:
|
151
154
|
specification_version: 4
|
152
155
|
summary: Sends FluentD events to New Relic
|