server: support /models/sse on single-model mode (#32398)
* server: support /models/sse on single-model mode * nits * nits
This commit is contained in:
1 parent
8d60873dfb
commit
0b51bb2fed
12 files changed
+273
-113
No files matched your search
@@ -396,6 +396,9 @@ bool server_http_context::init_listener(const common_params & params) {
|
||||
if (frontend_paths.count(req.path)) {
|
||||
return true; // frontend asset, allow it to load and show "loading"
|
||||
}
|
||||
if (req.path == "/models/sse") {
|
||||
return true; // reports the download and loading progress
|
||||
}
|
||||
// no endpoints are allowed to be accessed when the server is not ready
|
||||
// this is to prevent any data races or inconsistent states
|
||||
res.status = 503;
|
||||
|
||||
Reference in new issue
Block a user