Welcome to the Course Review Platform, a comprehensive solution designed to empower students to share and discover reviews about courses they've attended. This platform is built using Svelte for the frontend, providing a modern and reactive user interface, and Spring Boot for the backend, ensuring a robust and scalable API.
The platform adopts a microservices architecture for scalability and maintainability:
git clone https://github.com/Tsounguinzo/concordia-courses.git
The repository includes a docker-compose.yml file that defines the MongoDB and Redis services. Use Docker Compose to start these services:
docker-compose up -d
Navigate to the backend directory. Before running the application, ensure it's configured to connect to the MongoDB and Redis instances started by Docker Compose. Then, run the Spring Boot application in the dev profile to initialize the database with any required seed data:
cd backend
./mvnw clean install
Comment out the following lines in the SecurityConfig.java
file to https enforcement:
//.requiresChannel(channel -> channel.anyRequest().requiresSecure())//enforce https
To generate new seeding data for the database, run the main method in the SeedRunner.java
file:
./mvnw exec:java -Dexec.mainClass="com.concordia.courses.backend.SeedData"
Install the necessary npm packages and start the Svelte development server:
cd ../ui
npm install
npm run build
Start the Backend Service
cd backend
./mvnw spring-boot:run -Dspring-boot.run.profiles=dev
Serve the Frontend
cd ../ui
npm run dev
The frontend application will be accessible at http://localhost:5173, and it will communicate with the backend API for operations.
When developing locally, use the dev profile for backend development to take advantage of any development-specific configurations, such as detailed logging and database seeding.
For frontend development, the Svelte development server provides hot reloading to immediately reflect changes in the browser.
concordia.courses is hosted across various cloud services to leverage the strengths of each and ensure optimal performance and reliability. Here's how each component is hosted:
The Svelte-based frontend is hosted on Vercel, which provides a seamless deployment process and excellent support for Svelte applications. Vercel offers automatic deployments from Git, enabling easy updates and rollbacks. Access the frontend at your Vercel project URL.
The MongoDB database is hosted on an M0 tier AWS cluster via MongoDB Atlas. This fully managed cloud database is configured for high availability and scalability. The M0 tier on AWS offers a free solution with sufficient resources for development and initial production use. Ensure your Spring Boot backend is configured with the connection string provided by MongoDB Atlas.
The spring boot backend application is hosted on Railway. This setup provides the flexibility needed for server-side operations and allows for custom configurations as required. The server runs the Spring Boot JAR file, with environment variables configured for database and Redis connections.
Session management and caching are powered by Redis, hosted on Redis Cloud via the Redis Enterprise Cloud Essentials plan. This setup offers a managed Redis instance with automatic scaling, backups, and end-to-end security. The Redis Cloud instance is configured as a cache and for storing blacklisted tokens, with connection details provided to the Spring Boot backend.
application.yml
file for production configurations, including MongoDB and Redis connection strings.Contributions are what make the open-source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.
Beaudelaire @ Beaudelaire@tutamail.com
mcgill.courses have led to the inspiration of concordia.courses with regard to its functionality and design.