You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@brpc.apache.org by GitBox <gi...@apache.org> on 2021/09/16 11:10:05 UTC

[GitHub] [incubator-brpc] bystorm opened a new issue #1561: 支持UNIX Domain socket

bystorm opened a new issue #1561:
URL: https://github.com/apache/incubator-brpc/issues/1561


   **Is your feature request related to a problem? (你需要的功能是否与某个问题有关?)**
   否
   
   **Describe the solution you'd like (描述你期望的解决方法)**
   支持UNIX domain socket 以更好的支持进程间通信。
   UNIX domain socket采用共享内存技术,在单机中的进程间通信有着更好的性能。
   **Describe alternatives you've considered (描述你想到的折衷方案)**
   
   
   **Additional context/screenshots (更多上下文/截图)**
   
   


-- 
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.

To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org


[GitHub] [incubator-brpc] bystorm commented on issue #1561: 支持UNIX Domain socket

Posted by GitBox <gi...@apache.org>.
bystorm commented on issue #1561:
URL: https://github.com/apache/incubator-brpc/issues/1561#issuecomment-957102561


   客户端的connection_type采用pooled方式,当启动多个客户端进程时,会打印:
   W1102 12:55:20.049485 2285291 src/brpc/socket.cpp:1136] Fail to connect to unix:/etc/local_cache/local_cache.sock: Resource temporarily unavailable
   W1102 12:55:20.049553 2285292 src/brpc/socket.cpp:1136] Fail to connect to unix:/etc/local_cache/local_cache.sock: Resource temporarily unavailable
   W1102 12:55:20.049557 2285291 src/brpc/socket.cpp:1136] Fail to connect to unix:/etc/local_cache/local_cache.sock: Resource temporarily unavailable
   W1102 12:55:20.049775 2285291 src/brpc/socket.cpp:1136] Fail to connect to unix:/etc/local_cache/local_cache.sock: Resource temporarily unavailable
   W1102 12:55:20.049793 2285292 src/brpc/socket.cpp:1136] Fail to connect to unix:/etc/local_cache/local_cache.sock: Resource temporarily unavailable
   W1102 12:55:20.049897 2285292 src/brpc/socket.cpp:1136] Fail to connect to unix:/etc/local_cache/local_cache.sock: Resource temporarily unavailable
   W1102 12:55:20.049926 2285292 src/brpc/socket.cpp:1136] Fail to connect to unix:/etc/local_cache/local_cache.sock: Resource temporarily unavailable
   导致连不上,是不是一个uds的fd有限制。


-- 
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.

To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org


[GitHub] [incubator-brpc] bystorm removed a comment on issue #1561: 支持UNIX Domain socket

Posted by GitBox <gi...@apache.org>.
bystorm removed a comment on issue #1561:
URL: https://github.com/apache/incubator-brpc/issues/1561#issuecomment-957038593






-- 
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.

To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org


[GitHub] [incubator-brpc] bystorm commented on issue #1561: 支持UNIX Domain socket

Posted by GitBox <gi...@apache.org>.
bystorm commented on issue #1561:
URL: https://github.com/apache/incubator-brpc/issues/1561#issuecomment-957038463


   E1102 09:51:59.358552 2258742 src/bthread/task_group.cpp:671] _remote_rq is full, capacity=2048
   E1102 09:52:00.359144 2258732 src/bthread/task_group.cpp:671] _remote_rq is full, capacity=2048
   E1102 09:52:01.359227 2258732 src/bthread/task_group.cpp:671] _remote_rq is full, capacity=2048
   E1102 09:52:02.359358 2258742 src/bthread/task_group.cpp:671] _remote_rq is full, capacity=2048
   E1102 09:52:03.359938 2258732 src/bthread/task_group.cpp:671] _remote_rq is full, capacity=2048
   E1102 09:52:04.360341 2258732 src/bthread/task_group.cpp:671] _remote_rq is full, capacity=2048
   E1102 09:52:05.360597 2258742 src/bthread/task_group.cpp:671] _remote_rq is full, capacity=2048
   E1102 09:52:06.361061 2258742 src/bthread/task_group.cpp:671] _remote_rq is full, capacity=2048
   


-- 
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.

To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org


[GitHub] [incubator-brpc] wwbmmm commented on issue #1561: 支持UNIX Domain socket

Posted by GitBox <gi...@apache.org>.
wwbmmm commented on issue #1561:
URL: https://github.com/apache/incubator-brpc/issues/1561#issuecomment-921405032


   #1560 已经在PR中了


-- 
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.

To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org


[GitHub] [incubator-brpc] bystorm commented on issue #1561: 支持UNIX Domain socket

Posted by GitBox <gi...@apache.org>.
bystorm commented on issue #1561:
URL: https://github.com/apache/incubator-brpc/issues/1561#issuecomment-957038593


   采用异步方式的时候总是出现这个,并且server端没有任何流量。
   


-- 
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.

To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org


[GitHub] [incubator-brpc] wwbmmm commented on issue #1561: 支持UNIX Domain socket

Posted by GitBox <gi...@apache.org>.
wwbmmm commented on issue #1561:
URL: https://github.com/apache/incubator-brpc/issues/1561#issuecomment-1080310733


   已合入master


