GithubHelp home page GithubHelp logo

weaver's Introduction

Software Developer Task

Description

System is design using Microservices architecture.
It utilises Celery Distributed Task Queue with Redis as a Message Broker as well as the Result Backend and MongoDB as database.

Requirements

  • Python 3.11.8
  • Packages: flask, gunicorn, celery, pymongo, python-dotenv, pytest, pytest-flask, mongomock, pytest-mock
  • Docker Images: mongo, mongo-express, redis

Installation

  • Install Python if you haven't already. You can download Python from the official website at: https://www.python.org/downloads/.
  • Clone the project into a directory of you choice.

$ git clone PROJECT_URL <your project directory>

  • Go into the project directory:

$ cd <your project directory>

  • Upgrade pip.

$ pip install --upgrade pip

  • Install pipenv.

$ pip install pipenv

  • Create virtual environment and install dependencies.

$ pipenv install --dev

Running tests

Run tests to check that everything is complete.

$ pipenv run pytest tests

Running containerised version of the system

$ docker compose up -d

You may need to wait a few seconds for the system to become ready.

Usage

You can check content of db by visiting http://localhost:8081/

You can check if server is alive by visiting http://localhost:8080/ping

You can get information about employee by visiting http://localhost:8080/employees/198

Testing Strategies

Basic unit and integration tests has been included in the project.
What is missing is automated End To End test which could be implemented using pytest, pytest-docker and Docker Compose configuration I provided.
Unfortunately pytest-docker plugin does not work on my MacBook ATM, the most likely due to depreciation of Python version of Docker Compose in a favor of the one written in Golang.
Another type of test which could be useful would be performance test of the system carried on Kubernetes cluster.

weaver's People

Contributors

jentyk avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.