2
2
description : Enable hot reload through SIGHUP signal or an HTTP endpoint
3
3
---
4
4
5
- # Hot Reload
5
+ # Hot reload
6
6
7
- Fluent Bit supports the hot reloading feature when enabled via the configuration file or command line with ` -Y ` or ` --enable-hot-reload ` option.
7
+ Fluent Bit supports the reloading feature when enabled in the configuration file
8
+ or on the command line with ` -Y ` or ` --enable-hot-reload ` option.
8
9
9
- ## Getting Started
10
+ Hot reloading is supported on Linux, macOS, and Windows operating systems.
10
11
11
- To get started with reloading via HTTP, the first step is to enable the HTTP Server from the configuration file:
12
+ ## Update the configuration
12
13
13
- ``` toml
14
+ To get started with reloading over HTTP, enable the HTTP Server
15
+ in the configuration file:
16
+
17
+ ``` text
14
18
[SERVICE]
15
19
HTTP_Server On
16
20
HTTP_Listen 0.0.0.0
@@ -19,47 +23,44 @@ To get started with reloading via HTTP, the first step is to enable the HTTP Ser
19
23
...
20
24
```
21
25
22
- The above configuration snippet will enable the HTTP endpoint for hot reloading.
23
-
24
26
## How to reload
25
27
26
- ### Via HTTP
28
+ After updating the configuration, use one of the following methods to perform a
29
+ hot reload:
27
30
28
- Hot reloading can be kicked via HTTP endpoints that are:
31
+ ### HTTP
29
32
30
- * ` PUT /api/v2/reload `
31
- * ` POST /api/v2/reload `
33
+ Use the following HTTP endpoints to perform a hot reload:
32
34
33
- If users don't enable the hot reloading feature, hot reloading via these endpoints will not work.
35
+ - ` PUT /api/v2/reload `
36
+ - ` POST /api/v2/reload `
34
37
35
38
For using curl to reload Fluent Bit, users must specify an empty request body as:
36
39
37
40
``` text
38
- $ curl -X POST -d '{}' localhost:2020/api/v2/reload
41
+ curl -X POST -d '{}' localhost:2020/api/v2/reload
39
42
```
40
43
41
- ### Via Signal
44
+ ### Signal
42
45
43
- Hot reloading also can be kicked via ` SIGHUP ` .
46
+ Hot reloading can be used with ` SIGHUP ` .
44
47
45
- ` SIGHUP ` signal is not supported on Windows. So, users can 't enable this feature on Windows.
48
+ ` SIGHUP ` signal isn 't supported on Windows.
46
49
47
- ## How to confirm reloaded or not
50
+ ## Confirm a reload
48
51
49
- ### via HTTP
52
+ Use one of the following methods to confirm the reload occurred.
50
53
51
- The number of hot reloaded count can be obtained via the HTTP endpoint that is:
54
+ ### HTTP
52
55
53
- * ` GET /api/v2/ reload`
56
+ Obtain a count of hot reload using the HTTP endpoint:
54
57
55
- The endpoint returns the count of hot-reloaded as follows:
58
+ - ` GET /api/v2/reload `
59
+
60
+ The endpoint returns ` hot_reload_count ` as follows:
56
61
57
62
``` json
58
63
{"hot_reload_count" :3 }
59
64
```
60
65
61
- The default value of that number is 0.
62
-
63
- ## Limitations
64
-
65
- The hot reloading feature is currently working on Linux, macOS and Windows.
66
+ The default value of the counter is ` 0 ` .
0 commit comments