-
Notifications
You must be signed in to change notification settings - Fork 29
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #10 from odpf/release-prep
Release prep
- Loading branch information
Showing
12 changed files
with
219 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,22 @@ | ||
# Structure | ||
This document describes high-level code structure of the project. You'll find this part useful when you want to get started to contribute to Raccoon. | ||
|
||
## Highlevel View | ||
The core structure of Raccoon is the server itself. After the server is started, data flows from `websocket` to `worker` to `publisher`. `websocket` manages websocket server, handle incoming connection, and incoming request. `worker` acts as a buffer and interface for various types of server and publisher down the roadmap. `publisher` contains logic to publish the events to the downstream pipeline. | ||
![high-level](../assets/structure.svg) | ||
All the components above are initialized on `app`. `app` package is the starting point of Raccoon. | ||
## Code Map | ||
This section talks briefly about the content of various important packages. You can use this to guess the code location when you need to make changes. | ||
### `websocket` | ||
Contains server-related code along with request/response handlers and [connection management](architecture.md#connections). | ||
### `worker` | ||
Buffer from when the events are processed and before events are published. This will also act as interface that connects server and publisher when in the future. Currently, `worker` is tightly coupled with `websocket` server and `kafka` publisher. | ||
### `publisher` | ||
Does the actual publishing to the downstream pipeline. Currently, only support Kafka publisher. | ||
### `app` | ||
The starting point of Raccoon. It initializes server, worker, publisher, and other components that require initialization like a metric reporter. | ||
### `config` | ||
Load and store application configurations. Contains mapping of environment configuration with configuration on the code. | ||
## Code Generation | ||
### Request, Response, and Events Proto | ||
Raccoon depends on [Proton](https://github.com/odpf/proton/tree/main/odpf/raccoon) repository. Proton is a repository to store all ODPF Protobuf files. Code to serde the request and response are generated using Protobuf. You can check how the code is generated on `Makefile`. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,29 @@ | ||
# Development Guide | ||
|
||
This guide is targeted at developers looking to contribute to Raccoon. | ||
|
||
## Making a Pull Request | ||
|
||
#### Incorporating upstream changes from main | ||
|
||
Our preference is the use of `git rebase` instead of `git merge` : `git pull -r` | ||
|
||
#### Signing commits | ||
|
||
Commits have to be signed before they are allowed to be merged into the codebase: | ||
|
||
```bash | ||
# Include -s flag to signoff | ||
git commit -s -m "My first commit" | ||
``` | ||
|
||
#### Good practices to keep in mind | ||
|
||
- Follow [conventional commits](https://www.conventionalcommits.org/en/v1.0.0/#summary) while composing our commit messages. | ||
- Add `WIP:` to PR name if more work needs to be done prior to review | ||
- Avoid `force-pushing` as it makes reviewing difficult | ||
|
||
**Managing CI-test failures** | ||
|
||
- GitHub runner tests | ||
- Click `checks` tab to analyse failed tests |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,23 @@ | ||
# Release Process | ||
# Release | ||
For maintainers, please read the sections below as a guide to create a new release. | ||
## Create A New Release | ||
Please follow these steps to create a new release: | ||
- Update `version.txt` file | ||
- Generate changelog from commits by using [conventional-changelog-cli](https://www.npmjs.com/package/conventional-changelog-cli#quick-start) | ||
```sh | ||
$ conventional-changelog -s -p conventionalcommits -i CHANGELOG.md | ||
``` | ||
- Commit `version.txt` and `CHANGELOG.md` together and mark the commit with the release tag. Make sure the release tag and `version.txt` are the same. | ||
```sh | ||
$ git add version.txt CHANGELOG.md | ||
$ git commit -m "docs: update changelog and version for vM.m.p" | ||
$ git tag vM.m.p | ||
``` | ||
- Push the commit and the tag. Release action will trigger to publish docker image and create GitHub release. | ||
|
||
## Important Notes | ||
- Raccoon release tags follow [SEMVER](https://semver.org/) convention. | ||
- Github workflow is used to build and push the built docker image to Docker hub. | ||
- A release is triggered when a github tag of format `vM.m.p` is pushed. After the release job is succeeded, a docker image of | ||
format `M.m.p` is pushed to docker hub. | ||
- Release tags should only point to main branch |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.