My First Java Web Project: From Planning to Deployment – A Full‑Stack Journey
This article recounts the author’s experience building a simple Java web application for a university anniversary, covering planning, environment setup, documentation, database design, coding challenges with Spring Boot, Redis, and session handling, deployment on Alibaba Cloud, and the lessons learned about architecture, logging, and monitoring.
Project Overview : The author completed a Java web project named “最美80周年,共同记录” (Beautiful 80th Anniversary) as a personal learning exercise, with documentation hosted on Showdoc and source code on GitHub.
Preparation Stage :
Server: Alibaba Cloud ECS (2‑core, 4 GB RAM).
Environment: Installed JDK 1.8, MySQL, Redis on CentOS 6.9.
Documentation: Managed with Showdoc and process diagrams via ProcessOn.
Code Management: GitHub repository.
Development Tools: IntelliJ IDEA.
Framework: Spring Boot, packaged as a runnable JAR.
Development Phase :
Emphasized writing comprehensive design documents before coding, though the author later admitted the documentation was incomplete.
Database design suffered from missing type and index specifications, leading to later schema changes.
Implemented Redis list structures for chat messages and faced indexing difficulties.
Session data handling became chaotic, causing bugs and maintenance headaches.
Data synchronization between MySQL, Redis, and session was handled manually, with no automated consistency checks.
Used long‑polling AJAX for real‑time message updates.
Front‑end UI was a borrowed WeChat‑style template due to limited design skills.
Pre‑Launch Challenges :
Alibaba Cloud security group required explicit port opening; default denial caused connectivity failures.
Domain registration in China required ICP备案, a process taking up to 25 days.
WeChat only redirects to domains using the standard HTTP port 80, necessitating port changes.
Post‑Launch Reality :
No logging, monitoring, or management system was in place; only a simple admin page for manual DB and Redis sync.
The author realized the critical importance of observability tools even for small projects.
Key Takeaways :
Thorough architectural design and documentation dramatically reduce later bugs.
Investing in logging, monitoring, and proper deployment configurations saves time and prevents frustration.
Understanding cloud security settings and domain registration processes is essential for successful launches.
Continuous learning and referencing best‑practice designs improve code quality and project maintainability.
Images and promotional sections from the original article have been omitted for brevity.
Top Architect
Top Architect focuses on sharing practical architecture knowledge, covering enterprise, system, website, large‑scale distributed, and high‑availability architectures, plus architecture adjustments using internet technologies. We welcome idea‑driven, sharing‑oriented architects to exchange and learn together.
How this landed with the community
Was this worth your time?
0 Comments
Thoughtful readers leave field notes, pushback, and hard-won operational detail here.