Get ahead
VMware offers training and certification to turbo-charge your progress.
Learn moreThe Spring team will be rolling out a simplified contribution process that replaces the requirement to sign a Contributor License Agreement (CLA) with a Developer Certificate of Origin (DCO). The process will start this week with Spring Framework, Spring Security, & Spring Boot and then roll out to the entire Spring portfolio.
Spring has long used a permissive Contributor License Agreement (CLA) in order to provide legal protections to the Spring project, users, and the Spring team. Long time contributors may remember that signing the CLA originally involved emailing a signed PDF of the CLA. The Spring team was then required to manually verify that the CLA was signed before accepting contributions. Without integrations like GitHub Apps, this manual process was somewhat necessary then.
In order to streamline that process, we created an electronic version of the CLA which automatically verified that the authors of pull requests had signed the CLA. This was a large improvement over the manual process, but it still had its disadvantages.
While the electronic CLA simplified contributions, contributors were still faced with obstacles when contributing to Spring. CLAs are lengthy legal documents that can be difficult to understand. What’s more is that CLAs tend to be custom and thus the effort to understand them must be done on a per project basis. Due to legal requirements between employees and their employers, developers would often need to work with their employer to get approval to sign the CLA. All of these factors added additional layers of complexity when contributing to Spring.
In order to further simplify contributing to Spring, we have decided to move to using a Developer Certificate of Origin (DCO). This still provides the same protections to the Spring project, users, and Spring team.
The benefit is that the Developer Certificate of Origin (DCO) is easy to read and a standard across many projects including the Linux Kernel. The entire DCO can be summarized as:
In order to contribute to the project, you must agree to the Developer Certificate of Origin. To confirm that you agree, your commit message must include a Signed-off-by trailer at the bottom of the commit message. For example, it might look like the following:
A commit message
Closes gh-123
Signed-off-by: Rob Winch <[email protected]>
The Signed-off-by trailer can be added automatically by using the -s or –signoff command line option when specifying your commit message:
git commit -s -m
If you have chosen the Keep my email address private option within GitHub, the Signed-off-by trailer might look something like:
A commit message
Closes gh-123
Signed-off-by: Rob Winch <[email protected]>
Existing pull requests which are already passing the CLA check do not need to sign the DCO. If the pull request is not already passing the CLA, then the DCO process should be used.
The Spring Framework, Spring Security, and Spring Boot projects will transition to this process this week (January 6, 2025). After a successful trial period, we will migrate all Spring projects to use this process.
Spring uses the DCO GitHub App to add a check that enforces that all commits in a pull request contain a Signed-off-by trailer with a value of the email and name found in the user’s GitHub profile.
If you would like to see what the process looks like, the DCO app describes how the process works along with screenshots of what to expect.
If the DCO check fails, you can click on the “Details” link next to the failed check which will explain why the check failed and how to fix it. If you forgot to add the Signed-off-by trailer for a single commit, then you can do so by using:
git rebase HEAD~1 --signoff
git push —-force-with-lease origin
Clause c of the Developer Certificate of Origin allows a commit containing code from multiple origins to include a single Signed-off-by trailer. In this instance, inclusion of the Signed-off-by trailer indicates that the commit author certifies that they have the right to submit the commit under the project’s license.
You may apply suggested changes on a pull request.
The Developer Certificate of Origin clause b allows modifying the code, but it can be considered impolite attributing your changes (bugs) to another person. For that reason, it is considered polite to insert a description with your email and name enclosed in square brackets followed by a Signed-off-by at the end of the commit message. For example:
Signed-off-by: PR Developer <[email protected]>
[[email protected]: apply code conventions]
Signed-off-by: Committer Developer <[email protected]>
We are looking forward to seeing more & simplified contributions from you! If you have any questions, don’t hesitate to reach out to us in our issue trackers.