From 3419895643cf1b3b2dc890995908ccd7c6cebf5d Mon Sep 17 00:00:00 2001 From: thomastomy5 <69713148+thomastomy5@users.noreply.github.com> Date: Thu, 26 Mar 2026 01:39:34 +0530 Subject: [PATCH] removed get app status endpoint --- .../floconsole/controllers/app_controller.py | 44 +------------------ 1 file changed, 1 insertion(+), 43 deletions(-) diff --git a/wavefront/server/apps/floconsole/floconsole/controllers/app_controller.py b/wavefront/server/apps/floconsole/floconsole/controllers/app_controller.py index 62c2ca19..b8b0956b 100644 --- a/wavefront/server/apps/floconsole/floconsole/controllers/app_controller.py +++ b/wavefront/server/apps/floconsole/floconsole/controllers/app_controller.py @@ -380,46 +380,4 @@ async def delete_app( content=response_formatter.buildErrorResponse( f'Failed to delete app: {str(e)}' ), - ) - - -@app_router.get('/apps/{app_id}/status') -@inject -async def get_app_status( - app_id: UUID, - response_formatter: ResponseFormatter = Depends( - Provide[CommonContainer.response_formatter] - ), - app_service: AppService = Depends(Provide[ApplicationContainer.app_service]), -): - app = await app_service.get_app_by_id(app_id) - - if not app: - logger.error(f'App with ID {app_id} not found') - return JSONResponse( - status_code=status.HTTP_404_NOT_FOUND, - content=response_formatter.buildErrorResponse('App not found'), - ) - - url = f'https://{app.app_name}-floware.apps.rootflo.ai/floware' - - try: - response = requests.get(url + '/v1/health', timeout=10) - - if response.status_code == 200: - await app_service.update_app(app_id, status=AppStatus.SUCCESS) - return JSONResponse( - status_code=status.HTTP_200_OK, - content=response_formatter.buildSuccessResponse({'status': 'success'}), - ) - else: - return JSONResponse( - status_code=status.HTTP_200_OK, - content=response_formatter.buildSuccessResponse({'status': app.status}), - ) - except requests.exceptions.RequestException as e: - logger.warning(f'Health check failed for app {app.app_name}: {str(e)}') - return JSONResponse( - status_code=status.HTTP_200_OK, - content=response_formatter.buildSuccessResponse({'status': app.status}), - ) + ) \ No newline at end of file