You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@dubbo.apache.org by GitBox <gi...@apache.org> on 2020/11/15 17:09:40 UTC

[GitHub] [dubbo-getty] watermelo opened a new pull request #50: opt: move taskpool at endpoint layer

watermelo opened a new pull request #50:
URL: https://github.com/apache/dubbo-getty/pull/50


   <!--  Thanks for sending a pull request! 
   -->
   
   **What this PR does**:
   
   **Which issue(s) this PR fixes**:
   <!--
   *Automatically closes linked issue when PR is merged.
   Usage: `Fixes #<issue number>`, or `Fixes (paste link of issue)`.
   _If PR is about `failing-tests or flakes`, please post the related issues/tests in a comment and do not use `Fixes`_*
   -->
   Fixes #
   
   **Special notes for your reviewer**:
   
   **Does this PR introduce a user-facing change?**:
   <!--
   If no, just write "NONE" in the release-note block below.
   If yes, a release note is required:
   Enter your extended release note in the block below. If the PR requires additional action from users switching to the new release, include the string "action required".
   -->
   ```release-note
   
   ```


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo-getty] AlexStocks commented on pull request #50: opt: move taskpool at endpoint layer

Posted by GitBox <gi...@apache.org>.
AlexStocks commented on pull request #50:
URL: https://github.com/apache/dubbo-getty/pull/50#issuecomment-735391128


   ![image](https://user-images.githubusercontent.com/7959374/100542718-be9e8b80-3286-11eb-985a-a070d5f344f7.png)
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo-getty] AlexStocks merged pull request #50: opt: move taskpool at endpoint layer

Posted by GitBox <gi...@apache.org>.
AlexStocks merged pull request #50:
URL: https://github.com/apache/dubbo-getty/pull/50


   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo-getty] codecov-io commented on pull request #50: opt: move taskpool at endpoint layer

