Cosmic Module
O
Qubits of DPK
March 20, 2026
Core Open Source
These are the foundation modules — every other module depends on them. Think of them as the concrete, steel, and wiring of the building. You never see them, but nothing stands without them.
1. fineract-core
Layman Analogy
This is the hospital's plumbing and electricity. Every department uses electricity. Nobody installs their own generator. fineract-core provides the shared infrastructure every module needs.
What's Inside
a) The Money Class — The Most Important Utility
In banking, you NEVER use Java's double or float for money. Why?
java
QUBITS OF DPK
Fineract uses BigDecimal wrapped in a Money class:
java
QUBITS OF DPK
b) Exception Hierarchy
All Fineract exceptions extend from AbstractPlatformException:
javascript
QUBITS OF DPK
Example: trying to get a loan that doesn't exist:
java
QUBITS OF DPK
c) CommandProcessingResult — Standard Write Response
Every write operation (create, update, delete) returns this:
java
QUBITS OF DPK
d) DateUtils — Date Handling
Banking deals with dates constantly. DateUtils handles:
- Getting tenant's local date (not server's date)
- Parsing dates from API requests
- Comparing dates with business logic
java
QUBITS OF DPK
e) Multi-Tenancy Infrastructure
ThreadLocalContextUtil stores which tenant is active for the current HTTP request:
java
QUBITS OF DPK
Key Packages:
javascript
QUBITS OF DPK
2. fineract-provider
Layman Analogy
This is the hospital's main building and reception desk. It's where you enter. It connects all departments. It's the address everyone uses.
What's Inside
a) The Entry Point — FineractApplication.java
java
QUBITS OF DPK
javascript
QUBITS OF DPK
c) Client Management — Lives in Provider
The Client domain (portfolio/client) lives in fineract-provider (not a separate module yet):
javascript
QUBITS OF DPK
d) Infrastructure — The Technical Backbone
javascript
QUBITS OF DPK
e) Instance Mode — Read/Write/Batch
This is what your PR #5658 tests:
java
QUBITS OF DPK
3. fineract-command
Layman Analogy
The ticket routing system in the hospital. When a patient comes in, a ticket is created (Command). The ticket is routed to the right department (CommandRouter). The department processes it (CommandHandler).
What's Inside
The Command Pipeline:
javascript
QUBITS OF DPK
CommandHandler Interface:
java
QUBITS OF DPK
CommandAuditor — Audit Trail:
Every command is recorded in m_portfolio_command_source table:
sql
QUBITS OF DPK
This creates a complete audit trail of every change in the system. Regulators can see who did what and when.
DisruptorCommandExecutor — High Performance:
For high throughput scenarios, Fineract uses the LMAX Disruptor (a ring buffer pattern) to process commands asynchronously without locks — much faster than traditional queues.
4. fineract-security
Layman Analogy
The security guard + ID card system of the hospital. Who can enter (authentication). What floors they can access (authorisation). Separate security for each company in the building (multi-tenant).
What's Inside
a) JWT Support — FineractJwtAuthenticationTokenConverter
java
QUBITS OF DPK
b) Two-Factor Authentication API
javascript
QUBITS OF DPK
c) User Details API
javascript
QUBITS OF DPK
d) Authentication API
javascript
QUBITS OF DPK
5. fineract-validation
Layman Analogy
The form checker at the hospital entrance. Before your form goes to any department, someone checks: Is the date filled in correctly? Is the ID number format right? Is the required field empty?
What's Inside
Custom validation annotations for Fineract-specific types:
java
QUBITS OF DPK
Used in request DTOs:
java
QUBITS OF DPK
6. fineract-db
Layman Analogy
The filing room infrastructure — the shelves, cabinets, and labelling system. It doesn't store the files (that's the tenant schemas) but defines HOW things are stored.
What's Inside
- Liquibase changelog files that define the schema
- Base database configuration (connection pools, transaction managers)
- Multi-tenant datasource routing logic
- Database migration utilities
javascript
QUBITS OF DPK
Why Liquibase?
Without Liquibase, if a developer adds a new column to m_loan, they'd have to manually run SQL on every database. Liquibase:
- #Tracks which scripts have run (in DATABASECHANGELOG table)
- #On startup, runs only the NEW scripts
- #Runs them on EVERY tenant's schema automatically