/elastic-test

Just a basic app testing Elasticsearch with Node.js.

Primary LanguageTypeScript

Elastic Search & Node.js API

This is a simple API that uses elastic search to store and retrieve logs.

Running instructions

  1. Clone the repository

  2. Run the elastic search server

docker compose -f ./dev/docker-compose.yml up -d elasticsearch
  1. Run the following command to install the required packages
cd src
pnpm install
pnpm build
pnpm start
  1. Run the script to create the index and add the data
cd src
pnpm run add-logs
  1. Open the browser and navigate to http://localhost:8080/ to view the swagger documentation

Screenshots

alt text alt text alt text

Technologies used

  1. Node.js
  2. Elastic Search
  3. TypeScript
  4. Fastify
  5. Pino