fluent-plugin-watch-objectspace 0.2.0 → 0.2.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 +4 -4
- data/CHANGELOG.md +21 -0
- data/README.md +22 -11
- data/fluent-plugin-watch-objectspace.gemspec +1 -1
- data/lib/fluent/plugin/in_watch_objectspace.rb +2 -2
- metadata +2 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 19ba7128bca625929870b7a571421b0684285005536709de94f7a36abcbbc9b7
|
4
|
+
data.tar.gz: d7f0d3eeb7e1869ef62b956fab42c9b798fcf4c097d146b944b75cec2033f895
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 450b9e0e801529c7f1b975714878a34ef04aaa4bcf68ce086ad1d8d141a3dfdee0c52956cd21686d189f49611947fbc196cb578bef37a75113571e7b064a429a
|
7
|
+
data.tar.gz: c06ca2aaa35dcc317eeb9472a550b3f8dd315fd1fa03aa01629b856f690c8ee9accc26d94f8e67ebe6e68cd980ac81f726e6d5f127ec8987dbf6210b262afe44
|
data/CHANGELOG.md
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
# 0.2.1
|
2
|
+
|
3
|
+
## Release v0.2.1 - 2021/09/30
|
4
|
+
|
5
|
+
* Fixed to use appropriate error log message
|
6
|
+
* Updated README.md about configuration section
|
7
|
+
|
8
|
+
# 0.2.0
|
9
|
+
|
10
|
+
## Release v0.2.0 - 2021/09/30
|
11
|
+
|
12
|
+
* Refactor config_section
|
13
|
+
The threshold value must be put under <threshold> section
|
14
|
+
* Fixed an crash bug when watch_class parameter is not set
|
15
|
+
|
16
|
+
# 0.1.0
|
17
|
+
|
18
|
+
## Release v0.1.0 - 2021/09/24
|
19
|
+
|
20
|
+
* Initial release
|
21
|
+
|
data/README.md
CHANGED
@@ -29,19 +29,28 @@ $ bundle
|
|
29
29
|
## Configuration
|
30
30
|
|
31
31
|
|
32
|
-
| parameter
|
33
|
-
|
34
|
-
| watch_class
|
35
|
-
| watch_interval
|
36
|
-
| tag
|
37
|
-
| modules
|
38
|
-
| watch_delay
|
39
|
-
| gc_raw_data
|
40
|
-
|
|
32
|
+
| parameter | type | description | default |
|
33
|
+
|----------------|-------------------|----------------------------------------|---------------------------------------------------|
|
34
|
+
| watch_class | array (optional) | Class to be watched | |
|
35
|
+
| watch_interval | time (optional) | Interval to watch object space | `60` |
|
36
|
+
| tag | string (optional) | Tag for this input plugin | `watch_objectspace` |
|
37
|
+
| modules | array (optional) | Modules which must be required | |
|
38
|
+
| watch_delay | time (optional) | Delayed seconds until process start up | `60` |
|
39
|
+
| gc_raw_data | bool (optional) | Collect GC::Profiler.raw_data | |
|
40
|
+
| top_fields | array (optional) | Specify included fields of top command | `["VIRT", "RES", "SHR", "%CPU", "%MEM", "TIME+"]` |
|
41
41
|
|
42
|
-
|
42
|
+
### \<threshold\> section (optional) (single)
|
43
|
+
|
44
|
+
### Configuration
|
45
|
+
|
46
|
+
|parameter|type|description|default|
|
47
|
+
|---|---|---|---|
|
48
|
+
|memsize_of_all|float (optional)|Threshold rate which regards increased memsize as memory leaks|`1.3`|
|
49
|
+
|res_of_top|float (optional)|Threshold rate which regards increased RES as memory leaks||
|
43
50
|
|
44
51
|
|
52
|
+
## Usage
|
53
|
+
|
45
54
|
```
|
46
55
|
<source>
|
47
56
|
@type watch_objectspace
|
@@ -50,7 +59,9 @@ $ bundle
|
|
50
59
|
watch_class CMetrics::Counter, CMetrics::Gauge, CMetrics::Untyped
|
51
60
|
watch_interval 60
|
52
61
|
watch_delay 10
|
53
|
-
|
62
|
+
<threshold>
|
63
|
+
memsize_of_all 1.3
|
64
|
+
</threshold>
|
54
65
|
</source>
|
55
66
|
```
|
56
67
|
|
@@ -130,7 +130,7 @@ module Fluent
|
|
130
130
|
if @threshold.res_of_top
|
131
131
|
if @source["res"] * @threshold.res_of_top < record["res"]
|
132
132
|
record["memory_leaks"] = true
|
133
|
-
message = sprintf("Memory
|
133
|
+
message = sprintf("Memory usage is over than expected, threshold res_of_top rate <%f>: %f > %f * %f",
|
134
134
|
@threshold.res_of_top, record["res"],
|
135
135
|
@source["res"], @threshold.res_of_top)
|
136
136
|
raise message
|
@@ -139,7 +139,7 @@ module Fluent
|
|
139
139
|
if @threshold.memsize_of_all
|
140
140
|
if @source["memsize_of_all"] * @threshold.memsize_of_all < record["memsize_of_all"]
|
141
141
|
record["memory_leaks"] = true
|
142
|
-
message = sprintf("Memory
|
142
|
+
message = sprintf("Memory usage is over than expected, threshold of memsize_of_all rate <%f>: %f > %f * %f",
|
143
143
|
@threshold.memsize_of_all, record["memsize_of_all"],
|
144
144
|
@source["memsize_of_all"], @threshold.memsize_of_all)
|
145
145
|
raise message
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: fluent-plugin-watch-objectspace
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Kentaro Hayashi
|
@@ -94,6 +94,7 @@ executables: []
|
|
94
94
|
extensions: []
|
95
95
|
extra_rdoc_files: []
|
96
96
|
files:
|
97
|
+
- CHANGELOG.md
|
97
98
|
- Gemfile
|
98
99
|
- LICENSE
|
99
100
|
- README.md
|