How kashisood/ccy-calc works
Project type and purpose
• This is a standalone backend microservice (“Ccy-calc”) built with Spring Boot and Maven.
• Its responsibility is to receive currency‐conversion requests, look up exchange rates (in an H2 database and/or in-memory cache), apply any business logic, and return a conversion result.
File structure
• Top-level artifacts:
• pom.xml / mvnw → Maven build & wrapper
• logs/ → runtime Log4j2 logs
• src/main/java/com/anz/curr/exchange/springcore:
• App.java / SpringBootMavenStarterApplication.java → Spring Boot entry points
• request/ → request‐DTOs (CurrencyRequest)
• processor/ → core business logic (CurrencyProcessor)
• dao/ → data access (CurrencyMappingDAO, ExchangeRateDao)
• entity/ → JPA or in-memory entities (CurrencyEntity, RateMap, CurrencyMatrix)
• cache/ → in-memory rate cache (CurrencyExchangeMappingCache, ExchangeRate)
• Response/ → response‐DTOs (ResponseObject)
• src/main/resources:
• application.properties → Spring Boot config
• data.sql / data-h2.sql → initial H2 data load scripts
• log4j2.xml → logging configuration
• Tests mirror the same packages under src/test/java.
README
• README only contains the project name (“Ccy-calc”), confirming there is no separate frontend or external services—this is a pure backend service.
Detailed capturing of essential elements
• Don’t omit the cache layer — it’s central to performance.
• Initial SQL data load (data.sql → H2) as part of application startup.
• Retry or error flows if relevant (e.g., DB unavailable → error response).
Summary