A Spring Boot–based journaling backend demonstrating secure authentication, efficient caching, event-driven messaging, and automated mail scheduling — designed to showcase modern backend engineering practices.
Dear Journal 404 is a backend system that lets users maintain personal journals with secure access, fast caching, and automated weekly summaries. It integrates Spring Boot, MongoDB, Redis, Kafka, and custom cron jobs to simulate real-world backend workflows.
##🧩 Core Features
- Implemented using Spring Security 6 with HTTP Basic Authentication.
- Role-based access control for differentiating user privileges.
- Credentials securely stored with BCrypt password hashing.
- Journals stored in MongoDB using repository abstractions.
- Each journal is linked to its authenticated user.
- Supports complete CRUD REST API operations.
- The latest 7 journals per user cached in Redis.
- Improves read performance and reduces database load.
- Cache automatically invalidated on updates or deletions.
- Apache Kafka handles asynchronous email dispatch.
- When a summary needs to be sent, a Kafka producer emits an event.
- A Kafka consumer listens and triggers the email delivery service.
- Weekly mail summaries are triggered through custom cron jobs, not Spring Scheduler.
- Each cron job produces a Kafka event that initiates the mail-sending workflow.
- Users receive weekly summaries of their last seven journal entries.
- Email sending is asynchronous through Kafka consumers using JavaMailSender.