[GitHub] [incubator-brpc] co0l1ce opened a new pull request, #2076: Rollback #2049 chang

2023-01-08 Thread GitBox


co0l1ce opened a new pull request, #2076:
URL: https://github.com/apache/incubator-brpc/pull/2076

   ### What problem does this PR solve?
   Chang in #2049 has same problem for a different Link order(. brpc -> 
pthread), will can't find symbol and exit, so rollback, the Origin implement 
need we link brpc befor pthread, we can use ldd binary to check it
   
   Issue Number:
   #2049 
   
   Problem Summary:
   the fix is not perfect
   
   ### What is changed and the side effects?
   
   Changed:rollback to origin implement
   
   Side effects:
   - Performance effects(性能影响):no effects
   
   - Breaking backward compatibility(向后兼容性):compatibility
   
   ---
   ### Check List:
   - Please make sure your changes are compilable(请确保你的更改可以通过编译).
   - When providing us with a new feature, it is best to add related 
tests(如果你向我们增加一个新的功能, 请添加相关测试).
   - Please follow [Contributor Covenant Code of 
Conduct](../../master/CODE_OF_CONDUCT.md).(请遵循贡献者准则).
   


-- 
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-unsubscr...@brpc.apache.org

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


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



[incubator-brpc] branch master updated: fix some typos (#2075)

2023-01-08 Thread wwbmmm
This is an automated email from the ASF dual-hosted git repository.

wwbmmm pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-brpc.git


The following commit(s) were added to refs/heads/master by this push:
 new 606fb7b1 fix some typos (#2075)
606fb7b1 is described below

commit 606fb7b1e2bdf8cd57cd626c30489620767c6b85
Author: Bright Chen <1021774...@qq.com>
AuthorDate: Mon Jan 9 10:53:34 2023 +0800

fix some typos (#2075)
---
 src/brpc/details/mesalink_ssl_helper.cpp | 2 +-
 src/brpc/details/ssl_helper.cpp  | 2 +-
 src/brpc/server.cpp  | 2 +-
 src/brpc/server.h| 2 +-
 src/brpc/socket.cpp  | 4 ++--
 5 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/src/brpc/details/mesalink_ssl_helper.cpp 
b/src/brpc/details/mesalink_ssl_helper.cpp
index 96b9cf5d..afc38613 100644
--- a/src/brpc/details/mesalink_ssl_helper.cpp
+++ b/src/brpc/details/mesalink_ssl_helper.cpp
@@ -208,7 +208,7 @@ static int LoadCertificate(SSL_CTX* ctx,
 return -1;
 }
 
-// Load the main certficate
+// Load the main certificate
 if (SSL_CTX_use_certificate(ctx, x.get()) != 1) {
 LOG(ERROR) << "Fail to load " << certificate << ": "
<< SSLError(ERR_get_error());
diff --git a/src/brpc/details/ssl_helper.cpp b/src/brpc/details/ssl_helper.cpp
index effba37e..76a73547 100644
--- a/src/brpc/details/ssl_helper.cpp
+++ b/src/brpc/details/ssl_helper.cpp
@@ -320,7 +320,7 @@ static int LoadCertificate(SSL_CTX* ctx,
 return -1;
 }
 
-// Load the main certficate
+// Load the main certificate
 if (SSL_CTX_use_certificate(ctx, x.get()) != 1) {
 LOG(ERROR) << "Fail to load " << certificate << ": "
<< SSLError(ERR_get_error());
diff --git a/src/brpc/server.cpp b/src/brpc/server.cpp
index 15c835b2..2087cbcf 100644
--- a/src/brpc/server.cpp
+++ b/src/brpc/server.cpp
@@ -2019,7 +2019,7 @@ int Server::ResetCertificates(const 
std::vector& certs) {
 return -1;
 }
 
-// Add default certficiate into tmp_map first since it can't be reloaded
+// Add default certificate into tmp_map first since it can't be reloaded
 std::string default_cert_key =
 _options.ssl_options().default_cert.certificate
 + _options.ssl_options().default_cert.private_key;
diff --git a/src/brpc/server.h b/src/brpc/server.h
index 31ffc05b..0974ce12 100644
--- a/src/brpc/server.h
+++ b/src/brpc/server.h
@@ -623,7 +623,7 @@ friend class Controller;
 std::shared_ptr ctx;
 std::vector filters;
 };
-// Mapping from [certficate + private-key] to SSLContext
+// Mapping from [certificate + private-key] to SSLContext
 typedef butil::FlatMap SSLContextMap;
 
 void FreeSSLContexts();
diff --git a/src/brpc/socket.cpp b/src/brpc/socket.cpp
index b4dc734e..e3878c19 100644
--- a/src/brpc/socket.cpp
+++ b/src/brpc/socket.cpp
@@ -1095,7 +1095,7 @@ void* Socket::ProcessEvent(void* arg) {
 }
 
 // Check if there're new requests appended.
-// If yes, point old_head to to reversed new requests and return false;
+// If yes, point old_head to reversed new requests and return false;
 // If no:
 //old_head is fully written, set _write_head to NULL and return true;
 //old_head is not written yet, keep _write_head unchanged and return false;
@@ -1147,7 +1147,7 @@ bool Socket::IsWriteComplete(Socket::WriteRequest* 
old_head,
 old_head->next = tail;
 // Call Setup() from oldest to newest, notice that the calling sequence
 // matters for protocols using pipelined_count, this is why we don't
-// calling Setup in above loop which is from newest to oldest.
+// call Setup in above loop which is from newest to oldest.
 for (WriteRequest* q = tail; q; q = q->next) {
 q->Setup(this);
 }


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



[GitHub] [incubator-brpc] wwbmmm merged pull request #2075: fix some typos

2023-01-08 Thread GitBox


wwbmmm merged PR #2075:
URL: https://github.com/apache/incubator-brpc/pull/2075


-- 
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-unsubscr...@brpc.apache.org

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


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



[GitHub] [incubator-brpc] TousakaRin commented on issue #2051: 应用层如何感知连接的断开和重连

2023-01-08 Thread GitBox


TousakaRin commented on issue #2051:
URL: 
https://github.com/apache/incubator-brpc/issues/2051#issuecomment-1375042065

   @yongxiangzheng  
还有一个比较tricky的方法,把你的要推送的信息作为Authentication信息,brpc在连接建立之后,第一个message会带上Authentication信息,服务端会调用VerifyCredential去验证,这个方法可以在连接建立的时候插入回调。接口在[这里](https://github.com/apache/incubator-brpc/blob/60159fc3f3e13490fb9806ea0a0cb0dcdbda7f7d/src/brpc/authenticator.h),继承这个类之后,将对象插入到channel和server的options里。


-- 
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-unsubscr...@brpc.apache.org

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


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



[GitHub] [incubator-brpc] Tuvie commented on issue #2073: 关于append_user_data中使用引用计数内存的问题

2023-01-08 Thread GitBox


Tuvie commented on issue #2073:
URL: 
https://github.com/apache/incubator-brpc/issues/2073#issuecomment-1375016238

   目前IOBuf还不支持帮外部内存做引用技术


-- 
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-unsubscr...@brpc.apache.org

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


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



[GitHub] [incubator-brpc] chenBright opened a new pull request, #2075: fix some typos

2023-01-08 Thread GitBox


chenBright opened a new pull request, #2075:
URL: https://github.com/apache/incubator-brpc/pull/2075

   ### What problem does this PR solve?
   
   Issue Number:
   
   Problem Summary:
   
   ### What is changed and the side effects?
   
   Changed:
   
   Side effects:
   - Performance effects(性能影响):
   
   - Breaking backward compatibility(向后兼容性): 
   
   ---
   ### Check List:
   - Please make sure your changes are compilable(请确保你的更改可以通过编译).
   - When providing us with a new feature, it is best to add related 
tests(如果你向我们增加一个新的功能, 请添加相关测试).
   - Please follow [Contributor Covenant Code of 
Conduct](../../master/CODE_OF_CONDUCT.md).(请遵循贡献者准则).
   


-- 
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-unsubscr...@brpc.apache.org

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


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



[GitHub] [incubator-brpc] xiaoyuxee opened a new issue, #2074: 客户端请求比较耗时的case 时,rpc E1010错误,500 Internal Server

2023-01-08 Thread GitBox


xiaoyuxee opened a new issue, #2074:
URL: https://github.com/apache/incubator-brpc/issues/2074

   **Describe the bug (描述bug)**
   server 端响应时间超过一定阈值时,client 收到 rpc 错误:E1010。如果请求server 端处理时间较少的case,client 端 
则可以接受到正常响应。
   
   rpc 错误时,client 端 controller 错误信息如下:
   ```
   E20230108 17:38:30.313141 ... code[1010] timeout[-1] latency_us[149377] 
err[[E1010]1/1 channels failed, fail_limit=1 
   [C0][E1010]HTTP/2.0 500 Internal Server Error]
   ```
   
   此时服务端业务处理逻辑正常,日志如下:
   ```
   INFO 2023-01-08 17:38:30 140677572634368 Received query: ...
   INFO 2023-01-08 17:38:30 140677572634368 Handle success. rt[137044us]
   ```
   
   client 端信息如下:
   - ParallelChannel 中包含多个 SelectiveChannel,用于并行调用 SelectiveChannel 中某个 server
   - protocol = "h2:grpc"
   - SelectiveChannel `timeout_ms`、`connect_timeout_ms` 均为 -1
   
   **To Reproduce (复现方法)**
   增加 server 端业务处理时长,client 将获取到 rpc 错误
   
   **Expected behavior (期望行为)**
   
   
   **Versions (各种版本)**
   OS: 
   Compiler: 4.9.2
   brpc: 0.9.7
   protobuf: 3.11.4
   
   **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-unsubscr...@brpc.apache.org.apache.org

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


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



[GitHub] [incubator-brpc] luliyucoordinate opened a new issue, #2073: 关于append_user_data数据的生命周期问题

2023-01-08 Thread GitBox


luliyucoordinate opened a new issue, #2073:
URL: https://github.com/apache/incubator-brpc/issues/2073

   
我看到现有iobuf里面如果想要使用一个申请好的内存可以使用append_user_data,这个方法需要传入一个delete的析构(是一个`void(void*)`函数,传入raw数据地址)。
   
   
如果申请好的内存是一个引用计数管理的内存,也就是需要append_user_data需要支持引用计数管理的内存,这个现有的代码中有办法实现吗?还是说需要修改原来iobuf的逻辑,将delete改为支持可以传入对象地址的一个function呢?


-- 
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-unsubscr...@brpc.apache.org.apache.org

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


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



[GitHub] [incubator-brpc-website] dependabot[bot] opened a new pull request, #124: Bump json5 from 1.0.1 to 1.0.2

2023-01-08 Thread GitBox


dependabot[bot] opened a new pull request, #124:
URL: https://github.com/apache/incubator-brpc-website/pull/124

   Bumps [json5](https://github.com/json5/json5) from 1.0.1 to 1.0.2.
   
   Release notes
   Sourced from https://github.com/json5/json5/releases;>json5's releases.
   
   v1.0.2
   
   Fix: Properties with the name __proto__ are added to 
objects and arrays. (https://github-redirect.dependabot.com/json5/json5/issues/199;>#199) 
This also fixes a prototype pollution vulnerability reported by Jonathan 
Gregson! (https://github-redirect.dependabot.com/json5/json5/issues/295;>#295). 
This has been backported to v1. (https://github-redirect.dependabot.com/json5/json5/issues/298;>#298)
   
   
   
   
   Changelog
   Sourced from https://github.com/json5/json5/blob/main/CHANGELOG.md;>json5's 
changelog.
   
   Unreleased [https://github.com/json5/json5/tree/main;>code, 
https://github.com/json5/json5/compare/v2.2.3...HEAD;>diff]
   v2.2.3 [https://github.com/json5/json5/tree/v2.2.3;>code, 
https://github.com/json5/json5/compare/v2.2.2...v2.2.3;>diff]
   
   Fix: json5@2.2.3 is now the 'latest' release according to npm instead of
   v1.0.2. (https://github-redirect.dependabot.com/json5/json5/issues/299;>#299)
   
   v2.2.2 [https://github.com/json5/json5/tree/v2.2.2;>code, 
https://github.com/json5/json5/compare/v2.2.1...v2.2.2;>diff]
   
   Fix: Properties with the name __proto__ are added to 
objects and arrays.
   (https://github-redirect.dependabot.com/json5/json5/issues/199;>#199) 
This also fixes a prototype pollution vulnerability reported by
   Jonathan Gregson! (https://github-redirect.dependabot.com/json5/json5/issues/295;>#295).
   
   v2.2.1 [https://github.com/json5/json5/tree/v2.2.1;>code, 
https://github.com/json5/json5/compare/v2.2.0...v2.2.1;>diff]
   
   Fix: Removed dependence on minimist to patch CVE-2021-44906. (https://github-redirect.dependabot.com/json5/json5/issues/266;>#266)
   
   v2.2.0 [https://github.com/json5/json5/tree/v2.2.0;>code, 
https://github.com/json5/json5/compare/v2.1.3...v2.2.0;>diff]
   
   New: Accurate and documented TypeScript declarations are now included. 
There
   is no need to install @types/json5. (https://github-redirect.dependabot.com/json5/json5/issues/236;>#236, 
https://github-redirect.dependabot.com/json5/json5/issues/244;>#244)
   
   v2.1.3 [https://github.com/json5/json5/tree/v2.1.3;>code, 
https://github.com/json5/json5/compare/v2.1.2...v2.1.3;>diff]
   
   Fix: An out of memory bug when parsing numbers has been fixed. (https://github-redirect.dependabot.com/json5/json5/issues/228;>#228,
   https://github-redirect.dependabot.com/json5/json5/issues/229;>#229)
   
   v2.1.2 [https://github.com/json5/json5/tree/v2.1.2;>code, 
https://github.com/json5/json5/compare/v2.1.1...v2.1.2;>diff]
   
   
   ... (truncated)
   
   
   Commits
   
   https://github.com/json5/json5/commit/a62db1e51e1031d92ac260f5bb38bbed1fdbc754;>a62db1e
 1.0.2
   https://github.com/json5/json5/commit/e0c23fe458a77c0b2cdb271376be5d8d0908133c;>e0c23fe
 docs: update CHANGELOG for v1.0.2
   https://github.com/json5/json5/commit/62a65408408d40aeea14c7869ed327acead12972;>62a6540
 fix: add proto to objects and arrays
   See full diff in https://github.com/json5/json5/compare/v1.0.1...v1.0.2;>compare 
view
   
   
   
   
   
   [![Dependabot compatibility 
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=json5=npm_and_yarn=1.0.1=1.0.2)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)
   
   Dependabot will resolve any conflicts with this PR as long as you don't 
alter it yourself. You can also trigger a rebase manually by commenting 
`@dependabot rebase`.
   
   [//]: # (dependabot-automerge-start)
   [//]: # (dependabot-automerge-end)
   
   ---
   
   
   Dependabot commands and options
   
   
   You can trigger Dependabot actions by commenting on this PR:
   - `@dependabot rebase` will rebase this PR
   - `@dependabot recreate` will recreate this PR, overwriting any edits that 
have been made to it
   - `@dependabot merge` will merge this PR after your CI passes on it
   - `@dependabot squash and merge` will squash and merge this PR after your CI 
passes on it
   - `@dependabot cancel merge` will cancel a previously requested merge and 
block automerging
   - `@dependabot reopen` will reopen this PR if it is closed
   - `@dependabot close` will close this PR and stop Dependabot recreating it. 
You can achieve the same result by closing it manually
   - `@dependabot ignore this major version` will close this PR and stop 
Dependabot creating any more for this major version (unless you reopen the PR 
or upgrade to it yourself)
   - `@dependabot ignore this minor version` will close this PR and stop 
Dependabot creating any more for this minor version (unless you reopen the PR 
or upgrade to it yourself)
   - `@dependabot ignore this dependency` will