From a75a1f84c4648df810bcea5271ef44a3ae08fd37 Mon Sep 17 00:00:00 2001 From: Bugen Zhao Date: Fri, 23 Feb 2024 11:45:13 +0800 Subject: [PATCH] why still not pass? Signed-off-by: Bugen Zhao --- e2e_test/source/basic/ddl.slt | 3 ++- src/meta/service/src/cloud_service.rs | 14 +++++++------- 2 files changed, 9 insertions(+), 8 deletions(-) diff --git a/e2e_test/source/basic/ddl.slt b/e2e_test/source/basic/ddl.slt index 6e640e047d4c2..402cf129b86ba 100644 --- a/e2e_test/source/basic/ddl.slt +++ b/e2e_test/source/basic/ddl.slt @@ -28,7 +28,8 @@ db error: ERROR: Failed to run the query Caused by these errors (recent errors listed first): 1: gRPC request to meta service failed: Internal error 2: failed to create source worker - 3: missing field `properties.bootstrap.server` + 3: failed to parse json + 4: missing field `properties.bootstrap.server` statement error diff --git a/src/meta/service/src/cloud_service.rs b/src/meta/service/src/cloud_service.rs index c309a46f39cbd..9c213bd7cb9e2 100644 --- a/src/meta/service/src/cloud_service.rs +++ b/src/meta/service/src/cloud_service.rs @@ -136,7 +136,7 @@ impl CloudService for CloudServiceImpl { { return Ok(new_rwc_validate_fail_response( ErrorType::PrivatelinkResolveErr, - e.to_string(), + e.to_report_string(), )); } } else { @@ -152,7 +152,7 @@ impl CloudService for CloudServiceImpl { if let Err(e) = props { return Ok(new_rwc_validate_fail_response( ErrorType::KafkaInvalidProperties, - e.to_string(), + e.to_report_string(), )); }; @@ -167,15 +167,15 @@ impl CloudService for CloudServiceImpl { if let Err(e) = enumerator { return Ok(new_rwc_validate_fail_response( ErrorType::KafkaInvalidProperties, - e.to_string(), + e.to_report_string(), )); } if let Err(e) = enumerator.unwrap().list_splits().await { - let error_message = e.to_string(); + let error_message = e.to_report_string(); if error_message.contains("BrokerTransportFailure") { return Ok(new_rwc_validate_fail_response( ErrorType::KafkaBrokerUnreachable, - e.to_string(), + e.to_report_string(), )); } static TOPIC_NOT_FOUND: LazyLock = @@ -183,12 +183,12 @@ impl CloudService for CloudServiceImpl { if TOPIC_NOT_FOUND.is_match(error_message.as_str()) { return Ok(new_rwc_validate_fail_response( ErrorType::KafkaTopicNotFound, - e.to_string(), + e.to_report_string(), )); } return Ok(new_rwc_validate_fail_response( ErrorType::KafkaOther, - e.to_string(), + e.to_report_string(), )); } });