snapshot of https://github.com/ThreeDotsLabs/watermill.git (master, 2026-09-15; blobs > 131072B omitted)
Some checks failed
master / ci (push) Failing after 0s

This commit is contained in:
upstream-mirror
2026-09-15 21:27:46 +05:00
commit ce933d1277
538 changed files with 46504 additions and 0 deletions

43
.github/ISSUE_TEMPLATE/bug_report.md vendored Normal file
View File

@@ -0,0 +1,43 @@
---
name: Bug report
about: Create a report to help us improve
title: ''
labels: bug
assignees: ''
---
<!--
The resources of our team are limited.
If you want to speed up fixing the problem, please follow the guidelines below.
It will help us to understand and reproduce the issue and to find a solution faster.
-->
### Steps to reproduce
<!--
⚠️ Important: Problem Reproduction Steps ⚠️
To help us investigate and fix your issue effectively, we need clear reproduction steps.
Include relevant code snippets and descriptions that demonstrate the problem.
-->
docker-compose.yml
```yaml
```
```go
// Your reproduction code goes here
```
### Expected behavior
<!-- What should happen -->
### Actual behavior
<!-- What happens instead -->
### Possible solution
<!-- Consider submitting a pull request - it will help us provide faster feedback on your solution. -->

1
.github/ISSUE_TEMPLATE/config.yml vendored Normal file
View File

@@ -0,0 +1 @@
blank_issues_enabled: true

View File

@@ -0,0 +1,33 @@
---
name: Feature request
about: Suggest an idea for this project
title: ''
labels: enhancement
assignees: ''
---
## Feature request
<!--
The resources of our team are limited. If you want to
We will be able to help you faster if you follow the guidelines below.
It will help us to understand and reproduce the issue and to find a solution faster.
-->
### Description
<!-- Describe the new feature clearly and concisely -->
### Example use case
<!--
Provide an example of how you would use this feature.
It will help us to understand the context of the request and to find the best solution.
-->
#### How it can look like in code
```go
```

42
.github/pull_request_template.md vendored Normal file
View File