Posted by GitBox <gi...@apache.org>.
codecov-io commented on pull request #50:
URL: https://github.com/apache/dubbo-getty/pull/50#issuecomment-731769819


   # [Codecov](https://codecov.io/gh/apache/dubbo-getty/pull/50?src=pr&el=h1) Report
   > Merging [#50](https://codecov.io/gh/apache/dubbo-getty/pull/50?src=pr&el=desc) (9ae631e) into [master](https://codecov.io/gh/apache/dubbo-getty/commit/bf36b5d9404cf0309276ba7c9371c270c98fab52?el=desc) (bf36b5d) will **decrease** coverage by `0.21%`.
   > The diff coverage is `12.50%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/dubbo-getty/pull/50/graphs/tree.svg?width=650&height=150&src=pr&token=WDmUsbxiLS)](https://codecov.io/gh/apache/dubbo-getty/pull/50?src=pr&el=tree)
   
   ```diff
   @@            Coverage Diff             @@
   ##           master      #50      +/-   ##
   ==========================================
   - Coverage   66.07%   65.85%   -0.22%     
   ==========================================
     Files           8        8              
     Lines        1350     1356       +6     
   ==========================================
   + Hits          892      893       +1     
   - Misses        365      370       +5     
     Partials       93       93              
   ```
   
   
   | [Impacted Files](https://codecov.io/gh/apache/dubbo-getty/pull/50?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [client.go](https://codecov.io/gh/apache/dubbo-getty/pull/50/diff?src=pr&el=tree#diff-Y2xpZW50Lmdv) | `67.41% <0.00%> (-0.31%)` | :arrow_down: |
   | [options.go](https://codecov.io/gh/apache/dubbo-getty/pull/50/diff?src=pr&el=tree#diff-b3B0aW9ucy5nbw==) | `81.25% <0.00%> (-11.61%)` | :arrow_down: |
   | [session.go](https://codecov.io/gh/apache/dubbo-getty/pull/50/diff?src=pr&el=tree#diff-c2Vzc2lvbi5nbw==) | `65.15% <0.00%> (ø)` | |
   | [server.go](https://codecov.io/gh/apache/dubbo-getty/pull/50/diff?src=pr&el=tree#diff-c2VydmVyLmdv) | `65.86% <100.00%> (+0.13%)` | :arrow_up: |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/dubbo-getty/pull/50?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/dubbo-getty/pull/50?src=pr&el=footer). Last update [bf36b5d...9ae631e](https://codecov.io/gh/apache/dubbo-getty/pull/50?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo-getty] AlexStocks edited a comment on pull request #50: opt: move taskpool at endpoint layer

Posted by GitBox <gi...@apache.org>.
AlexStocks edited a comment on pull request #50:
URL: https://github.com/apache/dubbo-getty/pull/50#issuecomment-735391128


   ![image](https://user-images.githubusercontent.com/7959374/100542718-be9e8b80-3286-11eb-985a-a070d5f344f7.png)
   流程:
   1 退出;
   2 如果 p.work 没有任务,就会阻塞,执行 t;
   3 再次尝试 step2
   4 如果设定的task 数目没有超过, 则新启动一个 goroutine 执行 worker;
   5 所有 work gr 都在忙,自动启动一个临时的 gr
   就是会有 len(p.sem) 个常驻 gr 构成一个 gr pool,gr pool 没有空闲就启动临时 gr。再也没有阻塞的问题了。
   
   而且以往每个session一个gr pool,现在这个 gr pool 变成全局的了。
   
   所以我建议 gr num也就是 sem len,设置长度是 GOMAXPROC * 200。
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo-getty] codecov-io edited a comment on pull request #50: opt: move taskpool at endpoint layer

Posted by GitBox <gi...@apache.org>.
codecov-io edited a comment on pull request #50:
URL: https://github.com/apache/dubbo-getty/pull/50#issuecomment-731769819


   # [Codecov](https://codecov.io/gh/apache/dubbo-getty/pull/50?src=pr&el=h1) Report
   > Merging [#50](https://codecov.io/gh/apache/dubbo-getty/pull/50?src=pr&el=desc) (9ae631e) into [master](https://codecov.io/gh/apache/dubbo-getty/commit/bf36b5d9404cf0309276ba7c9371c270c98fab52?el=desc) (bf36b5d) will **decrease** coverage by `0.21%`.
   > The diff coverage is `12.50%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/dubbo-getty/pull/50/graphs/tree.svg?width=650&height=150&src=pr&token=WDmUsbxiLS)](https://codecov.io/gh/apache/dubbo-getty/pull/50?src=pr&el=tree)
   
   ```diff
   @@            Coverage Diff             @@
   ##           master      #50      +/-   ##
   ==========================================
   - Coverage   66.07%   65.85%   -0.22%     
   ==========================================
     Files           8        8              
     Lines        1350     1356       +6     
   ==========================================
   + Hits          892      893       +1     
   - Misses        365      370       +5     
     Partials       93       93              
   ```
   
   
   | [Impacted Files](https://codecov.io/gh/apache/dubbo-getty/pull/50?src=pr&el=tree) | Coverage Δ | |
   |---|---|---|
   | [client.go](https://codecov.io/gh/apache/dubbo-getty/pull/50/diff?src=pr&el=tree#diff-Y2xpZW50Lmdv) | `67.41% <0.00%> (-0.31%)` | :arrow_down: |
   | [options.go](https://codecov.io/gh/apache/dubbo-getty/pull/50/diff?src=pr&el=tree#diff-b3B0aW9ucy5nbw==) | `81.25% <0.00%> (-11.61%)` | :arrow_down: |
   | [session.go](https://codecov.io/gh/apache/dubbo-getty/pull/50/diff?src=pr&el=tree#diff-c2Vzc2lvbi5nbw==) | `65.15% <0.00%> (ø)` | |
   | [server.go](https://codecov.io/gh/apache/dubbo-getty/pull/50/diff?src=pr&el=tree#diff-c2VydmVyLmdv) | `65.86% <100.00%> (+0.13%)` | :arrow_up: |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/dubbo-getty/pull/50?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/dubbo-getty/pull/50?src=pr&el=footer). Last update [bf36b5d...9ae631e](https://codecov.io/gh/apache/dubbo-getty/pull/50?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo-getty] watermelo commented on a change in pull request #50: opt: move taskpool at endpoint layer

Posted by GitBox <gi...@apache.org>.
watermelo commented on a change in pull request #50:
URL: https://github.com/apache/dubbo-getty/pull/50#discussion_r528356095



##########
File path: server.go
##########
@@ -22,6 +22,7 @@ import (
 	"crypto/tls"
 	"crypto/x509"
 	"fmt"
+	gxsync "github.com/dubbogo/gost/sync"

Review comment:
       done




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo-getty] wongoo commented on pull request #50: opt: move taskpool at endpoint layer

Posted by GitBox <gi...@apache.org>.
wongoo commented on pull request #50:
URL: https://github.com/apache/dubbo-getty/pull/50#issuecomment-728561570


   using `go mod tidy` to remove unused lib version in go.sum


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo-getty] AlexStocks edited a comment on pull request #50: opt: move taskpool at endpoint layer

Posted by GitBox <gi...@apache.org>.
AlexStocks edited a comment on pull request #50:
URL: https://github.com/apache/dubbo-getty/pull/50#issuecomment-735391128


   ![image](https://user-images.githubusercontent.com/7959374/100542718-be9e8b80-3286-11eb-985a-a070d5f344f7.png)
   1 退出;
   2 如果 p.work 没有任务,就会阻塞,执行 t;
   3 再次尝试 step2
   4 如果设定的task 数目没有超过, 则新启动一个 goroutine 执行 worker;
   5 所有 work gr 都在忙,自动启动一个临时的 gr


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo-getty] AlexStocks commented on a change in pull request #50: opt: move taskpool at endpoint layer

Posted by GitBox <gi...@apache.org>.
AlexStocks commented on a change in pull request #50:
URL: https://github.com/apache/dubbo-getty/pull/50#discussion_r524883675



##########
File path: server.go
##########
@@ -22,6 +22,7 @@ import (
 	"crypto/tls"
 	"crypto/x509"
 	"fmt"
+	gxsync "github.com/dubbogo/gost/sync"

Review comment:
       move out to 3rd import block.




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org


[GitHub] [dubbo-getty] watermelo commented on pull request #50: opt: move taskpool at endpoint layer

Posted by GitBox <gi...@apache.org>.
watermelo commented on pull request #50:
URL: https://github.com/apache/dubbo-getty/pull/50#issuecomment-731770082


   > using `go mod tidy` to remove unused lib version in go.sum
   
   done


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org