Skip to content

A full-stack e-commerce application built and deployed on AWS EC2, enabling users to browse, sort, and search for movies.

Notifications You must be signed in to change notification settings

jacheng1/fabflix

Repository files navigation

2024-fall-cs-122b-team-101

About the Project

K8s Cluster Throughput (minute)
Case 1: 1 Control Plane + 3 Worker nodes + 1 master MySQL pod + 1 slave MySQL pod + 2 Fabflix pods 15230.19
Case 2: 1 Control Plane + 4 Worker nodes + 1 master MySQL pod + 1 slave MySQL pod + 3 Fabflix pods 14562.488

Demonstration

Project 1 Video Link
Project 2 Video Link
Project 3 Video Link
Project 4 Video Link
Project 5 Video Link

Member Contributions

Project 1:

● Jacky: repository setup, Movie List Page, Single Movie Page, Single Star Page
● Kristen: AWS instance setup, web application deployment on AWS instance, Single Star Page, video demonstration

Project 2:

● Jacky: Login Page, Main Page, extend Movie List Page, extend Single Movie/Star Page, update jump functionality, Shopping Cart Page UI, Payment Page, Confirmation Page UI
● Kristen: Shopping Cart Page functionality, Add-to-Cart feature on Movie List/Single Movie Page, Confirmation Page functionality, video demonstration

Project 3:

● Jacky: reCAPTCHA, PreparedStatement, add customers/employees encrypted password verification, Metadata Page, Add Star/Movie Page, add_movie stored procedure, domain registration
● Kristen: Add HTTPS, moviedb customers/employees password encryption, SAX XML parser, video demonstration

Project 4:

● Jacky: full-text search, autocomplete, JDBC connection pooling
● Kristen: full-text search bug fix, MySQL Master-Slave Replication, scaling with cluster of MySQL/Tomcat, load balancer, video demonstration

Project 5:

● Jacky: Running on Docker container, set up Kubernetes (K8s) cluster on AWS, deploy Fabflix to K8s cluster on AWS, JMeter testing
● Kristen: Running on Docker container, set up Kubernetes (K8s) cluster on AWS, video demonstration

Substring Matching

Substring matching is used in conjunction with the LIKE SQL predicate in MovieListServlet.java to
fetch records from moviedb with m.title, m.director, and s.name that have the retrieved parameters
title, director, and name at any position, respectively. Next, these query excerpts are appended to
the StringBuilder object, queryBuilder, which contains an incomplete SQL query.

PreparedStatement Usage

The following .java files contain a PreparedStatement:

● ConfirmationServlet
● DashboardLoginServlet
● LoginServlet
● MainServlet
● MovieListServlet
● PaymentServlet
● ShoppingCartServlet
● SingleMovieServlet
● SingleStarServlet
● LoadFromFile
● UpdateDatabase

Performance Tuning

To maximize the efficiency of our SAX XML parser, we integrated the following:

  1. Writing parsed movie attributes into .txt files during parsing, which contain stars, stars_in_movies, movies, genres, and genres_into_movies. The .txt files are efficiently loaded into temporary SQL tables.
  2. Temporary tables to store parsed data from .txt files, which are then inserted into moviedb tables. Next, the temporary tables are dropped to eliminate residual data and possible duplicate insertions.

We found that these techniques vastly decreased the runtime of our SAX XML parser, as well as the time it took to load the .txt file data into our moviedb database.

Built With

  • Java
  • JavaScript
  • HTML
  • CSS

About

A full-stack e-commerce application built and deployed on AWS EC2, enabling users to browse, sort, and search for movies.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published