@@ -0,0 +1,42 @@
<!--
Thanks for contributing to Watermill!
The following template aims to help contributors write a good description for their pull requests.
**The more information you provide, the faster we will be able to review and merge your PR.**
Feel free to skip this template for minor changes like typo fixes.
-->
### Motivation / Background
<!--
Explain the purpose of this Pull Request:
- What issue or bug does it address?
- What new functionality does it add?
- Why are these changes needed?
For bug fixes, include "Fixes #ISSUE" to automatically link to the related issue.
-->
### Detail
### Alternative approaches considered (if applicable)
<!-- If applicable, describe alternative approaches you considered and why you chose this one. -->
### Checklist
The resources of our team are limited. **There are a couple of things that you can do to help us merge your PR faster**:
- [ ] I wrote tests for the changes.
- [ ] All tests are passing.
- If you are testing a Pub/Sub, you can start Docker with `make up`.
- You can start with `make test_short` for a quick check.
- If you want to run all tests, use `make test`.
- [ ] Code has no breaking changes.
- [ ] _(If applicable)_ documentation on [watermill.io](https://watermill.io/) is updated.
- Documentation is built in the [github.com/ThreeDotsLabs/watermill/docs](https://github.com/ThreeDotsLabs/watermill/tree/master/docs).
- You can find development instructions in the [DEVELOP.md](https://github.com/ThreeDotsLabs/watermill/tree/master/docs/DEVELOP.md).

13
.github/workflows/master.yml vendored Normal file
View File

@@ -0,0 +1,13 @@
name: master
on:
push:
branches:
- master
jobs:
ci:
uses: ThreeDotsLabs/watermill/.github/workflows/tests.yml@master
with:
stress-tests: true
codecov: true
secrets:
codecov_token: ${{ secrets.CODECOV_TOKEN }}

52
.github/workflows/pr-examples.yml vendored Normal file
View File

@@ -0,0 +1,52 @@
name: pr-examples
on:
pull_request:
paths:
- '_examples/**/*'
jobs:
detect-changed-examples:
runs-on: ubuntu-latest
outputs:
examples: ${{ steps.set.outputs.examples }}
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- id: set
env:
BASE_SHA: ${{ github.event.pull_request.base.sha }}
HEAD_SHA: ${{ github.event.pull_request.head.sha }}
run: |
changed=$(git diff --name-only "$BASE_SHA"..."$HEAD_SHA")
example_dirs=$(find _examples -name '.validate_example*.yml' -exec dirname {} \; | sort -u)
examples=()
while IFS= read -r dir; do
if printf '%s\n' "$changed" | grep -q "^${dir}/"; then
examples+=("${dir#_examples/}")
fi
done <<< "$example_dirs"
if [ ${#examples[@]} -eq 0 ]; then
json='[]'
else
json=$(jq -c -n '$ARGS.positional' --args "${examples[@]}")
fi
echo "examples=$json" >> "$GITHUB_OUTPUT"
echo "Detected changed examples: $json"
validate:
needs: detect-changed-examples
if: needs.detect-changed-examples.outputs.examples != '[]'
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
example: ${{ fromJSON(needs.detect-changed-examples.outputs.examples) }}
timeout-minutes: 15
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: '^1.26'
- name: Validate ${{ matrix.example }}
run: cd dev/validate-examples && go run main.go "${{ matrix.example }}"

10
.github/workflows/pr.yml vendored Normal file
View File

@@ -0,0 +1,10 @@
name: pr
on:
pull_request:
jobs:
ci:
uses: ThreeDotsLabs/watermill/.github/workflows/tests.yml@master
with:
codecov: true
secrets:
codecov_token: ${{ secrets.CODECOV_TOKEN }}

95
.github/workflows/tests.yml vendored Normal file
View File

@@ -0,0 +1,95 @@
name: tests
on:
workflow_call:
inputs:
stress-tests:
description: 'Run stress tests'
required: false
type: boolean
default: false
codecov:
required: false
type: boolean
default: false
runs-on:
required: false
type: string
default: 'ubuntu-latest'
secrets:
codecov_token:
required: false
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v4
with:
go-version: '^1.26'
- run: make build
detect-modules:
runs-on: ubuntu-latest
outputs:
modules: ${{ steps.set-modules.outputs.modules }}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: '^1.26'
- id: set-modules
run: echo "modules=$(go list -m -json | jq -s '.' | jq -c '[.[].Dir]')" >> $GITHUB_OUTPUT
lint:
needs: detect-modules
runs-on: ubuntu-latest
strategy:
matrix:
modules: ${{ fromJSON(needs.detect-modules.outputs.modules) }}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v4
with:
go-version: '^1.26'
- name: golangci-lint ${{ matrix.modules }}
uses: golangci/golangci-lint-action@v9.2.0
with:
working-directory: ${{ matrix.modules }}
tests:
needs: [build]
runs-on: ${{ inputs.runs-on }}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v4
with:
go-version: '^1.26'
- run: cat .env >> $GITHUB_ENV || true
- run: make up
- run: make wait
- run: make test_short
- run: make test
timeout-minutes: 30
- run: make test_race
- run: make test_stress
if: ${{ inputs.stress-tests }}
- name: Dump docker logs on failure
if: failure()
uses: jwalton/gh-docker-logs@a8cb5301950dd4d2b86619cd487b3b281526b178 # v2.2.0
codecov:
runs-on: ${{ inputs.runs-on }}
if: ${{ inputs.codecov }}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v4
with:
go-version: '^1.26'
- run: cat .env >> $GITHUB_ENV || true
- run: make up
- run: make wait
- run: make test_codecov
- uses: codecov/codecov-action@v4
with:
fail_ci_if_error: true
files: ./coverage.out
token: ${{ secrets.codecov_token }}