-- 
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.

To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org


[GitHub] [incubator-brpc] wwbmmm closed issue #1561: 支持UNIX Domain socket

Posted by GitBox <gi...@apache.org>.
wwbmmm closed issue #1561:
URL: https://github.com/apache/incubator-brpc/issues/1561


   


-- 
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.

To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org


[GitHub] [incubator-brpc] wwbmmm commented on issue #1561: 支持UNIX Domain socket

Posted by GitBox <gi...@apache.org>.
wwbmmm commented on issue #1561:
URL: https://github.com/apache/incubator-brpc/issues/1561#issuecomment-938313261


   > 试用了1560提交的那个版本的uds,发现两个问题:1. 如果客户端先启动,服务端后期动,客户端无法连接到服务端。2. 服务端生成sock文件如果不删除,会bind失败。
   
   1. 我试了下,如果客户端先启动,服务端后启动,客户端会在服务端启动3秒后连接到服务端。不知道你具体是怎么操作的?
   2. 可以设置gflag reuse_uds_path=true,这样就会自动删除sock文件


-- 
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.

To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org


[GitHub] [incubator-brpc] bystorm commented on issue #1561: 支持UNIX Domain socket

Posted by GitBox <gi...@apache.org>.
bystorm commented on issue #1561:
URL: https://github.com/apache/incubator-brpc/issues/1561#issuecomment-938413892


   我就是先启动client,然后再启动server。之后就一直连不上了。
   error=[E112]Not connected to unix:local_cache.sock yet, server_id=0 [R1][E112]Not connected to unix:local_cache.sock yet, server_id=0
   我看了example中的确实可以重新连接,连不上的时候错误码不同。
   src/brpc/socket.cpp:1136] Fail to connect to unix:1.sock: Connection refused
   Fail to connect to unix:1.sock: No such file or directory


-- 
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.

To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org


[GitHub] [incubator-brpc] bystorm commented on issue #1561: 支持UNIX Domain socket

Posted by GitBox <gi...@apache.org>.
bystorm commented on issue #1561:
URL: https://github.com/apache/incubator-brpc/issues/1561#issuecomment-938260333


   试用了1560提交的那个版本的uds,发现两个问题:1. 如果客户端先启动,服务端后期动,客户端无法连接到服务端。2. 服务端生成sock文件如果不删除,会bind失败。


-- 
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.

To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org


[GitHub] [incubator-brpc] bystorm commented on issue #1561: 支持UNIX Domain socket

Posted by GitBox <gi...@apache.org>.
bystorm commented on issue #1561:
URL: https://github.com/apache/incubator-brpc/issues/1561#issuecomment-957038463






-- 
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.

To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org


[GitHub] [incubator-brpc] bystorm removed a comment on issue #1561: 支持UNIX Domain socket

Posted by GitBox <gi...@apache.org>.
bystorm removed a comment on issue #1561:
URL: https://github.com/apache/incubator-brpc/issues/1561#issuecomment-957038593






-- 
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.

To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org


[GitHub] [incubator-brpc] bystorm commented on issue #1561: 支持UNIX Domain socket

Posted by GitBox <gi...@apache.org>.
bystorm commented on issue #1561:
URL: https://github.com/apache/incubator-brpc/issues/1561#issuecomment-957038463






-- 
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.

To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org


[GitHub] [incubator-brpc] bystorm removed a comment on issue #1561: 支持UNIX Domain socket

Posted by GitBox <gi...@apache.org>.
bystorm removed a comment on issue #1561:
URL: https://github.com/apache/incubator-brpc/issues/1561#issuecomment-957038593






-- 
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.

To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org


[GitHub] [incubator-brpc] wwbmmm commented on issue #1561: 支持UNIX Domain socket

Posted by GitBox <gi...@apache.org>.
wwbmmm commented on issue #1561:
URL: https://github.com/apache/incubator-brpc/issues/1561#issuecomment-938440415


   > 我就是先启动client,然后再启动server。之后就一直连不上了。 error=[E112]Not connected to unix:local_cache.sock yet, server_id=0 [R1][E112]Not connected to unix:local_cache.sock yet, server_id=0 我看了example中的确实可以重新连接,连不上的时候错误码不同。 src/brpc/socket.cpp:1136] Fail to connect to unix:1.sock: Connection refused Fail to connect to unix:1.sock: No such file or directory
   
   Connection refused的情况应该是sock文件存在,但是没有进程在监听
   No such file or directory的情况是sock文件不存在
   我就是用的example/echo_c++,先启动client,一开始打的是: [E112]Not connected to unix:path.sock yet, server_id=0 [R1][E112]Not connected to unix:path.sock yet, server_id=0 [R2][E112]Not connected to unix:path.sock yet, server_id=0 [R3][E112]Not connected to unix:path.sock yet, server_id=0
   每3秒会探活一次,打印一条:Fail to connect to unix:path.sock: No such file or directory
   再启动server,下一次探活就会出现:Revived Socket{id=0 addr=unix:path.sock} (0x55ecd5810050) (Connectable)
   然后就正常了


-- 
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.

To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org

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



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org