Codeinwp / logo-maker

Another Logo Maker app made for fun and profit.
https://themeisle.com/logo-maker/
MIT License
73 stars 23 forks source link

[ Experimental ] Backend #37

Open Soare-Robert-Daniel opened 3 years ago

Soare-Robert-Daniel commented 3 years ago

Introduction

One of the Logo Maker's ideas is to have a backend for saving the configuration made by users. At this stage, I do not know if Logo Maker deserves a serious backend. Still, we can use the opportunity to test some technologies for educational purposes or do some training - or as an interview exercise.

Eventually, if one of the prototypes is a success, we can use it as a backend. With the logos stored, we can run some analytics to see the most popular options and create suggestions based on them.

Overview

diagrama_api_logo_maker

There are 2 main functionalities:

For the first one, the scheme is straightforward: you send the JSON configuration to the server, and the server gives back a link from where you can access the configuration later on.

For the second, the fork also has a parent from which it was derived. The parent's id is used to access the original configuration. The structure is like a linked list. The repeated action to get the parent sends you to the original configuration. But in the grand overview, the struct is like a tree. A configuration can have many forks, but only the parents and not other children are the forks you can get. When you create a fork, you can do the same as in the first function; besides, you need to add a field as a reference to the parent, or you can save only what changes, and when the content is retrieved, you can merge the configuration with the parent. The structure of the access link will be the same like in Read & Save, but with additional information in the response that the configuration is a fork.

Example.

{
    "configuration": { /* data */ },
    "fork": {
           "parentId": "213"
     }
}

Server

We can toy with those technologies in Virtual Machine / Container:

Or we can test some serverless services:

Databases

It is the same case as in the Server; we can test:

For the cloud part:

@ineagu, @selul, @HardeepAsrani what do you think?

ineagu commented 3 years ago

I think is a good idea that we now have documented for potential research projects or interviews/internship 👍