A log of progress for the week of September 15, 2025.
After focusing heavily on security and automation in previous weeks, it was time to turn our attention to the heart of the application: its data model. This week was defined by a major evolution of the database schema to perfectly align with the business logic of property and contract management.
The Great Database Refactor
This was the most significant architectural change to the project so far. The initial database schema was good, but it needed to be great. I undertook a massive database refactoring effort to create a robust and highly optimized data model. The key changes included:
- Schema Restructuring: Core tables were renamed and restructured to be more intuitive and specific, such as renaming contract to ejari_contracts.
- Performance Optimization: I introduced materialized views (e.g., properties_summary) to pre-calculate complex queries. This dramatically improves the performance of data-heavy API endpoints, ensuring the user experience is fast.
- Data Integrity & Syncing: Comprehensive indexes, foreign key relationships, and triggers were added. The triggers are particularly important, as they automatically keep user data in our database perfectly in sync with the user records in AWS Cognito.
Developer Tooling and UI Enhancements
While the database was the main event, several other important updates were shipped:
- Developer Tooling: I added new helper scripts and documentation to make it easier to work with a live database during development.
- UI Enhancements: The frontend received some polish with a new “Exo 2” font for better readability and UI elements to display key stats like Ejari contract counts.
This week, the application’s data layer matured significantly, setting a solid foundation for complex features. The improvements to developer tooling and the UI rounded out a week of deep architectural work.