Repository: juspay/hyperswitch
File: crates/router/src/db/kafka_store.rs (Rust)

Code before:
        Box::new(self.clone())
    }
}

impl GlobalStorageInterface for KafkaStore {
    fn get_cache_store(&self) -> Box<(dyn RedisConnInterface + Send + Sync + 'static)> {
        Box::new(self.clone())
    }
}
impl AccountsStorageInterface for KafkaStore {}

#[async_trait::async_trait]
impl hyperswitch_domain_models::merchant_connector_account::MerchantConnectorAccountInterface
    for KafkaStore
{
    type Error = errors::StorageError;

    #[cfg(feature = "v1")]
    async fn find_merchant_connector_account_by_merchant_id_connector_label(
        &self,
        state: &KeyManagerState,
        merchant_id: &id_type::MerchantId,
        connector_label: &str,
        key_store: &domain::MerchantKeyStore,
    ) -> CustomResult<domain::MerchantConnectorAccount, Self::Error> {
        hyperswitch_domain_models::merchant_connector_account::MerchantConnectorAccountInterface::find_merchant_connector_account_by_merchant_id_connector_label(&self.diesel_store, state, merchant_id, connector_label, key_store).await
    }

    #[cfg(feature = "v1")]
    async fn find_merchant_connector_account_by_profile_id_connector_name(
        &self,
        state: &KeyManagerState,
        profile_id: &id_type::ProfileId,
        connector_name: &str,
        key_store: &domain::MerchantKeyStore,
    ) -> CustomResult<domain::MerchantConnectorAccount, Self::Error> {
        hyperswitch_domain_models::merchant_connector_account::MerchantConnectorAccountInterface::find_merchant_connector_account_by_profile_id_connector_name(&self.diesel_store, state, profile_id, connector_name, key_store).await
    }

    #[cfg(feature = "v1")]
    async fn find_merchant_connector_account_by_merchant_id_connector_name(
        &self,
        state: &KeyManagerState,
        merchant_id: &id_type::MerchantId,
        connector_name: &str,
        key_store: &domain::MerchantKeyStore,
    ) -> CustomResult<Vec<domain::MerchantConnectorAccount>, Self::Error> {
        hyperswitch_domain_models::merchant_connector_account::MerchantConnectorAccountInterface::find_merchant_connector_account_by_merchant_id_connector_name(&self.diesel_store, state, merchant_id, connector_name, key_store).await
    }

    async fn insert_merchant_connector_account(

Review comment (suggestion):
```suggestion
        merchant_connector_account::MerchantConnectorAccountInterface::find_merchant_connector_account_by_merchant_id_connector_label(&self.diesel_store, state, merchant_id, connector_label, key_store).await
```

do the same in other places too

Code after:
        Box::new(self.clone())
    }
}

impl GlobalStorageInterface for KafkaStore {
    fn get_cache_store(&self) -> Box<(dyn RedisConnInterface + Send + Sync + 'static)> {
        Box::new(self.clone())
    }
}
impl AccountsStorageInterface for KafkaStore {}

impl PaymentMethodsStorageInterface for KafkaStore {}

impl CommonStorageInterface for KafkaStore {
    fn get_storage_interface(&self) -> Box<dyn StorageInterface> {
        Box::new(self.clone())
    }
    fn get_global_storage_interface(&self) -> Box<dyn GlobalStorageInterface> {
        Box::new(self.clone())
    }
    fn get_accounts_storage_interface(&self) -> Box<dyn AccountsStorageInterface> {
        Box::new(self.clone())
    }
}

#[async_trait::async_trait]
impl SchedulerInterface for KafkaStore {}

impl MasterKeyInterface for KafkaStore {
    fn get_master_key(&self) -> &[u8] {
        self.diesel_store.get_master_key()
    }
}
#[async_trait::async_trait]
impl UserInterface for KafkaStore {
    async fn insert_user(
        &self,
        user_data: storage::UserNew,
    ) -> CustomResult<storage::User, errors::StorageError> {
        self.diesel_store.insert_user(user_data).await
    }

    async fn find_user_by_email(
        &self,
        user_email: &domain::UserEmail,
    ) -> CustomResult<storage::User, errors::StorageError> {
        self.diesel_store.find_user_by_email(user_email).await
    }

    async fn find_user_by_id(
        &self,