From 7e77235d5ee140d1d106c07fdb610579157d3bfc Mon Sep 17 00:00:00 2001 From: Hao Liu <44379968+TheRealHaoLiu@users.noreply.github.com> Date: Mon, 22 Jul 2024 16:47:11 -0400 Subject: [PATCH] Add UI for RECEPTOR_KEEP_WORK_ON_ERROR In Troubleshooting settings --- .../TroubleshootingEdit/TroubleshootingEdit.js | 4 ++++ .../data.defaultTroubleshootingSettings.json | 5 +++-- .../Setting/shared/data.allSettingOptions.json | 17 +++++++++++++++++ .../Setting/shared/data.allSettings.json | 1 + 4 files changed, 25 insertions(+), 2 deletions(-) diff --git a/awx/ui/src/screens/Setting/Troubleshooting/TroubleshootingEdit/TroubleshootingEdit.js b/awx/ui/src/screens/Setting/Troubleshooting/TroubleshootingEdit/TroubleshootingEdit.js index 1ff860d329c0..a28afeb5922b 100644 --- a/awx/ui/src/screens/Setting/Troubleshooting/TroubleshootingEdit/TroubleshootingEdit.js +++ b/awx/ui/src/screens/Setting/Troubleshooting/TroubleshootingEdit/TroubleshootingEdit.js @@ -117,6 +117,10 @@ function TroubleshootingEdit() { name="RECEPTOR_RELEASE_WORK" config={debug.RECEPTOR_RELEASE_WORK} /> + {submitError && } {revertError && } diff --git a/awx/ui/src/screens/Setting/Troubleshooting/TroubleshootingEdit/data.defaultTroubleshootingSettings.json b/awx/ui/src/screens/Setting/Troubleshooting/TroubleshootingEdit/data.defaultTroubleshootingSettings.json index 2b5ac1700382..35983281fde3 100644 --- a/awx/ui/src/screens/Setting/Troubleshooting/TroubleshootingEdit/data.defaultTroubleshootingSettings.json +++ b/awx/ui/src/screens/Setting/Troubleshooting/TroubleshootingEdit/data.defaultTroubleshootingSettings.json @@ -1,5 +1,6 @@ { "AWX_CLEANUP_PATHS": false, "AWX_REQUEST_PROFILE": false, - "RECEPTOR_RELEASE_WORK": false -} \ No newline at end of file + "RECEPTOR_RELEASE_WORK": false, + "RECEPTOR_KEEP_WORK_ON_ERROR": false +} diff --git a/awx/ui/src/screens/Setting/shared/data.allSettingOptions.json b/awx/ui/src/screens/Setting/shared/data.allSettingOptions.json index d544bcf42734..de027f2b6c2d 100644 --- a/awx/ui/src/screens/Setting/shared/data.allSettingOptions.json +++ b/awx/ui/src/screens/Setting/shared/data.allSettingOptions.json @@ -830,6 +830,15 @@ "category_slug": "debug", "default": true }, + "RECEPTOR_KEEP_WORK_ON_ERROR": { + "type": "boolean", + "required": false, + "label": "Keep receptor work on error", + "help_text": "Prevent receptor work from being released on when error is detected", + "category": "Debug", + "category_slug": "debug", + "default": false + }, "SESSION_COOKIE_AGE": { "type": "integer", "required": true, @@ -5173,6 +5182,14 @@ "category_slug": "debug", "defined_in_file": false }, + "RECEPTOR_KEEP_WORK_ON_ERROR": { + "type": "boolean", + "label": "Keep receptor work on error", + "help_text": "Prevent receptor work from being released on when error is detected", + "category": "Debug", + "category_slug": "debug", + "defined_in_file": false + }, "SESSION_COOKIE_AGE": { "type": "integer", "label": "Idle Time Force Log Out", diff --git a/awx/ui/src/screens/Setting/shared/data.allSettings.json b/awx/ui/src/screens/Setting/shared/data.allSettings.json index 37d560537a6d..558d66d15194 100644 --- a/awx/ui/src/screens/Setting/shared/data.allSettings.json +++ b/awx/ui/src/screens/Setting/shared/data.allSettings.json @@ -91,6 +91,7 @@ "slirp4netns:enable_ipv6=true" ], "RECEPTOR_RELEASE_WORK": true, + "RECEPTOR_KEEP_WORK_ON_ERROR": false, "SESSION_COOKIE_AGE": 1800, "SESSIONS_PER_USER": -1, "DISABLE_LOCAL_AUTH": false,