Skip to content

Commit 772d956

Browse files
JWittmeyerJWittmeyer
andauthored
Adds config changed endpoint (#28)
Co-authored-by: JWittmeyer <[email protected]>
1 parent 74143f2 commit 772d956

File tree

2 files changed

+8
-2
lines changed

2 files changed

+8
-2
lines changed

app.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
import torch
77

88
from submodules.model.business_objects import general
9-
from util import request_util
9+
from util import request_util, config_handler
1010

1111
app = FastAPI()
1212

@@ -122,3 +122,9 @@ def upload_tensor_data(project_id: str, embedding_id: str) -> Tuple[int, str]:
122122
request_util.post_embedding_to_neural_search(project_id, embedding_id)
123123
general.remove_and_refresh_session(session_token)
124124
return 200, ""
125+
126+
127+
@app.put("/config_changed")
128+
def config_changed() -> int:
129+
config_handler.refresh_config()
130+
return 200

0 commit comments

Comments
 (0)