Andrea Campanella | 4dd0422 | 2022-03-18 15:52:28 +0100 | [diff] [blame] | 1 | ====================== |
| 2 | Contributing to VOLTHA |
| 3 | ====================== |
| 4 | |
| 5 | We'd love to accept your patches and contributions to the VOLTHA project. There are |
| 6 | just a few small guidelines you need to follow. |
| 7 | |
| 8 | Contributor License Agreement |
| 9 | ----------------------------- |
| 10 | |
| 11 | Contributions to this project must be accompanied by a Contributor License |
| 12 | Agreement. You (or your employer) retain the copyright to your contribution, |
| 13 | this simply gives us permission to use and redistribute your contributions as |
| 14 | part of the project. Head over to the `ONF CLA <https://cla.opennetworking.org/>`_ to see |
| 15 | your current agreements on file or to sign a new one. |
| 16 | |
| 17 | You generally only need to submit a CLA once, so if you've already submitted one |
| 18 | (even if it was for a different project), you probably don't need to do it |
| 19 | again. |
| 20 | |
| 21 | Guides, Rules and Best Practices |
| 22 | -------------------------------- |
| 23 | |
| 24 | VOLTHA follows `Google's Engineering Practices <https://google.github.io/eng-practices/>`_, |
| 25 | `Golang Formatting Guide <https://go.dev/doc/effective_go#formatting>`_. Use these documents as a guide when |
| 26 | writing, submitting or reviewing code. |
| 27 | VOLTHA uses gerrit to submit, review, tests and finally merge patches. |
| 28 | |
| 29 | Submitting Code |
| 30 | +++++++++++++++ |
| 31 | |
| 32 | Some additional points for developers: |
| 33 | |
| 34 | - Submit your changes early and often. Input and |
| 35 | corrections early in the process prevent huge changes later. |
| 36 | |
Joey Armstrong | a62c74a | 2022-11-23 13:16:34 -0500 | [diff] [blame] | 37 | - Please open a `jira ticket <https://jira.opencord.org/projects/VOL>`_ describing the issue/feature. During the patch please |
Andrea Campanella | 4dd0422 | 2022-03-18 15:52:28 +0100 | [diff] [blame] | 38 | preface the commit message with `[VOL-<jira_number]` e.g. `[VOL-4550]` so it gets |
| 39 | automatically linked to the Jira ticket. This keeps code review and design discussions clean. |
| 40 | |
| 41 | Steps to successful PRs |
| 42 | +++++++++++++++++++++++ |
| 43 | |
| 44 | 1. Checkout the code and prepare your patch. The workflow to make changes to the VOLTHA code through gerrit is identical |
| 45 | to the one from `onos-classic` and is described in the |
| 46 | `Sample Gerrit Workflow page <https://wiki.onosproject.org/display/ONOS/Sample+Gerrit+Workflow>`_ |
| 47 | |
| 48 | 2. Before submitting the patch via `git review` please execute VOLTHA specific tests: |
| 49 | `make test` and `make sca`. These commands run unit test, linting and other elements |
| 50 | to assure the quality of your patch. |
| 51 | |
| 52 | 3. Wait for sanity checks `jenkins <https://jenkins.opencord.org>`_ to pass. |
| 53 | If the tests fail please fix your patch with step 3 an then repeat 2 and 3, as necessary. |
| 54 | **Passing CI verification is mandatory.** If the CI check does not start or fails but you think the issue |
| 55 | is un-related you can re-trigger by commenting on to the patch with `recheck`. |
| 56 | |
| 57 | 4. When comments are made to your patch please make the appropriate fixes and then |
| 58 | amend your commit with `git commit --amend` and re-upload to gerrit with `git review`. |
| 59 | |
| 60 | 5. Await review. Everyone can comment on code changes, but only Core contributors |
| 61 | can give final review approval. **All changes must get at least one |
| 62 | approval**. Join one of the `communication channels <https://wiki.opennetworking.org/display/COM/VOLTHA>`_ |
| 63 | to request a review or to bring additional attention to your patch. |
| 64 | |
Andrea Campanella | 7dae5ce | 2022-03-25 16:08:15 +0100 | [diff] [blame] | 65 | Versioning |
| 66 | ++++++++++ |
| 67 | |
| 68 | All of the VOLTHA components and the charts include a VERSION file that specifies |
| 69 | the version of the service, library, protobuf, test suite included in the repository. |
| 70 | The VERSION is in the format and follows the `SemVer principles <https://semver.org>`_ |
| 71 | VOLTHA also follows the guidelines on how to increment versions as described in the |
| 72 | `SemVer specification <https://semver.org/#semantic-versioning-specification-semver>`_. |
| 73 | |
| 74 | Each increment of the VERSION file in a patch automatically triggers publishing of the repository |
| 75 | artifact, e.g. docker images, with that tag. |
| 76 | In VOLTHA we also use a `x.y.z-dev` format which identifies a non-released component (what is `master`). |
| 77 | When a patch is merged with the `-dev` suffix in the VERSION file no artifact is published except for `master` |
| 78 | docker images. The `-dev` suffix should be removed when a feature being worked on and the component |
| 79 | is ready for release. |
| 80 | |
| 81 | We expect contributions to the VOLTHA codebase to follow these rules when submitting a patch |
| 82 | and the same rules to be enforced by reviewers during the core review process. |
| 83 | |
| 84 | |
Andrea Campanella | 4dd0422 | 2022-03-18 15:52:28 +0100 | [diff] [blame] | 85 | Core Contributors |
| 86 | ----------------- |
| 87 | |
| 88 | Anyone with a Gerrit account can open new issues, comment on existing issues, or |
| 89 | contribute code by opening a review. |
| 90 | |
| 91 | A **“core contributor”** is someone who can manage, approve and |
| 92 | merge patches, and create new branches in the main repository. |
| 93 | |
| 94 | Core contributors are responsible for maintaining the quality of contributions |
| 95 | to the codebase. The goal of this program is to have a diverse group of |
| 96 | individuals whose expertise in aggregate covers the entire project. |
| 97 | |
| 98 | The benefits of being a core contributor include: |
| 99 | - Increased influence of the direction of the project |
| 100 | - The ability to create branches in the main repository and after others approve it |
| 101 | merge your own code |
| 102 | - Community recognition and visibility for their contributions and expertise. |
| 103 | |
| 104 | Becoming a Core Contributor |
| 105 | +++++++++++++++++++++++++++ |
| 106 | |
| 107 | Core contributor candidates need to have a demonstrated proficiency with the |
| 108 | VOLTHA codebase and a track record of code reviews. Members of the Technical |
| 109 | Steering Team (TST) and existing core contributors will regularly invite people |
| 110 | to become new core contributors. Nominations can also be made (including |
| 111 | self-nominations) to the VOLTHA TST (`voltha-tst@opennetworking.org`) at any time. |
| 112 | |
| 113 | A good nomination will include details about who the person is (including their email |
| 114 | and Github and/or Gerrit username) and outline their experience with the VOLTHA codebase |
| 115 | and project at large. |
| 116 | Nominations are intended to start a conversation that results in a decision to |
| 117 | make the person a core contributor – anyone whose nomination is not initially |
| 118 | approved is encouraged to gain more experience with code submission and code |
| 119 | review in order to gain further mastery over the codebase. Partial approval is |
| 120 | also possible (e.g. a person may be granted the ability to handles patches only |
| 121 | on a certain repository), and full approval may be granted after the contributor |
| 122 | has gained more experience. |
| 123 | |
| 124 | New core contributors will be assigned a mentor that is either a TST member or |
| 125 | existing core contributor. The mentor will serve as the primary point of contact |
| 126 | to help onboard the new core contributors and answer any questions they have |
| 127 | with their new responsibilities. The mentor is not the only point of contact, |
| 128 | and core contributors should feel free to reach out to others if and when they |
| 129 | have questions or concerns. |
| 130 | |
| 131 | Guidelines for Core Contributors |
| 132 | ++++++++++++++++++++++++++++++++ |
| 133 | |
| 134 | Contributions in VOLTHA can should be merged after two different +1 arrive on a |
| 135 | given patch-set that is verified by CI as well. |
| 136 | For your own contributions, you now have the ability to approve and merge your |
| 137 | own code, pending that you received two other positive reviews. |
| 138 | For larger or potentially controversial reviews, please give the |
| 139 | community an opportunity (at least a few business days) to review your |
| 140 | contribution. Please always ask for comments on the #voltha-dev Slack channel. |
| 141 | **With great power comes great responsibility; please don't abuse |
| 142 | this privilege.** |
| 143 | |
| 144 | All Core Contributors have +2 and merge capabilities on all the repositories related |
| 145 | to the VOLTHA project, but we expect that they are responsible and exercise their |
| 146 | privilege **only** on patches and repositories they have expertise in and are comfortable reviewing and merging. |
| 147 | |
| 148 | To help patchset verification the VOLTHA test infrastructure offers Per-Patchset Verification Jobs |
| 149 | triggered by specific keyword used in the patch. More information can be found in the |
| 150 | `testing automation page <https://docs.voltha.org/master/testing/voltha_test_automation.html#per-patchset-verification-jobs>`_ |
| 151 | We suggest Core contributors to use these triggers when they would like more checks on a patch they are uncertain about |
| 152 | or that might have differences when applied to hardware pods. |
| 153 | |
| 154 | VOLTHA follows `Google’s best practices for code review <https://google.github.io/eng-practices/review/reviewer/>`_. |
| 155 | You should apply these guidelines strictly and with confidence when reviewing |
| 156 | submissions. |
| 157 | |
| 158 | If you are unsure about something in an issue or a review, leave a comment |
| 159 | that outlines your concerns. If a resolution is difficult to reach in the |
| 160 | comments section, the TST meetings are a good place to raise your concerns and |
| 161 | have a discussion. |
| 162 | |
| 163 | Current Core Contributors |
| 164 | +++++++++++++++++++++++++++ |
| 165 | |
| 166 | This is a list of core contributors divided by area of expertise: |
| 167 | |
| 168 | Adapter openonu and omci-lib-go: |
| 169 | |
| 170 | - `Holger Hildebrandt <holger.hildebrandt@adtran.com>`_ |
| 171 | - `Chip Boling <chip.boling@tibitcom.com>`_ |
| 172 | - `Michael Pagenkopf <michael.pagenkopf@adtran.com>`_ |
| 173 | - `Ozge Ayaz <ozge.ayaz@netsia.com>`_ |
| 174 | |
| 175 | Voltha-system-tests: |
| 176 | |
| 177 | - `Torsten Thieme <torsten.thieme@adtran.com>`_ |
| 178 | |
| 179 | Openolt agent: |
| 180 | |
| 181 | - `Thiyagarajan Subramani <Thiyagarajan.Subramani@radisys.com>`_ |
| 182 | - `Burak Gurdag <burak.gurdag@netsia.com>`_ |
| 183 | |
| 184 | ONOS apps: |
| 185 | |
| 186 | - `Gamze Abaka <gamze.abaka@netsia.com>`_ |
| 187 | - `Yasin Sapli <yasin.sapli@netsia.com>`_ |
| 188 | - `Tunahan Sezen <tunahan.sezen@netsia.com>`_ |
| 189 | |
| 190 | Olt adapter, rw-core: |
| 191 | |
| 192 | - `Abhilash Satish Laxmeshwar <abhilash.laxmeshwar@radisys.com>`_ |
| 193 | - `Gamze Abaka <gamze.abaka@netsia.com>`_ |
| 194 | |
| 195 | All of the codebase: |
| 196 | |
| 197 | - `Andrea Campanella <andrea@opennetworking.org>`_ |
| 198 | - `Matteo Scandolo <teo@opennetworking.org>`_ |
| 199 | - `Girish Gowdra <girish@opennetworking.org>`_ |
| 200 | - `Hardik Windlass <hardik@opennetworking.org>`_ |
| 201 | - `Suchitra Vemuri <suchitra@opennetworking.org>`_ |
| 202 | - `Saurav Das <saurav.das@opennetworking.org>`_ |
| 203 | - `Mahir Gunyel <mahir.gunyel@netsia.com>`_ |
| 204 | - `Serkant Uluderya <serkant.uluderya@netsia.com>`_ |
| 205 | - `Amit Ghosh <Amit.Ghosh@radisys.com>`_ |
| 206 | - `Khenaidoo Nursimulu <knursimu@ciena.com>`_ |
| 207 | - `David Bainbridge <dbainbri.ciena@gmail.com>`_ |
| 208 | |
Andrea Campanella | 4dd0422 | 2022-03-18 15:52:28 +0100 | [diff] [blame] | 209 | Community Guidelines |
| 210 | -------------------- |
| 211 | |
| 212 | This project follows `Google's Open Source Community Guidelines <https://opensource.google.com/conduct/>`_ |
| 213 | and ONF's [Code of Conduct](CODE_OF_CONDUCT.md). |