For developersBuilding Movies database app using React, NodeJS and Redis
END-OF-LIFE NOTICERedis is phasing out RedisGraph. This blog post explains the motivation behind this decision and the implications for existing Redis customers and community members.End of support is scheduled for January 31, 2025.Beginning with Redis Stack 7.2.x-y, Redis Stack will no longer include graph capabilities (RedisGraph).
IMDb(Internet Movie Database) is the world's most popular and authoritative source for information on movies, TV shows and celebrities. This application is an IMDB clone with basic account authentication and movie recommendation functionality. You will learn the power of RedisGraph and NodeJS to build a simple movie database.

#Tech Stack
- Frontend - React
- Backend - Node.js, Redis, RedisGraph
#Step 1. Install the pre-requisites
- Node - v13.14.0+
- NPM - v7.6.0+
#Step 2. Run Redis Stack Docker container
Ensure that Docker container is up and running:
#Step 3. Run RedisInsight Docker container
Ensure that Docker container is up and runnig
#Step 4. Clone the repository
#Step 5. Setting up environment variables
Copy
.env.sample to .env and add the following details:#Step 6. Install the dependencies
#Step 7. Run the backend server
#Step 8. Run the client
#Step 9. Accessing the Movie app
Open http://IP:3000 to access the movie app

#Step 10. Sign up for a new account

Enter the details to create a new account:

#Step 11. Sign-in to movie app

#Step 12. Rate the movie

#Step 13. View the list of rated movie

#Step 14. View directed movie over RedisInsight

#Step 15. Find movies where actor acted in.
Run the below query under RedisGraph to find the author acted in a movie

#Step 16. Store a user in a database

#Step 17. Find a user by username

#How it works?
The app consumes the data provided by the Express API and presents it through some views to the end user, including:
- Home page
- Sign-up and Login pages
- Movie detail page
- Actor and Director detail page
- User detail page
#Home page

The home page shows the genres and a brief listing of movies associated with them.
#How the data is stored
#Add a new genre:
#Add a movie:
#Set genre to a movie:
#How the data is accessed
#Get genres:
#Get moves by genre:
#Code example: Get movies with genre
#Sign-up and Login pages


To be able to rate movies a user needs to be logged in: for that a basic JWT-based authentication system is implemented, where user details are stored in the RedisGraph for persistence.
#How the data is stored
#Store user in the database:
#How the data is accessed
#Find by user name:
#Code Example: Find user
#Movie detail page

On this page a user can rate the film and view the Actors/directors who participated in the production of the film.
#How the data is stored
#Associate actor with a movie:
#Associate director with a movie:
#How the data is accessed
#Find movie by id with genre, actors and director:
#Code Example: Get movie detail
#Actor and Director detail page

#How the data is accessed
#Find movies where actor acted in:
#Find movies directed by:
#Get movies directed by
#User detail page

#Shows the profile info and movies which were rated by user
#How the data is stored
#Set rating for a movie:
#How the data is accessed
#Get movies and user ratings:
#Get rated movies for user
#Data types:
- The data is stored in various keys and various relationships.
- There are 5 types of data
- User
- Director
- Actor
- Genre
- Movie
#Each type has its own properties
- Actor:
id, bio, born , bornIn, imdbId, name, poster, tmdbId, url - Genre:
id, name - Director:
id, born, bornIn, imdbId, name, tmdbId, url - User:
id, username, password, api_key - Movie:
id, url, languages, countries, budget, duration, imdbId, imdbRating, indbVotes, movieId, plot, poster, poster_image, released, revenue, runtime, tagline, tmdbId, year
#And there are 4 types of relationship:
- User-
RATED->Movie - Director-
DIRECTED->Movie - Actor-
ACTED_IN_MOVIE->Movie - Movie-
IN_GENRE->Genre
