Aman-Mittal commented on code in PR #155: URL: https://github.com/apache/fineract-consumer-facing/pull/155#discussion_r4293034470
########## consumer/src/test/resources/archunit_store/feature-classes-do-not-depend-on-the-generated-fineract-feign-clients-fd283b04.txt: ########## @@ -31,6 +31,7 @@ Constructor <org.apache.fineract.consumer.loans.query.service.LoansQueryServiceI Constructor <org.apache.fineract.consumer.loans.query.service.LoansQueryServiceImpl.<init>(org.apache.fineract.consumer.infrastructure.fineractclient.generated.api.LoansApi, org.apache.fineract.consumer.infrastructure.fineractclient.generated.api.LoanTransactionsApi, org.apache.fineract.consumer.infrastructure.fineractclient.generated.api.LoanChargesApi, org.apache.fineract.consumer.infrastructure.fineractclient.generated.api.GuarantorsApi, org.apache.fineract.consumer.infrastructure.fineractclient.generated.api.LoanProductsApi, org.apache.fineract.consumer.infrastructure.fineractclient.generated.api.ClientApi, org.apache.fineract.consumer.infrastructure.access.service.AccessPolicyEvaluator, org.apache.fineract.consumer.infrastructure.access.service.UserClientResolver)> has parameter of type <org.apache.fineract.consumer.infrastructure.fineractclient.generated.api.LoanProductsApi> in (LoansQueryServiceImpl.java:0) Constructor <org.apache.fineract.consumer.loans.query.service.LoansQueryServiceImpl.<init>(org.apache.fineract.consumer.infrastructure.fineractclient.generated.api.LoansApi, org.apache.fineract.consumer.infrastructure.fineractclient.generated.api.LoanTransactionsApi, org.apache.fineract.consumer.infrastructure.fineractclient.generated.api.LoanChargesApi, org.apache.fineract.consumer.infrastructure.fineractclient.generated.api.GuarantorsApi, org.apache.fineract.consumer.infrastructure.fineractclient.generated.api.LoanProductsApi, org.apache.fineract.consumer.infrastructure.fineractclient.generated.api.ClientApi, org.apache.fineract.consumer.infrastructure.access.service.AccessPolicyEvaluator, org.apache.fineract.consumer.infrastructure.access.service.UserClientResolver)> has parameter of type <org.apache.fineract.consumer.infrastructure.fineractclient.generated.api.LoanTransactionsApi> in (LoansQueryServiceImpl.java:0) Constructor <org.apache.fineract.consumer.loans.query.service.LoansQueryServiceImpl.<init>(org.apache.fineract.consumer.infrastructure.fineractclient.generated.api.LoansApi, org.apache.fineract.consumer.infrastructure.fineractclient.generated.api.LoanTransactionsApi, org.apache.fineract.consumer.infrastructure.fineractclient.generated.api.LoanChargesApi, org.apache.fineract.consumer.infrastructure.fineractclient.generated.api.GuarantorsApi, org.apache.fineract.consumer.infrastructure.fineractclient.generated.api.LoanProductsApi, org.apache.fineract.consumer.infrastructure.fineractclient.generated.api.ClientApi, org.apache.fineract.consumer.infrastructure.access.service.AccessPolicyEvaluator, org.apache.fineract.consumer.infrastructure.access.service.UserClientResolver)> has parameter of type <org.apache.fineract.consumer.infrastructure.fineractclient.generated.api.LoansApi> in (LoansQueryServiceImpl.java:0) +Constructor <org.apache.fineract.consumer.savings.command.service.SavingsCommandServiceImpl.<init>(org.apache.fineract.consumer.user.query.service.UserQueryService, org.apache.fineract.consumer.infrastructure.access.service.AccessPolicyEvaluator, org.apache.fineract.consumer.infrastructure.access.service.OwnedAccountsCache, org.apache.fineract.consumer.infrastructure.idempotency.service.IdempotencyKeyHolder, org.apache.fineract.consumer.infrastructure.fineractclient.generated.api.SavingsAccountApi)> has parameter of type <org.apache.fineract.consumer.infrastructure.fineractclient.generated.api.SavingsAccountApi> in (SavingsCommandServiceImpl.java:0) Review Comment: **Blocking: lines added by hand to the frozen ArchUnit store.** This PR adds 5 lines (the constructor, the field and 3 method calls) for the new `SavingsCommandServiceImpl`. The store is shrink-only by design: - the header of this file says "Do not edit by hand … Adding lines is never allowed: fix new violations instead"; - `AGENTS.md`: "The store only shrinks … never add entries by hand"; - `docs/consumer/architecture/modules.adoc`: "the existing direct uses are frozen … so no new feature class may inject a generated client". CI only passes because `ShrinkOnlyViolationStore` compares the current violations with whatever lines the file contains, so lines added by hand are accepted as baseline. Please revert the changes to this file and move the three `SavingsAccountApi` calls (`submitSavingsApplication`, `updateSavingsAccount`, `handleCommandsSavingsAccount`) behind a narrow interface + impl in `consumer.infrastructure`, following the existing infrastructure classes that call generated clients (`OwnedAccountsCache`, `ClientStandingChecker`). `SavingsCommandServiceImpl` should then depend only on that interface. Keep `FineractCaller` error translation in the feature service, or pass the mappers in, so the `savings.command` error codes stay the same. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
