From f762f4f5854eeb7a78c78149075804ee4f07bb25 Mon Sep 17 00:00:00 2001 From: sweta-sharma <77436883+swetasharma03@users.noreply.github.com> Date: Mon, 18 Aug 2025 13:17:52 +0530 Subject: [PATCH] fix(core): connector customer id population dependency removed from config (#8937) --- config/config.example.toml | 2 +- config/deployments/integration_test.toml | 2 +- config/deployments/production.toml | 2 +- config/deployments/sandbox.toml | 2 +- config/development.toml | 2 +- config/docker_compose.toml | 2 +- crates/router/src/core/payments/customers.rs | 11 ++++++----- loadtest/config/development.toml | 2 +- 8 files changed, 13 insertions(+), 12 deletions(-) diff --git a/config/config.example.toml b/config/config.example.toml index 2559a157b3..91a663d88a 100644 --- a/config/config.example.toml +++ b/config/config.example.toml @@ -900,7 +900,7 @@ pix = { country = "BR", currency = "BRL" } bluecode = { country = "AT,BE,BG,HR,CY,CZ,DK,EE,FI,FR,DE,GR,HU,IE,IT,LV,LT,LU,MT,NL,PL,PT,RO,SK,SI,ES,SE,IS,LI,NO", currency = "EUR" } [connector_customer] -connector_list = "adyen,authorizedotnet,facilitapay,gocardless,hyperswitch_vault,stax,stripe" +connector_list = "authorizedotnet,facilitapay,gocardless,hyperswitch_vault,stax,stripe" payout_connector_list = "nomupay,stripe,wise" [bank_config.online_banking_fpx] diff --git a/config/deployments/integration_test.toml b/config/deployments/integration_test.toml index d4fa61acb4..40f755b104 100644 --- a/config/deployments/integration_test.toml +++ b/config/deployments/integration_test.toml @@ -194,7 +194,7 @@ force_cookies = true enabled = true [connector_customer] -connector_list = "adyen,authorizedotnet,facilitapay,gocardless,hyperswitch_vault,stax,stripe" +connector_list = "authorizedotnet,facilitapay,gocardless,hyperswitch_vault,stax,stripe" payout_connector_list = "nomupay,stripe,wise" [delayed_session_response] diff --git a/config/deployments/production.toml b/config/deployments/production.toml index fedfd2d142..3ea362f8a6 100644 --- a/config/deployments/production.toml +++ b/config/deployments/production.toml @@ -15,7 +15,7 @@ open_banking_uk.adyen.banks = "aib,bank_of_scotland,danske_bank,first_direct,fir przelewy24.stripe.banks = "alior_bank,bank_millennium,bank_nowy_bfg_sa,bank_pekao_sa,banki_spbdzielcze,blik,bnp_paribas,boz,citi,credit_agricole,e_transfer_pocztowy24,getin_bank,idea_bank,inteligo,mbank_mtransfer,nest_przelew,noble_pay,pbac_z_ipko,plus_bank,santander_przelew24,toyota_bank,volkswagen_bank" [connector_customer] -connector_list = "adyen,authorizedotnet,facilitapay,gocardless,hyperswitch_vault,stax,stripe" +connector_list = "authorizedotnet,facilitapay,gocardless,hyperswitch_vault,stax,stripe" payout_connector_list = "nomupay,stripe,wise" # Connector configuration, provided attributes will be used to fulfill API requests. diff --git a/config/deployments/sandbox.toml b/config/deployments/sandbox.toml index cc688456bc..3044dde9dc 100644 --- a/config/deployments/sandbox.toml +++ b/config/deployments/sandbox.toml @@ -15,7 +15,7 @@ open_banking_uk.adyen.banks = "aib,bank_of_scotland,danske_bank,first_direct,fir przelewy24.stripe.banks = "alior_bank,bank_millennium,bank_nowy_bfg_sa,bank_pekao_sa,banki_spbdzielcze,blik,bnp_paribas,boz,citi,credit_agricole,e_transfer_pocztowy24,getin_bank,idea_bank,inteligo,mbank_mtransfer,nest_przelew,noble_pay,pbac_z_ipko,plus_bank,santander_przelew24,toyota_bank,volkswagen_bank" [connector_customer] -connector_list = "adyen,authorizedotnet,facilitapay,gocardless,hyperswitch_vault,stax,stripe" +connector_list = "authorizedotnet,facilitapay,gocardless,hyperswitch_vault,stax,stripe" payout_connector_list = "nomupay,stripe,wise" # Connector configuration, provided attributes will be used to fulfill API requests. diff --git a/config/development.toml b/config/development.toml index c20d7487db..02e1449793 100644 --- a/config/development.toml +++ b/config/development.toml @@ -958,7 +958,7 @@ nexixpay = { payment_method = "card" } redsys = { payment_method = "card" } [connector_customer] -connector_list = "adyen,authorizedotnet,facilitapay,gocardless,hyperswitch_vault,stax,stripe" +connector_list = "authorizedotnet,facilitapay,gocardless,hyperswitch_vault,stax,stripe" payout_connector_list = "nomupay,stripe,wise" [dummy_connector] diff --git a/config/docker_compose.toml b/config/docker_compose.toml index a96d9b88be..9b619f3d35 100644 --- a/config/docker_compose.toml +++ b/config/docker_compose.toml @@ -959,7 +959,7 @@ card.debit = { connector_list = "cybersource" } connector_list = "adyen,archipel,cybersource,novalnet,stripe,worldpay,worldpayvantiv" [connector_customer] -connector_list = "adyen,authorizedotnet,facilitapay,gocardless,hyperswitch_vault,stax,stripe" +connector_list = "authorizedotnet,facilitapay,gocardless,hyperswitch_vault,stax,stripe" payout_connector_list = "nomupay,stripe,wise" diff --git a/crates/router/src/core/payments/customers.rs b/crates/router/src/core/payments/customers.rs index 210a6dd09f..d1fc40aef3 100644 --- a/crates/router/src/core/payments/customers.rs +++ b/crates/router/src/core/payments/customers.rs @@ -87,15 +87,16 @@ pub fn should_call_connector_create_customer<'a>( .connector_customer .connector_list .contains(&connector.connector_name); - + let connector_customer_details = customer + .as_ref() + .and_then(|customer| customer.get_connector_customer_id(connector_label)); if connector_needs_customer { - let connector_customer_details = customer - .as_ref() - .and_then(|customer| customer.get_connector_customer_id(connector_label)); let should_call_connector = connector_customer_details.is_none(); (should_call_connector, connector_customer_details) } else { - (false, None) + // Populates connector_customer_id if it is present after data migration + // For connector which does not have create connector customer flow + (false, connector_customer_details) } } diff --git a/loadtest/config/development.toml b/loadtest/config/development.toml index e3fe4e7722..a2f38e7dd4 100644 --- a/loadtest/config/development.toml +++ b/loadtest/config/development.toml @@ -640,7 +640,7 @@ billwerk = { long_lived_token = false, payment_method = "card" } globalpay = { long_lived_token = false, payment_method = "card", flow = "mandates" } [connector_customer] -connector_list = "adyen,authorizedotnet,facilitapay,gocardless,hyperswitch_vault,stax,stripe" +connector_list = "authorizedotnet,facilitapay,gocardless,hyperswitch_vault,stax,stripe" payout_connector_list = "nomupay,wise" [dummy_connector]