Skip to content

Commit 6d094b8

Browse files
authored
Merge the two CONTRIBUTING.md's (#2543)
- Remove `./.github/CONTRIBUTING.md`, while merging some parts of it into the top-level CONTRIBUTING.md. - Link to the top-level CONTRIBUTING.md from README.md Signed-off-by: Adrian Preston <[email protected]>
1 parent bbee916 commit 6d094b8

File tree

3 files changed

+36
-35
lines changed

3 files changed

+36
-35
lines changed

.github/CONTRIBUTING.md

-31
This file was deleted.

CONTRIBUTING.md

+35-3
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,28 @@
1-
## Contributing
1+
# Contributing
22

33
[fork]: https://github.com/IBM/sarama/fork
44
[pr]: https://github.com/IBM/sarama/compare
55
[released]: https://help.github.com/articles/github-terms-of-service/#6-contributions-under-repository-license
66

77
Hi there! We are thrilled that you would like to contribute to Sarama.
8-
Your help is essential for keeping it great.
8+
Contributions are always welcome, both reporting issues and submitting pull requests!
9+
10+
## Reporting issues
11+
12+
Please make sure to include any potentially useful information in the issue, so we can pinpoint the issue faster without going back and forth.
13+
14+
- What SHA of Sarama are you running? If this is not the latest SHA on the main branch, please try if the problem persists with the latest version.
15+
- You can set `sarama.Logger` to a [log.Logger](http://golang.org/pkg/log/#Logger) instance to capture debug output. Please include it in your issue description.
16+
- Also look at the logs of the Kafka broker you are connected to. If you see anything out of the ordinary, please include it.
17+
18+
Also, please include the following information about your environment, so we can help you faster:
19+
20+
- What version of Kafka are you using?
21+
- What version of Go are you using?
22+
- What are the values of your Producer/Consumer/Client configuration?
23+
24+
25+
## Contributing a change
926

1027
Contributions to this project are [released][released] to the public under the project's [opensource license](LICENSE.md).
1128
By contributing to this project you agree to the [Developer Certificate of Origin](https://developercertificate.org/) (DCO).
@@ -19,12 +36,26 @@ feat: this is my commit message
1936
Signed-off-by: Random J Developer <[email protected]>
2037
```
2138

22-
Git even has a `-s` command line option to append this automatically to your commit message:
39+
Git even has a `-s` command line option to append this automatically to your
40+
commit message:
2341

2442
```
2543
$ git commit -s -m 'This is my commit message'
2644
```
2745

46+
Because this library is in production use by many people and applications, we code review all additions.
47+
To make the review process go as smooth as possible, please consider the following.
48+
49+
- If you plan to work on something major, please open an issue to discuss the design first.
50+
- Don't break backwards compatibility. If you really have to, open an issue to discuss this first.
51+
- Make sure to use the `go fmt` command to format your code according to the standards. Even better, set up your editor to do this for you when saving.
52+
- Run [go vet](https://golang.org/cmd/vet/) to detect any suspicious constructs in your code that could be bugs.
53+
- Explicitly handle all error return values. If you really want to ignore an error value, you can assign it to `_`. You can use [errcheck](https://github.com/kisielk/errcheck) to verify whether you have handled all errors.
54+
- You may also want to run [golint](https://github.com/golang/lint) as well to detect style problems.
55+
- Add tests that cover the changes you made. Make sure to run `go test` with the `-race` argument to test for race conditions.
56+
- Make sure your code is supported by all the Go versions we support.
57+
You can rely on GitHub Actions for testing older Go versions.
58+
2859
## Submitting a pull request
2960

3061
0. [Fork][fork] and clone the repository
@@ -44,3 +75,4 @@ Here are a few things you can do that will increase the likelihood of your pull
4475
- [How to Contribute to Open Source](https://opensource.guide/how-to-contribute/)
4576
- [Using Pull Requests](https://help.github.com/articles/about-pull-requests/)
4677
- [GitHub Help](https://help.github.com)
78+

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ A changelog is available [here](CHANGELOG.md).
2525

2626
## Contributing
2727

28-
- Get started by checking our [contribution guidelines](https://github.com/IBM/sarama/blob/main/.github/CONTRIBUTING.md).
28+
- Get started by checking our [contribution guidelines](https://github.com/IBM/sarama/blob/main/CONTRIBUTING.md).
2929
- Read the [Sarama wiki](https://github.com/IBM/sarama/wiki) for more technical and design details.
3030
- The [Kafka Protocol Specification](https://cwiki.apache.org/confluence/display/KAFKA/A+Guide+To+The+Kafka+Protocol) contains a wealth of useful information.
3131
- For more general issues, there is [a google group](https://groups.google.com/forum/#!forum/kafka-clients) for Kafka client developers.

0 commit comments

Comments
 (0)