Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/riita10069/roche
Roche is a Code Generator and Web Framework, makes web development super concise with Go, CleanArch
https://github.com/riita10069/roche
clearn-arch code-generator golang microservice-architecture roche
Last synced: about 1 month ago
JSON representation
Roche is a Code Generator and Web Framework, makes web development super concise with Go, CleanArch
- Host: GitHub
- URL: https://github.com/riita10069/roche
- Owner: riita10069
- License: mit
- Created: 2021-04-19T12:30:13.000Z (over 3 years ago)
- Default Branch: master
- Last Pushed: 2022-04-15T09:19:04.000Z (over 2 years ago)
- Last Synced: 2024-06-20T11:49:00.017Z (5 months ago)
- Topics: clearn-arch, code-generator, golang, microservice-architecture, roche
- Language: Go
- Homepage:
- Size: 274 KB
- Stars: 14
- Watchers: 3
- Forks: 0
- Open Issues: 7
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
Awesome Lists containing this project
README
# ![roche](./roche_2nd.png)
It is still under development, so please do not use it. We plan to release v.1.0.0 in the summer.
roche is a web framework optimized for microservice architecture using go.
It prioritizes schema-first and quick development over lightweight.
It is currently in the development concept stage and should not be used in production.It is inspired by Ruby on Rails, [https://github.com/izumin5210/grapi][grapi] and protoeasy.
And roche relies on [https://github.com/izumin5210/grapi][grapi] heavily.## Roche is named after the Roche limit and Roche radius.
The Roche limit is the critical satellite orbital radius at which the satellite will break apart due to tidal destruction if the satellite is approximated to be a self-gravitating fluid, ignoring its material strength.
The Roche radius is the size of the region where the mutual gravity of two celestial bodies orbiting around the central body exceeds the gravity of the central body.In a microservices architecture, each service pulls together as if it has universal gravitation. However, if they are too close together (i.e., too dense), they will break, hence the name.
## Getting Started
### protobuf
You have to install [https://github.com/protocolbuffers/protobuf][protobuf]### Framework
`go get github.com/riita10069/roche`
### CLI tool
`go install github.com/riita10069/roche/cmd/roche@latest`
## Getting Started
Requires go version 1.16 or higher`roche init .`
To Initialize project like create-react-app`roche toml`
Generate roche.toml which is needed roche command.`roche g scaffold-service NAME`
Generate .proto and server`roche scaffold all NAME`
Generate CRUD template for NAME service
You can also generate a single file.
By using (domain, model, repo, migrate) instead of all.`roche manifest app APPNAME`
Generate k8s manifest template, APPNAME is app name.`roche server`
Run api server## if you want to use roche server
Currently, this feature is not supported. Sorry.
```go
func Run() error {
+ defer roche.Close()
+
s := grapiserver.New(
+ rocheserver.WithDefaultLogger(),
- grapiserver.WithDefaultLogger(),
grapiserver.WithServers(
// TODO: Add server implementations
),
)
return s.Serve()
}
```## core maintainers
- @riita10069
- @hourglasshoro
- @ffjlabo[protobuf]: https://github.com/protocolbuffers/protobuf
[grapi]: https://github.com/izumin5210/grapi