Skip to content
This repository has been archived by the owner on Mar 20, 2023. It is now read-only.

jorgechato/2020.api.jorgechato.com

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

71 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Personal web page API (Work in progress)

Build Status Go Report Card Godoc whereisjorge.today

Must have

Description

I've been researching the proper way to structure code for the last 4 years. Currently I'm into a clean code architecture, more specific testing the Hexagonal Architecture.

I run into this 101 article which describe perfectly the DDD, clean code and hexagonal architecture.

Structure

Following the basic go structure, cmd hosted the entry points for each port. In the pkg folder you can find the source code of the project, where the magic happen.

The different components are split into packages following the Who + What principle. In the next example we only have one who (location) and 4 what (application, domain, infrastructure, repository) as described in the hexagonal architecture.

.
├── build # core build misc (dockerfile, k8s.yml...)
├── cmd # entry point
│   ├── http
│   └── lambda
├── pkg # source code
│   └── location # who
│       ├── application # use cases
│       │   └── json
│       ├── domain # business logic
│       ├── infrastructure # ports
│       │   ├── api
│       │   ├── lambda
│       │   └── polarsteps
│       └── repository # adapters
└── scripts # build scripts (.sh...)

About

My personal web page. You can visit the following url to see it. [API]

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published