Match-Me is a full-stack recommendation platform that connects people based on their profile and bio data. Users register, complete their profile, browse matches, send connection requests, and chat in real time once connected.
- Backend: Spring Boot (Java 21), PostgreSQL, Flyway, JWT auth
- Frontend: React + TypeScript (Vite)
- Realtime: WebSocket (Socket.IO)
- Java 21+
- Maven
- Node.js 18+
- PostgreSQL 16+
Ensure PostgreSQL is running and you can connect to a database named matchme.
Database Setup:
# Connect to PostgreSQL as superuser
psql -U postgres
# Create database
CREATE DATABASE matchme;
\qSet Environment Variables: Before starting the backend, you need to set these environment variables:
export DB_USERNAME=your_postgres_username
export DB_PASSWORD=your_postgres_password
export JWT_SECRET=at_least_32_byte_long_secret_key_hereTo generate a secure JWT secret, you can use:
openssl rand -base64 64cd server
./mvnw spring-boot:runThe API will be available at http://localhost:8080.
WebSocket endpoint: http://localhost:8081
cd client
npm install
npm run devThe UI will be available at http://localhost:5173.
Register with email and password, then log in. JWT is stored in local storage for API access.
Before accessing recommendations, you must fill out:
- Profile: display name, about me, location
- Bio: hobbies, music preferences, food preferences, interests, looking for
You can also upload or remove a profile picture.
Recommendations are ranked by a matching algorithm. You can:
- Connect to send a request
- Dismiss to remove that user from future recommendations
- Pending: outgoing requests you can cancel
- Requests: incoming requests you can accept or dismiss
Connected users can chat with:
- Real-time message delivery
- Unread indicators
- Typing indicator
- Online/offline status
POST /auth/register- Register a new userPOST /auth/login- Authenticate user
GET /me- Get current user detailsGET /me/profile- Get current user's profilePUT /me/profile- Update current user's profilePOST /me/profile/picture- Upload profile pictureDELETE /me/profile/picture- Remove profile pictureGET /me/bio- Get current user's bioPUT /me/bio- Update current user's bio
GET /users/{id}- Get user summaryGET /users/{id}/profile- Get user's profileGET /users/{id}/bio- Get user's bio
GET /recommendations- Get user recommendationsPOST /recommendations/dismiss/{userId}- Dismiss a recommendation
GET /connections- Get user's connectionsPOST /connections/request- Send connection requestGET /connections/requests- Get incoming connection requestsGET /connections/requests/outgoing- Get outgoing connection requestsPOST /connections/accept- Accept connection requestPOST /connections/dismiss- Dismiss connection requestPOST /connections/cancel- Cancel outgoing connection request
POST /chats/with?otherUserId=ID- Get or create chat with userGET /chats- Get user's chat conversationsGET /chats/{chatId}/messages?page=0&size=20- Get chat messagesPOST /chats/{chatId}/messages- Send a messagePOST /chats/{chatId}/read- Mark messages as read
Seed scripts live in scripts/ and use PostgreSQL.
./scripts/reset_db.shcd server
mvn spring-boot:runWait for Started ServerApplication, then stop with Ctrl+C.
./scripts/seed.shAll seeded users share the password:
password123
Example accounts:
user1@example.com
user2@example.com
...
user100@example.com
There's a helper script to test real-time chat functionality:
./scripts/chat_test.shFollow the prompts to test WebSocket connectivity and message sending.
Both the frontend and backend support environment variables:
Frontend (.env file):
VITE_API_URL- API base URL (default: http://localhost:8080)VITE_SOCKET_URL- WebSocket URL (default: http://localhost:8081)
Backend (application.properties):
spring.datasource.url- Database connection URLspring.datasource.username- Database usernamespring.datasource.password- Database passwordjwt.secret- JWT signing secret
- Users: Core authentication entity with email/password
- Profiles: Extended profile information including location
- Bio: Personal interests and preferences for matching
- Connection Requests: Pending relationship requests
- Connections: Established relationships between users
- Chats: Conversation threads between connected users
- Messages: Individual chat messages
- Chat Reads: Message read status tracking
- JWT Authentication: Stateless authentication with token refresh
- RESTful API Design: Consistent resource-oriented endpoints
- Real-time Updates: WebSocket for instant messaging and presence
- Database Migrations: Version-controlled schema changes with Flyway
- Client-side Routing: SPA navigation with React Router
- Real-time chat (Socket.IO)
- Online/offline status indicator
- Typing indicator
- Profile gating before recommendations
- Distance-based matching preferences
- Form validation and error handling
- Responsive UI design
Issue: Connection refused when starting server Solution: Ensure PostgreSQL is running and database credentials are correct
Issue: "Profile incomplete" error when accessing recommendations Solution: Complete all required profile fields in the Profile Setup section
Issue: WebSocket connection failing Solution: Verify Socket.IO server is running on port 8081 and check CORS settings
I give my sincere thanks to my teammate Eike Langerbaur who helped us a lot in the development of this project. She is a really structured, nice and efficient teammate to work with. Without her, the project would have been much more difficult for me.