Skip to content

Commit 66f22fe

Browse files
committed
Add stop command
1 parent d38b7f7 commit 66f22fe

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

singlestoredb/fusion/handlers/export.py

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -420,3 +420,24 @@ def run(self, params: Dict[str, Any]) -> Optional[FusionSQLResult]:
420420

421421

422422
ShowExport.register(overwrite=True)
423+
424+
425+
class StopExport(SQLHandler):
426+
"""
427+
STOP EXPORT export_id;
428+
429+
# ID of export
430+
export_id = '<export-id>'
431+
432+
"""
433+
434+
_enabled = False
435+
436+
def run(self, params: Dict[str, Any]) -> Optional[FusionSQLResult]:
437+
wsg = get_workspace_group({})
438+
service = ExportService.from_export_id(wsg, params['export_id'])
439+
service.stop()
440+
return None
441+
442+
443+
StopExport.register(overwrite=True)

0 commit comments

Comments
 (0)