You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
srs/trunk/doc
Winlin 0df81c3b34 Support HTTP-API for fetching reload result. v5.0.176 (#3779)
During a Reload, several stages will be passed through:
1. Parsing new configurations: Parse.
2. Transforming configurations: Transform.
3. Applying configurations: Apply.

Previously, any error at any stage would result in a direct exit, making
the system completely dependent on configuration checks:

```bash
./objs/srs -c conf/srs.conf -t
echo $?
```

Optimized to: If an error occurs before applying the configuration, it
can be ignored. If an error occurs during the application of the
configuration, some of the configuration may have already taken effect,
leading to unpredictable behavior, so SRS will exit directly.

Added a new HTTP API to query the result of the reload.

```nginx
http_api {
    enabled         on;
    raw_api {
        enabled on;
        allow_reload on;
    }
}
```

```bash
curl http://localhost:1985/api/v1/raw?rpc=reload-fetch
```

```json
{
  "code": 0,
  "data": {
    "err": 0,
    "msg": "Success",
    "state": 0,
    "rid": "0s6y0n9"
  }
}

{
  "code": 0,
  "data": {
    "err": 1023,
    "msg": "code=1023(ConfigInvalid) : parse file : parse buffer containers/conf/srs.release-local.conf : root parse : parse dir : parse include buffer containers/data/config/srs.vhost.conf : read token, line=0, state=0 : line 3: unexpected end of file, expecting ; or \"}\"",
    "state": 1,
    "rid": "0g4z471"
  }
}
```

This way, you can know if the last reload of the system was successful.

---------

Co-authored-by: Haibo Chen <495810242@qq.com>
2 years ago
..
Architecture.md GB28181: Fix bug for parsing GB to RTC. 2 years ago
CHANGELOG.md Support HTTP-API for fetching reload result. v5.0.176 (#3779) 2 years ago
Dockers.md Speedup test by refine the task dependencies. 3 years ago
Features.md WHIP: Support DELETE resource for Larix Broadcaster. v5.0.148 v6.0.36 (#3427) 2 years ago
PERFORMANCE.md Merge 4.0release, migrate to new website. 3 years ago
README.md Micro changes and refines. 2 years ago
Resources.md Merge 4.0release, migrate to new website. 3 years ago
ffmpeg-logo.png support ffmpeg filter 11 years ago
ffmpeg-min.png add drawtext filter sample 11 years ago
readme.txt Move doc 5 years ago
source.200kbps.768x320.flv update readme, add hls(audio-only) support to readme. update sample flv from h264+mp3 to h264+aac 11 years ago
source.flv SquashSRS4: Support RTC2RTMP. 4 years ago
srs-logo.ico Windows: Support cygwin pipline and packager. v5.0.89 (#3257) 2 years ago
srs-logo.png remove the libfreetype for it fullfill with bugs and always cause build failed. 0.9.139 11 years ago