learning-cloud-native-go / Myapp
Licence: mit
๐ฅ๏ธ How to build a Dockerized RESTful API application using Go.
Stars: โญ 171
Projects that are alternatives of or similar to Myapp
Go Zero
go-zero is a web and rpc framework written in Go. It's born to ensure the stability of the busy sites with resilient design. Builtin goctl greatly improves the development productivity.
Stars: โญ 13,156 (+7593.57%)
Mutual labels: microservice, restful-api, cloud-native
Spring Boot Microservices
This repo is part of a tutorial about writing microservices using Spring Boot
Stars: โญ 79 (-53.8%)
Mutual labels: microservice, tutorial
Jina Hub
An open-registry for hosting Jina executors via container images
Stars: โญ 71 (-58.48%)
Mutual labels: microservice, cloud-native
Devspace
DevSpace - The Fastest Developer Tool for Kubernetes โก Automate your deployment workflow with DevSpace and develop software directly inside Kubernetes.
Stars: โญ 2,559 (+1396.49%)
Mutual labels: microservice, cloud-native
Html Pdf Service
LGPL V3. Java Spring Boot microservice with RESTful webconsole and service endpoints that convert HTML to PDF, optionally styling with CSS and templating with JSON using Flying Saucer, PDF Box and Jackson libraries. Available on Docker Hub.
Stars: โญ 12 (-92.98%)
Mutual labels: microservice, restful-api
Kong
๐ฆ The Cloud-Native API Gateway
Stars: โญ 30,838 (+17933.92%)
Mutual labels: microservice, cloud-native
Staffjoy
ๅพฎๆๅก(Microservices)ๅไบๅ็ๆถๆๆๅญฆๆกไพ้กน็ฎ๏ผๅบไบSpring BootๅKubernetesๆๆฏๆ
Stars: โญ 1,391 (+713.45%)
Mutual labels: microservice, cloud-native
Django Rest Framework Tutorial
Django-REST-framework ๅบๆฌๆๅญธ - ๅพ็กๅฐๆ DRF-Beginners-Guide ๐
Stars: โญ 630 (+268.42%)
Mutual labels: restful-api, tutorial
Microservice Rs
Tutorial codebase for writing a microservice in Rust
Stars: โญ 114 (-33.33%)
Mutual labels: microservice, tutorial
Motan Openresty
A cross-language RPC framework for rapid development of high performance distributed services based on OpenResty.
Stars: โญ 117 (-31.58%)
Mutual labels: microservice, cloud-native
Dubbo Go Pixiu
Based on the proxy gateway service of dubbo-go, it solves the problem that the external protocol calls the internal Dubbo cluster. At present, it supports HTTP and gRPC[developing].
Stars: โญ 124 (-27.49%)
Mutual labels: microservice, cloud-native
Kratos
A modular-designed and easy-to-use microservices framework in Go.
Stars: โญ 15,844 (+9165.5%)
Mutual labels: microservice, cloud-native
Quarkus Microservices Poc
Very simplified shop sales system made in a microservices architecture using quarkus
Stars: โญ 16 (-90.64%)
Mutual labels: microservice, cloud-native
Awesome Cloud Native Tutorials
A curated list of tutorials and labs for learning cloud native concepts
Stars: โญ 70 (-59.06%)
Mutual labels: cloud-native, tutorial
Hemera
๐ฌ Writing reliable & fault-tolerant microservices in Node.js https://hemerajs.github.io/hemera/
Stars: โญ 773 (+352.05%)
Mutual labels: microservice, cloud-native
Grpcjsontranscoder
A filter which allows a RESTful JSON API client to send requests to .NET web server over HTTP and get proxied to a gRPC service
Stars: โญ 97 (-43.27%)
Mutual labels: restful-api, cloud-native
Kubernetes Handbook
Kubernetes Handbook ๏ผKubernetesๆๅ๏ผ https://kubernetes.feisky.xyz
Stars: โญ 4,511 (+2538.01%)
Mutual labels: microservice, cloud-native
Awesome Fenix
่ฎจ่ฎบๅฆไฝๆ็ญไธๅฅๅฏ้ ็ๅๅธๅผๅคงๅ่ฝฏไปถ็ณป็ป
Stars: โญ 530 (+209.94%)
Mutual labels: microservice, cloud-native
Sentinel Golang
Sentinel Go version (Reliability & Resilience)
Stars: โญ 1,817 (+962.57%)
Mutual labels: microservice, cloud-native
Appkernel
API development made easy: a smart Python 3 API framework
Stars: โญ 152 (-11.11%)
Mutual labels: microservice, restful-api
Learning Cloud Native Go - myapp
Cloud Native Application Development is a one way of speeding up building web applications, using micro-services, containers and orchestration tools.
As the first step, this repository shows How to build a Dockerized RESTful API application using Go.
๐ก Refer learning-cloud-native-go.github.io or commit messages and
step-
branches for a step by step guild.
Points to Highlight
- Usage of Docker and Docker Compose.
- Usage of Golang and MySQL Alpine images.
- Usage of Docker Multistage builds.
- Liveness and Readiness APIs for K8s.
- Usage of Goose for Migrations.
- Usage of GORM as the ORM.
- Usage of Chi as the Router.
- Usage of Zerolog as the Logger.
- Usage of Validator.v10 as the Form Validator.
๐ญ Hope to use Wire for Compile-time Dependency Injection in the future.
Endpoints
Docker Image Sizes
- DB: 217MB
- App
- Development environment: 650MB
- Production environment: 20.9MB
๐ก Building Docker image for production
docker build -f docker/app/prod.Dockerfile . -t myapp_app
Design Decisions & Project Folder Structure
- Store Docker related files inside the
docker
folder. But keep thedocker-compose.yml
file in the project root. - Store executable packages inside the
cmd
folder. - Store database migrations inside the
migrations
folder. - Store main application code inside the
app
folder. - Store reusable packages like configs, utils, models and repositories in separate folders. This will be helpful if you are adding more executable applications to support web front-ends, publish/subscribe systems, document stores and etc.
.
โโโ docker
โ โโโ app
โ โโโ bin
โ โ โโโ init.sh
โ โ โโโ wait-for-mysql.sh
โ โโโ Dockerfile
โโโ docker-compose.yml
โ
โโโ cmd
โ โโโ app
โ โ โโโ main.go
โ โโโ migrate
โ โโโ main.go
โ
โโโ migrations
โ โโโ 20190805170000_create_books_table.sql
โ
โโโ app
โ โโโ app
โ โ โโโ app.go
โ โ โโโ book_handler.go
โ โ โโโ health_handler.go
โ โ โโโ index_handler.go
โ โโโ requestlog
โ โ โโโ handler.go
โ โ โโโ log_entry.go
โ โโโ router
โ โโโ middleware
โ โ โโโ content_type_json.go
โ โ โโโ content_type_json_test.go
โ โโโ router.go
โ
โโโ config
โ โโโ config.go
โ
โโโ adapter
โ โโโ db
โ โ โโโ db.go
โ โโโ gorm
โ โโโ gorm.go
โ
โโโ util
โ โโโ logger
โ โ โโโ logger.go
โ โ โโโ logger_test.go
โ โโโ validator
โ โโโ validator.go
โ โโโ validator_test.go
โ
โโโ model
โ โโโ book.go
โโโ repository
โ โโโ book.go
โ
โโโ go.mod
โโโ go.sum
๐ก About
app/app/app.go
; Some preferapp/server/server.go
orhttp/app/app.go
Form Validation
Logs
Note that the project description data, including the texts, logos, images, and/or trademarks,
for each open source project belongs to its rightful owner.
If you wish to add or remove any projects, please contact us at [email protected].