Node.js app use redis and search in PostgreSQL DB
- for Node.js go to the Node.js site and install
- install redis using
brew install redis
on MacOS or usenpm install redis
- start server
brew services start redis
or run manually usingredis-server /usr/local/etc/redis.conf
I use
/usr/local/bin/redis-server
for run server and connects to localhost on port 6379
- Clone this app using
git clone
or download zip - Change to the project directory and run
node app.js
- If everythink is ok the terminal will display
Server listening on port: 3000
redis-server and app.js are working
- Go to https://www.postman.com/ for test app
work only
GET
requests
- Use endpoint
/film/:title
where :title - name of the film - For example run
localhost:3000/film/Fargo_Gandhi
- It is from database
- From cache