Skip to content

RAGFlow is an agent-native database: a Retrieval-Augmented Generation (RAG) engine that grew into context infrastructure.

[Bug] Don't display not used component status in admin status dashboard (#12355)

Jin Haia0c3bcf79838
diff --git a/admin/server/services.py b/admin/server/services.py
index 4dbbf011e5..c394dae3a6 100644
--- a/admin/server/services.py
+++ b/admin/server/services.py
@@ -13,6 +13,8 @@
# See the License for the specific language governing permissions and
# limitations under the License.
#
+
+import os
import logging
import re
from werkzeug.security import check_password_hash
@@ -179,10 +181,14 @@ class ServiceMgr:
@staticmethod
def get_all_services():
+ doc_engine = os.getenv('DOC_ENGINE', 'elasticsearch')
result = []
configs = SERVICE_CONFIGS.configs
for service_id, config in enumerate(configs):
config_dict = config.to_dict()
+ if config_dict['service_type'] == 'retrieval':
+ if config_dict['extra']['retrieval_type'] != doc_engine:
+ continue
try:
service_detail = ServiceMgr.get_service_details(service_id)
if "status" in service_detail: