Skip to content

FINERACT-2293: Migrate client address module to new command pipeline#5657

Draft
avivijay19 wants to merge 2 commits intoapache:developfrom
avivijay19:FINERACT-2293
Draft

FINERACT-2293: Migrate client address module to new command pipeline#5657
avivijay19 wants to merge 2 commits intoapache:developfrom
avivijay19:FINERACT-2293

Conversation

@avivijay19
Copy link
Copy Markdown
Contributor

Description

Describe the changes made and why they were made. (Ignore if these details are present on the associated Apache Fineract JIRA ticket.)

Checklist

Please make sure these boxes are checked before submitting your pull request - thanks!

  • Write the commit message as per our guidelines
  • Acknowledge that we will not review PRs that are not passing the build ("green") - it is your responsibility to get a proposed PR to pass the build, not primarily the project's maintainers.
  • Create/update unit or integration tests for verifying the changes made.
  • Follow our coding conventions.
  • Add required Swagger annotation and update API documentation at fineract-provider/src/main/resources/static/legacy-docs/apiLive.htm with details of any API changes
  • This PR must not be a "code dump". Large changes can be made in a branch, with assistance. Ask for help on the developer mailing list.

Your assigned reviewer(s) will follow our guidelines for code reviews.

Comment thread fineract-provider/src/main/resources/application.properties
@avivijay19 avivijay19 force-pushed the FINERACT-2293 branch 2 times, most recently from 602cd1a to 91c3b39 Compare March 22, 2026 18:36
Comment thread fineract-provider/src/main/resources/application.properties Outdated
}

@Override
public void addNewClientAddress(Client client, List<ClientAddressCreateRequest> requests) {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why do we need this loop inside this service? I bet this is called only in 1 place... let's create the loop there... no added value hiding 3 lines of code in a service and they add basically no new functionality. We are not saving anything here... unless you tell me we are calling this function in 57 places...

}
}

private Address createAddressFromRequest(ClientAddressCreateRequest request) {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can move to createClientAddres function once we have remove that other one with the loop.

import org.springframework.jdbc.core.JdbcTemplate;

@Configuration
public class AddressConfiguration {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ClientAddressConfiguration.... consistency...


import io.swagger.v3.oas.annotations.media.Schema;
import java.time.LocalDate;
import java.util.HashMap;
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As soon as we read "XXXSwagger.java" something is wrong aka not finished. Again, these are the dummy classes we intend to remove... mentioned it already a couple of times... maybe go slower with the changes and double check yourself before you submit.


if (isAddressEnabled) {
this.addressWritePlatformService.addNewClientAddress(newClient, command);
final com.google.gson.JsonArray addressArray = command.arrayOfParameterNamed("address");
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is not type safety! This kind of thing is now consistently slipping through the cracks. ANYTHING:

  • GSON
  • xxxParamterNamed
  • JsonArray
  • JsonXXX
  • JsonCommand
  • CommandWrapper
  • CommandBuilder

... needs to go, because this is the goal of this exercise, to make things type safe... all of the above is not. Again, maybe go a bit slower... otherwise this feels a bit like a prompt loop. I don't mind reviewing... but let's keep an eye on these details.

@Aman-Mittal
Copy link
Copy Markdown
Contributor

@avivijay19 plz resolve conflicts

@adamsaghy
Copy link
Copy Markdown
Contributor

@avivijay19 Is this abandoned?

@avivijay19
Copy link
Copy Markdown
Contributor Author

@adamsaghy work still going on

@adamsaghy adamsaghy marked this pull request as draft April 22, 2026 09:13
@adamsaghy
Copy link
Copy Markdown
Contributor

@avivijay19 Moved into draft. Let us know once it is ready to be reviewed.

@avivijay19 avivijay19 force-pushed the FINERACT-2293 branch 2 times, most recently from f350682 to b9c6178 Compare April 24, 2026 03:39
Delete dead code: AddressCommandFromApiJsonDeserializer, Address.fromJson(),
Address.fromJsonObject(). Rename FieldConfigurationReadPlatformService to
FieldConfigurationReadService, remove PlatformSecurityContext, add security
rule for fieldconfiguration endpoint.

Co-Authored-By: Claude Opus 4.6 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants