You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@dolphinscheduler.apache.org by Jave-Chen <ke...@foxmail.com> on 2020/01/01 07:43:18 UTC

回复: [discussion] The SonarCloud check in the CI flow

I noticed sonarcloud didn't get the right&nbsp; UT coverage and create PR #1662 to fix it.&nbsp;https://github.com/apache/incubator-dolphinscheduler/pull/1662


And updated&nbsp;maven command&nbsp;as below&nbsp;
mvn clean --batch-mode verify org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.1.1688:sonar&nbsp; -Dsonar.host.url=https://sonarcloud.io -Dsonar.organization=${org} -Dsonar.projectKey=${pKey} -Dsonar.login=${token}-Dmaven.test.skip=true can be appended to skip tests, it will get 0% UT coverage, but will cost less time on local testing .


For now, Sonarcloud&nbsp; just analysis Java source file. There are still need some work to get fronted code be analyzed. When the work is done, I will infrom it.


------------------&nbsp;原始邮件&nbsp;------------------
发件人:&nbsp;"nauu"<boness@qq.com&gt;;
发送时间:&nbsp;2020年1月1日(星期三) 凌晨0:04
收件人:&nbsp;"dev@dolphinscheduler.apache.org"<dev@dolphinscheduler.apache.org&gt;;

主题:&nbsp;Re: [discussion] The SonarCloud check in the CI flow



Thanks for your reply, this is normal discussion, no need to apologize.

I will try the test way in local environment , if there is any problem, i will continue to follow up in this mail.

However, I still feel that the method of local testing is too complicated. Such as UT coverage , checkstyle and spotbugs,&nbsp; If the rules are clear, these checks are easy to do in the IDE.

BTW, I said causeing merge to slow do not means we should not use SonarCloud. SonarCloud is very useful.
But If the rules are clear, and there is a way for local testing, we can get everything right before pull request, instead of trying.



boness@qq.com
zhukai/nauu ygsoft




&gt; On Dec 31, 2019, at 11:37 PM, 陈克佳 <kejia.chen@foxmail.com&gt; wrote:
&gt; 
&gt; Sorry for your confuse 
&gt; 
&gt; 1. SonarCloud's test standards
&gt; For now , SonarCloud use the default Quality Gate analysis new code. if one of these conditions is true, Quality Gate will failed .
&gt; 
&gt; For SonarCloud's testing standards, You can check here :
&gt; https://sonarcloud.io/organizations/apache/quality_gates/show/9
&gt; 
&gt; More metric definitions:
&gt; https://sonarcloud.io/documentation/user-guide/metric-definitions/
&gt; 
&gt; 2.&nbsp; Test in a local development environment
&gt; Use&nbsp; maven&nbsp; command will be a easy way , there&nbsp; 2 steps:
&gt; 1) Sign up at https://sonarcloud.io/ <https://sonarcloud.io/&gt; , set up organization, projectKey, and token
&gt; 2) Run maven command locally , remember replace the variable as you set up at step 1)
&gt; mvn clean --batch-mode verify org.sonarsource.scanner.maven:sonar-maven-plugin:sonar -Dsonar.host.url=https://sonarcloud.io -Dsonar.organization=${org} -Dsonar.projectKey=${pKey} -Dsonar.login=${token}
&gt; Then your can browse analysis&nbsp; at SonarCloud.
&gt; 
&gt; 3. Cause merge to slow
&gt;&nbsp; Adding SonarCloud check in the CI workflow means developers need spend more time on code implementation&nbsp; stage ,but less on testing and debuging. I think it's worthy .
&gt; 
&gt; 
&gt; ------------------ Original ------------------
&gt; From: "nauu"<boness@qq.com&gt;;
&gt; Date: Tue, Dec 31, 2019 10:36 PM
&gt; To: "dev@dolphinscheduler.apache.org"<dev@dolphinscheduler.apache.org&gt;;
&gt; Subject: [discussion] The SonarCloud check in the CI flow
&gt; 
&gt; Hi :
&gt; 
&gt; I'd like to discuss the SonarCloud check in the CI flow, It makes me a little confused.
&gt; 
&gt; Before this, we have a very clear goal in our project:
&gt; The root issue #1460,&nbsp; It defines the overall goal and break into subtasks. Such as [Add unit test] #1465, It defines which unit tests should we write and what is the coverage ratio.
&gt; 
&gt; But now,&nbsp; SonarCloud suddenly added in without discussion in the community(dev maillist).It is obviously unstable,&nbsp; and causing the progress of the merge to slow.
&gt; 
&gt; I'm not quite sure what is the SonarCloud's testing standards, what is our goals, and how to test in a local development environment.
&gt; 
&gt; 
&gt; boness@qq.com
&gt; zhukai/nauu ygsoft
&gt; 
&gt; 
&gt; 
&gt; 
&gt;

Re: [discussion] The SonarCloud check in the CI flow

Posted by lidong dai <da...@gmail.com>.
good job, very glad to hear this message.



Best Regards
---------------
DolphinScheduler(Incubator) PPMC
Lidong Dai 代立冬
dailidong66@gmail.com
---------------


Java-Chen <ke...@foxmail.com> 于2020年1月6日周一 下午1:31写道:

> Hi, all
> After PR 1707 was merged, Sonarcloud now analyze fronted code.
> https://github.com/apache/incubator-dolphinscheduler/pull/1707
>
> You can open https://sonarcloud.io/dashboard?id=apache-dolphinscheduler for
> more details. There is still much work to do, any contributions are welcome.
>
> ------------------ 原始邮件 ------------------
> *发件人:* "Java-Chen"<ke...@foxmail.com>;
> *发送时间:* 2020年1月1日(星期三) 下午3:43
> *收件人:* "dev"<de...@dolphinscheduler.apache.org>;
> *主题:* 回复: [discussion] The SonarCloud check in the CI flow
>
> I noticed sonarcloud didn't get the right UT coverage and create PR #1662
> to fix it.&nbsp;
> https://github.com/apache/incubator-dolphinscheduler/pull/1662
>
>
> And updated maven command&nbsp;as below
> mvn clean --batch-mode verify
> org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.1.1688:sonar&nbsp;
> -Dsonar.host.url=https://sonarcloud.io -Dsonar.organization=${org}
> -Dsonar.projectKey=${pKey} -Dsonar.login=${token}-Dmaven.test.skip=true can
> be appended to skip tests, it will get 0% UT coverage, but will cost less
> time on local testing .
>
>
> For now, Sonarcloud just analysis Java source file. There are still need
> some work to get fronted code be analyzed. When the work is done, I will
> infrom it.
>
>
> ------------------&nbsp;原始邮件&nbsp;------------------
> 发件人:&nbsp;"nauu"<boness@qq.com&gt;;
> 发送时间:&nbsp;2020年1月1日(星期三) 凌晨0:04
> 收件人:&nbsp;"dev@dolphinscheduler.apache.org"<
> dev@dolphinscheduler.apache.org&gt;;
>
> 主题:&nbsp;Re: [discussion] The SonarCloud check in the CI flow
>
>
>
> Thanks for your reply, this is normal discussion, no need to apologize.
>
> I will try the test way in local environment , if there is any problem, i
> will continue to follow up in this mail.
>
> However, I still feel that the method of local testing is too complicated.
> Such as UT coverage , checkstyle and spotbugs,&nbsp; If the rules are
> clear, these checks are easy to do in the IDE.
>
> BTW, I said causeing merge to slow do not means we should not use
> SonarCloud. SonarCloud is very useful.
> But If the rules are clear, and there is a way for local testing, we can
> get everything right before pull request, instead of trying.
>
>
>
> boness@qq.com
> zhukai/nauu ygsoft
>
>
>
>
> &gt; On Dec 31, 2019, at 11:37 PM, 陈克佳 <kejia.chen@foxmail.com&gt; wrote:
> &gt;
> &gt; Sorry for your confuse
> &gt;
> &gt; 1. SonarCloud's test standards
> &gt; For now , SonarCloud use the default Quality Gate analysis new code.
> if one of these conditions is true, Quality Gate will failed .
> &gt;
> &gt; For SonarCloud's testing standards, You can check here :
> &gt; https://sonarcloud.io/organizations/apache/quality_gates/show/9
> &gt;
> &gt; More metric definitions:
> &gt; https://sonarcloud.io/documentation/user-guide/metric-definitions/
> &gt;
> &gt; 2.&nbsp; Test in a local development environment
> &gt; Use&nbsp; maven&nbsp; command will be a easy way , there&nbsp; 2
> steps:
> &gt; 1) Sign up at https://sonarcloud.io/ <https://sonarcloud.io/&gt; ,
> set up organization, projectKey, and token
> &gt; 2) Run maven command locally , remember replace the variable as you
> set up at step 1)
> &gt; mvn clean --batch-mode verify
> org.sonarsource.scanner.maven:sonar-maven-plugin:sonar -Dsonar.host.url=
> https://sonarcloud.io -Dsonar.organization=${org}
> -Dsonar.projectKey=${pKey} -Dsonar.login=${token}
> &gt; Then your can browse analysis&nbsp; at SonarCloud.
> &gt;
> &gt; 3. Cause merge to slow
> &gt;&nbsp; Adding SonarCloud check in the CI workflow means developers
> need spend more time on code implementation&nbsp; stage ,but less on
> testing and debuging. I think it's worthy .
> &gt;
> &gt;
> &gt; ------------------ Original ------------------
> &gt; From: "nauu"<boness@qq.com&gt;;
> &gt; Date: Tue, Dec 31, 2019 10:36 PM
> &gt; To: "dev@dolphinscheduler.apache.org"<dev@dolphinscheduler.apache.org
> &gt;;
> &gt; Subject: [discussion] The SonarCloud check in the CI flow
> &gt;
> &gt; Hi :
> &gt;
> &gt; I'd like to discuss the SonarCloud check in the CI flow, It makes me
> a little confused.
> &gt;
> &gt; Before this, we have a very clear goal in our project:
> &gt; The root issue #1460,&nbsp; It defines the overall goal and break
> into subtasks. Such as [Add unit test] #1465, It defines which unit tests
> should we write and what is the coverage ratio.
> &gt;
> &gt; But now,&nbsp; SonarCloud suddenly added in without discussion in the
> community(dev maillist).It is obviously unstable,&nbsp; and causing the
> progress of the merge to slow.
> &gt;
> &gt; I'm not quite sure what is the SonarCloud's testing standards, what
> is our goals, and how to test in a local development environment.
> &gt;
> &gt;
> &gt; boness@qq.com
> &gt; zhukai/nauu ygsoft
> &gt;
> &gt;
> &gt;
> &gt;
> &gt;
>

re: [discussion] The SonarCloud check in the CI flow

Posted by Java-Chen <ke...@foxmail.com>.
Hi, all
After PR 1707 was merged, Sonarcloud now analyze fronted code.
https://github.com/apache/incubator-dolphinscheduler/pull/1707


You can open&nbsp;https://sonarcloud.io/dashboard?id=apache-dolphinscheduler&nbsp;for more details. There is still much work to do, any contributions are welcome.



------------------&nbsp;原始邮件&nbsp;------------------
发件人:&nbsp;"Java-Chen"<kejia.chen@foxmail.com&gt;;
发送时间:&nbsp;2020年1月1日(星期三) 下午3:43
收件人:&nbsp;"dev"<dev@dolphinscheduler.apache.org&gt;;

主题:&nbsp;回复: [discussion] The SonarCloud check in the CI flow



I noticed sonarcloud didn't get the right UT coverage and create PR #1662 to fix it.&amp;nbsp;https://github.com/apache/incubator-dolphinscheduler/pull/1662


And updated maven command&amp;nbsp;as below
mvn clean --batch-mode verify org.sonarsource.scanner.maven:sonar-maven-plugin:3.6.1.1688:sonar&amp;nbsp; -Dsonar.host.url=https://sonarcloud.io -Dsonar.organization=${org} -Dsonar.projectKey=${pKey} -Dsonar.login=${token}-Dmaven.test.skip=true can be appended to skip tests, it will get 0% UT coverage, but will cost less time on local testing .


For now, Sonarcloud just analysis Java source file. There are still need some work to get fronted code be analyzed. When the work is done, I will infrom it.


------------------&amp;nbsp;原始邮件&amp;nbsp;------------------
发件人:&amp;nbsp;"nauu"<boness@qq.com&amp;gt;;
发送时间:&amp;nbsp;2020年1月1日(星期三) 凌晨0:04
收件人:&amp;nbsp;"dev@dolphinscheduler.apache.org"<dev@dolphinscheduler.apache.org&amp;gt;;

主题:&amp;nbsp;Re: [discussion] The SonarCloud check in the CI flow



Thanks for your reply, this is normal discussion, no need to apologize.

I will try the test way in local environment , if there is any problem, i will continue to follow up in this mail.

However, I still feel that the method of local testing is too complicated. Such as UT coverage , checkstyle and spotbugs,&amp;nbsp; If the rules are clear, these checks are easy to do in the IDE.

BTW, I said causeing merge to slow do not means we should not use SonarCloud. SonarCloud is very useful.
But If the rules are clear, and there is a way for local testing, we can get everything right before pull request, instead of trying.



boness@qq.com
zhukai/nauu ygsoft




&amp;gt; On Dec 31, 2019, at 11:37 PM, 陈克佳 <kejia.chen@foxmail.com&amp;gt; wrote:
&amp;gt; 
&amp;gt; Sorry for your confuse 
&amp;gt; 
&amp;gt; 1. SonarCloud's test standards
&amp;gt; For now , SonarCloud use the default Quality Gate analysis new code. if one of these conditions is true, Quality Gate will failed .
&amp;gt; 
&amp;gt; For SonarCloud's testing standards, You can check here :
&amp;gt; https://sonarcloud.io/organizations/apache/quality_gates/show/9
&amp;gt; 
&amp;gt; More metric definitions:
&amp;gt; https://sonarcloud.io/documentation/user-guide/metric-definitions/
&amp;gt; 
&amp;gt; 2.&amp;nbsp; Test in a local development environment
&amp;gt; Use&amp;nbsp; maven&amp;nbsp; command will be a easy way , there&amp;nbsp; 2 steps:
&amp;gt; 1) Sign up at https://sonarcloud.io/ <https://sonarcloud.io/&amp;gt; , set up organization, projectKey, and token
&amp;gt; 2) Run maven command locally , remember replace the variable as you set up at step 1)
&amp;gt; mvn clean --batch-mode verify org.sonarsource.scanner.maven:sonar-maven-plugin:sonar -Dsonar.host.url=https://sonarcloud.io -Dsonar.organization=${org} -Dsonar.projectKey=${pKey} -Dsonar.login=${token}
&amp;gt; Then your can browse analysis&amp;nbsp; at SonarCloud.
&amp;gt; 
&amp;gt; 3. Cause merge to slow
&amp;gt;&amp;nbsp; Adding SonarCloud check in the CI workflow means developers need spend more time on code implementation&amp;nbsp; stage ,but less on testing and debuging. I think it's worthy .
&amp;gt; 
&amp;gt; 
&amp;gt; ------------------ Original ------------------
&amp;gt; From: "nauu"<boness@qq.com&amp;gt;;
&amp;gt; Date: Tue, Dec 31, 2019 10:36 PM
&amp;gt; To: "dev@dolphinscheduler.apache.org"<dev@dolphinscheduler.apache.org&amp;gt;;
&amp;gt; Subject: [discussion] The SonarCloud check in the CI flow
&amp;gt; 
&amp;gt; Hi :
&amp;gt; 
&amp;gt; I'd like to discuss the SonarCloud check in the CI flow, It makes me a little confused.
&amp;gt; 
&amp;gt; Before this, we have a very clear goal in our project:
&amp;gt; The root issue #1460,&amp;nbsp; It defines the overall goal and break into subtasks. Such as [Add unit test] #1465, It defines which unit tests should we write and what is the coverage ratio.
&amp;gt; 
&amp;gt; But now,&amp;nbsp; SonarCloud suddenly added in without discussion in the community(dev maillist).It is obviously unstable,&amp;nbsp; and causing the progress of the merge to slow.
&amp;gt; 
&amp;gt; I'm not quite sure what is the SonarCloud's testing standards, what is our goals, and how to test in a local development environment.
&amp;gt; 
&amp;gt; 
&amp;gt; boness@qq.com
&amp;gt; zhukai/nauu ygsoft
&amp;gt; 
&amp;gt; 
&amp;gt; 
&amp;gt; 
&amp;gt;