You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@openwhisk.apache.org by Ying Chun Guo <gu...@cn.ibm.com> on 2018/02/08 12:24:36 UTC
Release policy compliance: Adding license headers and the excluded files
Hello, whiskers
In order to get Apache release policy compliance, we need to add license headers to every source file in the distributions with few exceptions. I'd like to share what I have done and what I'm going to do with you.
"With few exceptions, all human-readable Apache-developed files that are included within a distribution must include the header text."
Quoted from http://www.apache.org/legal/src-headers.html
I use Apache Rat to audit license headers. I use wskdeploy repo as the trial repo. I reported an issue (https://github.com/apache/incubator-openwhisk-wskdeploy/issues/716) to wskdeploy including a report generated by Apache Rat. In the report, all the files with unapproved licenses will be listed. Then I submit a PR (https://github.com/apache/incubator-openwhisk-wskdeploy/pull/709) to add Apache license headers. I'm going to do same to all the other projects in OpenWhisk community. Matt Rutkowski offers help to this work too.
As to the exceptions, I followed the document in http://www.apache.org/legal/src-headers.html#faq-exceptions to decide which files can be excluded. In wskdeploy project, they are:
# files copied from third parties or created by tools
gradlew
gradlew.bat
Godeps
i18n_resources.go
# JSON data file doesn't support annotation
.*json
# Test data
# others
.gitignore
.rat-excludes
Different repo may have a different exception list. The exception list can be tracked by .rat-excludes in the root folder ( refer to https://github.com/daisy-ycguo/incubator-openwhisk-wskdeploy/blob/add_lice/.rat-excludes )
If you have comments or suggestions to my work or to the exception list, feel free to discuss here. I'm open for any inputs. Thank you.
Best regards
Ying Chun Guo (Daisy)
Re: Release policy compliance: Adding license headers and the
excluded files
Posted by Carlos Santana <cs...@gmail.com>.
+1 Daisy
Thanks !
--Carlos
On Thu, Feb 8, 2018 at 7:24 AM Ying Chun Guo <gu...@cn.ibm.com> wrote:
> Hello, whiskers
>
> In order to get Apache release policy compliance, we need to add license
> headers to every source file in the distributions with few exceptions. I'd
> like to share what I have done and what I'm going to do with you.
>
> "With few exceptions, all human-readable Apache-developed files that are
> included within a distribution must include the header text."
> Quoted from http://www.apache.org/legal/src-headers.html
>
> I use Apache Rat to audit license headers. I use wskdeploy repo as the
> trial repo. I reported an issue (
> https://github.com/apache/incubator-openwhisk-wskdeploy/issues/716) to
> wskdeploy including a report generated by Apache Rat. In the report, all
> the files with unapproved licenses will be listed. Then I submit a PR (
> https://github.com/apache/incubator-openwhisk-wskdeploy/pull/709) to add
> Apache license headers. I'm going to do same to all the other projects in
> OpenWhisk community. Matt Rutkowski offers help to this work too.
>
> As to the exceptions, I followed the document in
> http://www.apache.org/legal/src-headers.html#faq-exceptions to decide
> which files can be excluded. In wskdeploy project, they are:
> # files copied from third parties or created by tools
> gradlew
> gradlew.bat
> Godeps
> i18n_resources.go
>
> # JSON data file doesn't support annotation
> .*json
>
> # Test data
>
> # others
> .gitignore
> .rat-excludes
>
> Different repo may have a different exception list. The exception list can
> be tracked by .rat-excludes in the root folder ( refer to
> https://github.com/daisy-ycguo/incubator-openwhisk-wskdeploy/blob/add_lice/.rat-excludes
> )
>
> If you have comments or suggestions to my work or to the exception list,
> feel free to discuss here. I'm open for any inputs. Thank you.
>
> Best regards
> Ying Chun Guo (Daisy)
>
>
>
>
Re: Release policy compliance: Adding license headers and the excluded
files
Posted by Ying Chun Guo <gu...@cn.ibm.com>.
Hi, Matt
I tested. The answer is NO. Apache Rat cannot recognize short header format.
That will cause a problem because the large size of action files will slow down the tests running.
We can ignore these files till Rat supports short header format.
Best regards
Ying Chun Guo (Daisy)
-----"Matt Rutkowski" <mr...@us.ibm.com> wrote: -----
>To: dev@openwhisk.apache.org
>From: "Matt Rutkowski" <mr...@us.ibm.com>
>Date: 02/12/2018 11:53PM
>Subject: Re: Release policy compliance: Adding license headers and
>the excluded files
>
>Is there any way for the RAT tool to acknowledge the "minified" ASF
>header
>that is approved for use in .js (and other files)?
>
>See "short form" approved here:
>https://urldefense.proofpoint.com/v2/url?u=https-3A__www.apache.org_l
>egal_src-2Dheaders.html&d=DwIFAg&c=jf_iaSHvJObTbx-siA1ZOg&r=V_NQebMEs
>ahq0wRsMMLN8VHG-pcqPRpdHygvo4rmK4o&m=V06q35OiWjYJAWe2jq-3fSk7CreRb6Ah
>wORWCs2KSJw&s=iNii7yGWwSTIBwziwicIhtKB91LCc5XgQpmAu_bTb9k&e=
>
>Kind regards,
>Matt
>
>
>
>
>From: "Ying Chun Guo" <gu...@cn.ibm.com>
>To: dev@openwhisk.apache.org
>Date: 02/12/2018 08:18 AM
>Subject: Re: Release policy compliance: Adding license headers
>and
>the excluded files
>
>
>
>Hi, Bertrand
>
>Thank you for the inputs.
>
>My original thought was to maintain different Rat exclusions for
>different
>repo because they may have different files. If we want to maintain a
>unique version, we may need to collect all exclusions in all the repo
>
>together and maintain a set. Sometimes it's difficult to tell whether
>a
>file shall be excluded or not. Hope you can help review after the
>collection is ready.
>
>OpenWhisk has a repo in github to track release documents and
>scripts.
>Here it is:
>https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_apach
>e_incubator-2Dopenwhisk-2Drelease_blob_master_README.md&d=DwIFaQ&c=jf
>_iaSHvJObTbx-siA1ZOg&r=6zQLM7Gc0Sv1iwayKOKa4_SFxRIxS478q2gZlAJj4Zw&m=
>tuRJI4eVUHlqHACnIGwvLgDqy1D9dIaSeLjOME3KJJg&s=RqfPKNiDPwlE1yljo6i5Rct
>CRB6jXLLbQ5gickneycE&e=
>. I think these information can be documented here:
>https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_apach
>e_incubator-2Dopenwhisk-2Drelease_blob_master_docs_work-5Fitems.md-23
>2-2Dverify-2Dthe-2Dcompliance-2Dof-2Dthe-2Dsource-2Dcode-2Dopen-2Diss
>ue&d=DwIFaQ&c=jf_iaSHvJObTbx-siA1ZOg&r=6zQLM7Gc0Sv1iwayKOKa4_SFxRIxS4
>78q2gZlAJj4Zw&m=tuRJI4eVUHlqHACnIGwvLgDqy1D9dIaSeLjOME3KJJg&s=t34yGdw
>cAE-qLfsKcS0ueeVqUAffslBtsP_kxQmK2fk&e=
>.
>
>Best regards
>Ying Chun Guo (Daisy)
>
>
>-----Bertrand Delacretaz <bd...@apache.org> wrote: -----
>To: dev@openwhisk.apache.org
>From: Bertrand Delacretaz <bd...@apache.org>
>Date: 02/09/2018 06:41PM
>Subject: Re: Release policy compliance: Adding license headers and
>the
>excluded files
>
>Hi Daisy,
>
>On Thu, Feb 8, 2018 at 1:24 PM, Ying Chun Guo <gu...@cn.ibm.com>
>wrote:
>> ...I use Apache Rat to audit license headers. I use wskdeploy repo
>as
>the trial repo.
>> I reported an issue (
>https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_apach
>e_incubator-2Dopenwhisk-2Dwskdeploy_issues_716&d=DwIBaQ&c=jf_iaSHvJOb
>Tbx-siA1ZOg&r=V_NQebMEsahq0wRsMMLN8VHG-pcqPRpdHygvo4rmK4o&m=m3ygIAacP
>w2tdx9MhWLfpLzsW1V32RO3z5g6A2YFWCo&s=zY3fWnnLVXjHDVQvYS73Db0ljWoQg4Oa
>YlqNm1mbjWE&e=
>)
>> to wskdeploy including a report generated by Apache Rat. In the
>report,
>all the files
>> with unapproved licenses will be listed...
>
>This sounds great.
>
>What you want basically is that for any build that's meant to create
>a
>release:
>
>-Rat should run
>-The build should fail if Rat reports any anomalies
>-The Rat exclusions should ideally be defined in the same way for all
>modules, for consistency
>-The Rat exclusions should be commented to indicate why each
>exclusion
>(or family of exclusions) is here
>
>I think this should be documented in a "coding standards" or "release
>management" page, does OpenWhisk have this already?
>
>-Bertrand (with my incubation mentor hat on)
>
>
>
>
>
>
>
Re: Release policy compliance: Adding license headers and the excluded
files
Posted by Matt Rutkowski <mr...@us.ibm.com>.
Is there any way for the RAT tool to acknowledge the "minified" ASF header
that is approved for use in .js (and other files)?
See "short form" approved here:
https://www.apache.org/legal/src-headers.html
Kind regards,
Matt
From: "Ying Chun Guo" <gu...@cn.ibm.com>
To: dev@openwhisk.apache.org
Date: 02/12/2018 08:18 AM
Subject: Re: Release policy compliance: Adding license headers and
the excluded files
Hi, Bertrand
Thank you for the inputs.
My original thought was to maintain different Rat exclusions for different
repo because they may have different files. If we want to maintain a
unique version, we may need to collect all exclusions in all the repo
together and maintain a set. Sometimes it's difficult to tell whether a
file shall be excluded or not. Hope you can help review after the
collection is ready.
OpenWhisk has a repo in github to track release documents and scripts.
Here it is:
https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_apache_incubator-2Dopenwhisk-2Drelease_blob_master_README.md&d=DwIFaQ&c=jf_iaSHvJObTbx-siA1ZOg&r=6zQLM7Gc0Sv1iwayKOKa4_SFxRIxS478q2gZlAJj4Zw&m=tuRJI4eVUHlqHACnIGwvLgDqy1D9dIaSeLjOME3KJJg&s=RqfPKNiDPwlE1yljo6i5RctCRB6jXLLbQ5gickneycE&e=
. I think these information can be documented here:
https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_apache_incubator-2Dopenwhisk-2Drelease_blob_master_docs_work-5Fitems.md-232-2Dverify-2Dthe-2Dcompliance-2Dof-2Dthe-2Dsource-2Dcode-2Dopen-2Dissue&d=DwIFaQ&c=jf_iaSHvJObTbx-siA1ZOg&r=6zQLM7Gc0Sv1iwayKOKa4_SFxRIxS478q2gZlAJj4Zw&m=tuRJI4eVUHlqHACnIGwvLgDqy1D9dIaSeLjOME3KJJg&s=t34yGdwcAE-qLfsKcS0ueeVqUAffslBtsP_kxQmK2fk&e=
.
Best regards
Ying Chun Guo (Daisy)
-----Bertrand Delacretaz <bd...@apache.org> wrote: -----
To: dev@openwhisk.apache.org
From: Bertrand Delacretaz <bd...@apache.org>
Date: 02/09/2018 06:41PM
Subject: Re: Release policy compliance: Adding license headers and the
excluded files
Hi Daisy,
On Thu, Feb 8, 2018 at 1:24 PM, Ying Chun Guo <gu...@cn.ibm.com> wrote:
> ...I use Apache Rat to audit license headers. I use wskdeploy repo as
the trial repo.
> I reported an issue (
https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_apache_incubator-2Dopenwhisk-2Dwskdeploy_issues_716&d=DwIBaQ&c=jf_iaSHvJObTbx-siA1ZOg&r=V_NQebMEsahq0wRsMMLN8VHG-pcqPRpdHygvo4rmK4o&m=m3ygIAacPw2tdx9MhWLfpLzsW1V32RO3z5g6A2YFWCo&s=zY3fWnnLVXjHDVQvYS73Db0ljWoQg4OaYlqNm1mbjWE&e=
)
> to wskdeploy including a report generated by Apache Rat. In the report,
all the files
> with unapproved licenses will be listed...
This sounds great.
What you want basically is that for any build that's meant to create a
release:
-Rat should run
-The build should fail if Rat reports any anomalies
-The Rat exclusions should ideally be defined in the same way for all
modules, for consistency
-The Rat exclusions should be commented to indicate why each exclusion
(or family of exclusions) is here
I think this should be documented in a "coding standards" or "release
management" page, does OpenWhisk have this already?
-Bertrand (with my incubation mentor hat on)
Re: Release policy compliance: Adding license headers and the excluded
files
Posted by Ying Chun Guo <gu...@cn.ibm.com>.
Hi, Bertrand
Thank you for the inputs.
My original thought was to maintain different Rat exclusions for different repo because they may have different files. If we want to maintain a unique version, we may need to collect all exclusions in all the repo together and maintain a set. Sometimes it's difficult to tell whether a file shall be excluded or not. Hope you can help review after the collection is ready.
OpenWhisk has a repo in github to track release documents and scripts.
Here it is: https://github.com/apache/incubator-openwhisk-release/blob/master/README.md. I think these information can be documented here: https://github.com/apache/incubator-openwhisk-release/blob/master/docs/work_items.md#2-verify-the-compliance-of-the-source-code-open-issue.
Best regards
Ying Chun Guo (Daisy)
-----Bertrand Delacretaz <bd...@apache.org> wrote: -----
To: dev@openwhisk.apache.org
From: Bertrand Delacretaz <bd...@apache.org>
Date: 02/09/2018 06:41PM
Subject: Re: Release policy compliance: Adding license headers and the excluded files
Hi Daisy,
On Thu, Feb 8, 2018 at 1:24 PM, Ying Chun Guo <gu...@cn.ibm.com> wrote:
> ...I use Apache Rat to audit license headers. I use wskdeploy repo as the trial repo.
> I reported an issue (https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_apache_incubator-2Dopenwhisk-2Dwskdeploy_issues_716&d=DwIBaQ&c=jf_iaSHvJObTbx-siA1ZOg&r=V_NQebMEsahq0wRsMMLN8VHG-pcqPRpdHygvo4rmK4o&m=m3ygIAacPw2tdx9MhWLfpLzsW1V32RO3z5g6A2YFWCo&s=zY3fWnnLVXjHDVQvYS73Db0ljWoQg4OaYlqNm1mbjWE&e=)
> to wskdeploy including a report generated by Apache Rat. In the report, all the files
> with unapproved licenses will be listed...
This sounds great.
What you want basically is that for any build that's meant to create a release:
-Rat should run
-The build should fail if Rat reports any anomalies
-The Rat exclusions should ideally be defined in the same way for all
modules, for consistency
-The Rat exclusions should be commented to indicate why each exclusion
(or family of exclusions) is here
I think this should be documented in a "coding standards" or "release
management" page, does OpenWhisk have this already?
-Bertrand (with my incubation mentor hat on)
Re: Release policy compliance: Adding license headers and the excluded
files
Posted by Ying Chun Guo <gu...@cn.ibm.com>.
Hi, Bertrand
Can you help to answer a specific question to Apache Rat?
For some short JavaScript files, we want to use short form of Apache license header.
But I found Apache Rat cannot recognize short form headers.
Do you know how to handler this situation?
Besides Rat, are there any other tools that can help audit headers in a release?
Best regards
Ying Chun Guo (Daisy)
-----Bertrand Delacretaz <bd...@apache.org> wrote: -----
To: dev@openwhisk.apache.org
From: Bertrand Delacretaz <bd...@apache.org>
Date: 02/09/2018 06:41PM
Subject: Re: Release policy compliance: Adding license headers and the excluded files
Hi Daisy,
On Thu, Feb 8, 2018 at 1:24 PM, Ying Chun Guo <gu...@cn.ibm.com> wrote:
> ...I use Apache Rat to audit license headers. I use wskdeploy repo as the trial repo.
> I reported an issue (https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_apache_incubator-2Dopenwhisk-2Dwskdeploy_issues_716&d=DwIBaQ&c=jf_iaSHvJObTbx-siA1ZOg&r=V_NQebMEsahq0wRsMMLN8VHG-pcqPRpdHygvo4rmK4o&m=m3ygIAacPw2tdx9MhWLfpLzsW1V32RO3z5g6A2YFWCo&s=zY3fWnnLVXjHDVQvYS73Db0ljWoQg4OaYlqNm1mbjWE&e=)
> to wskdeploy including a report generated by Apache Rat. In the report, all the files
> with unapproved licenses will be listed...
This sounds great.
What you want basically is that for any build that's meant to create a release:
-Rat should run
-The build should fail if Rat reports any anomalies
-The Rat exclusions should ideally be defined in the same way for all
modules, for consistency
-The Rat exclusions should be commented to indicate why each exclusion
(or family of exclusions) is here
I think this should be documented in a "coding standards" or "release
management" page, does OpenWhisk have this already?
-Bertrand (with my incubation mentor hat on)
Re: Release policy compliance: Adding license headers and the
excluded files
Posted by Bertrand Delacretaz <bd...@apache.org>.
Hi Daisy,
On Thu, Feb 8, 2018 at 1:24 PM, Ying Chun Guo <gu...@cn.ibm.com> wrote:
> ...I use Apache Rat to audit license headers. I use wskdeploy repo as the trial repo.
> I reported an issue (https://github.com/apache/incubator-openwhisk-wskdeploy/issues/716)
> to wskdeploy including a report generated by Apache Rat. In the report, all the files
> with unapproved licenses will be listed...
This sounds great.
What you want basically is that for any build that's meant to create a release:
-Rat should run
-The build should fail if Rat reports any anomalies
-The Rat exclusions should ideally be defined in the same way for all
modules, for consistency
-The Rat exclusions should be commented to indicate why each exclusion
(or family of exclusions) is here
I think this should be documented in a "coding standards" or "release
management" page, does OpenWhisk have this already?
-Bertrand (with my incubation mentor hat on)