Server-Side development with NodeJS, Express, and MongoDB (SDN302)
Vietnamese title: Phát triển Server-Side với NodeJS, Express và MongoDB
Credits: 3
Prerequisites: DBI202, FER202

Description:
This course tackles all the problems related to NodeJS-based web servers. Contents to be implemented include:
- Overview of Web protocols: HTTP and HTTPS.
- Introduction of NodeJS and frameworks such as ExpressJS, NestJS, Hono to build a web server.
- Introduction of simple templating languages such as EJB and HandleBar .
- Deploy the application on a web server with basic CRUD operations. Work with NoSQL databases, specifically MongoDB and Mongoose, to access MongoDB from NodeJS.
- Overview of REST and building a RESTful API.
- Learn Authentication and security-related issues for web applications.
- Integrate React app with server NodeJs
- Deploy server-based applications with Hosting Services

Learning outcomes:
Understand Node, Node modules, API and the Node HTTP server
Understand Express, NestJS and Hono framework, operating principles, and methods of building a web server that supports REST API
Be able to use the Express Generator tool to generate Express applications
Understand MongoDB basics, develop Node applications that work with data through MongoDB and Mongoose ODM
Be able to implement REST APIs with Express, MongoDB, Mongoose and Mongoose Population
Be able to implement user authentication mechanisms for applications
Be able to use Backend as a Service (BaaS) to enhance secure communication between client and server applications
Be able to use EJB and HandleBar

Student tasks:
- Students must attend at least 80% of contact slots in order to be accepted to the final examination.
- Student is responsible to do all exercises given by instructor in class or at home and submit on time
- Constantly follow announcements on FU CMS at https://cmshn.fpt.edu.vn/ and FU FLM at https://flm.fpt.edu.vn/ for up-to-date course information regarding assignment submission and feedback on assignments and project work.

Tools:
- Visual Studio Code (https://code.visualstudio.com)
- Postman
- MongoDBCompass
- Internet

Materials:
description: Full Stack Web Development Guide: Everything Node JS, Express, APIs, Embedded JavaScript (EJS), React JS, Database Fundamentals, SQL Databases, NoSQL …
author: Sammie Smith
publisher: Independently published
published_date: 2022
isbn: 979-8848179330
description: Ultimate Full-Stack Web Development with MERN_ Design, Build, Test and Deploy Production-Grade Web Applications with MongoDB, Express, React and NodeJS
author: Nabendu Biswas
publisher: Orange Education Pvt Ltd
published_date: 2023
isbn: 978-8119416424
description: https://www.mongodb.com/
description: https://ejs.co/
description: https://expressjs.com/
description: https://nodejs.org/docs/latest/api/
description: https://handlebarsjs.com/
description: NestJS - A progressive Node.js framework
description: Hono - Ultrafast web framework for the Edges

Assessments:
category: Assignment
type: on-going
weight: 20.0
duration: Guided and reviewed in tutorial sesions;
Cont. at home
question_type: All CLOs
no_question: a problem similar to
real one
grading_guide: problem(s) to solve by programming using LO1 - LO8
note: Individual or team work, guided by instructor, submission by a given deadline
category: Practical Exam
type: on-going
weight: 25.0
duration: 85'
question_type: All CLOs
no_question: Preferable to be marked by scripts
grading_guide: problem(s) to solve by programming using LO1 - LO8
note: supervised by proctor(s) sent by exam board
category: Progress test
type: on-going
weight: 15.0
duration: 20'-40'
question_type: PT1: CLO1,2,3,4,5,8
PT2: CLO6
PT3: CLO7
no_question: essay or multiple choice
knowledge_and_skill: 15-30
if multiple choice
grading_guide: PT 1
LO1,2,3,4,5,8
PT 2
LO6
PT 3
LO6, 8
Number of questions:
3-8 for each LOx
note: supervised by instructor
category: Project
type: on-going
weight: 15.0
duration: Guided and reviewed in tutorial sesions;
Cont. at home
question_type: All CLOs
no_question: a problem similar to
real one
grading_guide: problem(s) to solve by programming using LO1 - LO8
note: Individual or team work, guided by instructor, submission by a given deadline
category: Final exam
type: Final exam
weight: 25.0
duration: 60'
question_type: All CLOs
no_question: multiple choice
knowledge_and_skill: 50
grading_guide: all topics;
more than 70% new questions (for the current semester);
note: supervised by proctor(s) sent by exam board

Schedule:
session: Course Introduction:
1.1 Full Stack Web Development: The Big Picture
1.2 NodeJS Introduction
learning_outcomes: I
materials: SDN302_Slides_1
session: 2.1 Features of node.js
- Single Threaded but Highly Scalable
- Event-driven and Asynchronous
- Event Loop
learning_outcomes: I
T
U
materials: SDN302_Slides_2
session: 3.1 Node.js - Environment setup
- Setting up node.js and npm
- Basics of node.js and npm
3.2 Node.js - First application
learning_outcomes: I
T
U
materials: SDN302_Slides_3
session: API:
4.1 What is API
4.2 How do APIs work?
4.3 What does an api do?
learning_outcomes: I
T
session: HTTP:
5.1 HTTP Overview
5.2 Receiving an HTTP Request with Express
learning_outcomes: U
session: NodeJS and HTTP:
6.1 Node.JS HTTP Module
6.2 Node.JS as a web server
learning_outcomes: I
T
U
session: EXPRESSJS:
7.1 Express Introduction
7.2 Using Express js to create your first program
learning_outcomes: I
T
U
session: NODE and EXPRESS:
8.1 Restful routing with express
8.2 Understand and use middleware for node applications
8.3 Types of middleware in node.js
8.4 Writing express middleware
8.5 Express- Generator
- Express Generator Introduction
- Using Express - Generator To Create Your First Program
learning_outcomes: T
U
session: Nosql Databases With Mongodb:
9.1 Nosql Introduction
9.2 Document Databases (Mongodb)
9.3 Create-Read-Update-Destroy (Crud)
learning_outcomes: T
U
session: 10.1 Nosql Best Practices
10.2 Mongodb Mongo Shell Features
10.3 NodeJs and MongoDB
learning_outcomes: T
U
session: Mongoose:
11 What is Mongoose
learning_outcomes: I
T
U
session: Mongoose Population
12 Use Mongoose population to cross-reference users within a comment
learning_outcomes: T
U
session: 13 Populate the comments with the users’ information upon querying
learning_outcomes: T
U
session: 14 Match with mongodb regex
learning_outcomes: T
U
session: REST API with Express, MongoDB and Mongoose:
15 Develop a full-fledged REST API server with Express, MongoDB and Mongoose
learning_outcomes: I
T
U
session: 16 Implement the end-to-end solution integrating Express, Node and MongoDB
learning_outcomes: T
U
session: 17 Model - View - Controller
learning_outcomes: T
U
session: ASSIGNMENT 1
learning_outcomes: U
session: Embedded Javascript (EJS):
19 What is EJS?
learning_outcomes: T
U
session: 20 Understand what EJS does and how to use it with node and express
learning_outcomes: I
T
U
session: 21 Templating with EJS
learning_outcomes: T
U
session: HandleBars:
22.1 What Is Handlebars?
22.2 Understand What Handlebars Does And How To Use It With Node And Express
23.3 Templating With Handlebars
learning_outcomes: U
session: Progress Test - 1
session: ASSIGNMENT 2
learning_outcomes: U
session: Authentication And Security:
25 Authentication And Keeping User Details Secure
- Password authentication
- Multi-factor authentication
- Biometric authentication
learning_outcomes: T
U
session: 26.1 Encryption And Useencryption To Keep Your Database Secure
- Database Encryption
26.2 Hashing Passwords With Bcrypt
learning_outcomes: T
U
session: 27 Sessions And Cookies
learning_outcomes: T
U
session: Authentication And Security (Cont'd)
28 User Authentication With Passport
- Use Passport Module Together With Passport-Local
learning_outcomes: T
U
session: 29.1 use passport-local-mongoose for setting up local authentication within server 29.2 use passport together with sessions to set up user authentication
learning_outcomes: I
T
U
session: 30 Token Based Authentication
learning_outcomes: I
T
U
session: HTTPS and Secure Communication:
31 Configure a secure server in Node using the core HTTPS module
learning_outcomes: I
T
U
session: 32.1 Generate the private key and public certificate and configure the HTTPS server
32.2 Redirect traffic from the insecure HTTP server to a secure HTTPS server
learning_outcomes: T
U
session: Uploading Files:
33 Configure the Multer module to enable file uploading
learning_outcomes: T
U
session: 34 Setup Express server to use Multer to upload files to a designated folder
learning_outcomes: T
U
session: Download Files:
35 Configure the module to enable file downloading
learning_outcomes: T
U
session: 36 Setup Express server to use Multer to download files to a designated folder
learning_outcomes: T
U
session: Cross-Origin Resource Sharing:
37 Use the CORS NPM module to enable CORS support
learning_outcomes: I
T
session: 38 Enable Express application to support CORS requests by configuring the CORS module
learning_outcomes: T
session: OAuth and User Authentication:
39 Use an OAuth providers for authenticating users within server
learning_outcomes: T
U
session: 40 Setup server using Passport OAuth modules
learning_outcomes: I
T
session: Progress Test - 2
session: ASSIGNMENT 3
learning_outcomes: U
session: Backend as a Service (BaaS):
43 Introduction
learning_outcomes: I
T
session: 44 Hosting static websites with GitHub Pages
learning_outcomes: I
T
session: 45 Understand and use to quickly build backend support for applications
learning_outcomes: T
session: Deployment:
46 Web hosting
learning_outcomes: I
T
U
session: 47 Website Deployment
learning_outcomes: T
U
session: 48 Deploying Server-Based Applications with Heroku
learning_outcomes: I
T
session: Frameworks: NestJS:
49 Introduction
learning_outcomes: T
I
U
session: 50 Installing
learning_outcomes: I
T
session: 51 Using Nestjs To Create Your First Program
learning_outcomes: T
U
session: 52 Overview Techniques
learning_outcomes: I
T
session: 53 Overview Techniques
learning_outcomes: T
U
session: 54 Overview Security
learning_outcomes: T
U
session: Framework Hono:
55 Introduction and Installing
learning_outcomes: I
T
session: 56 Using Hono To Create Your First Program
learning_outcomes: U
session: ASSIGNMENT 4
session: Project Presentation
session: Project Presentation
session: Progress Test - 3