You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by GitBox <gi...@apache.org> on 2020/03/07 16:58:46 UTC
[GitHub] [incubator-doris] WingsGo opened a new pull request #3054: Fix
invalid rollback for stream load txn
WingsGo opened a new pull request #3054: Fix invalid rollback for stream load txn
URL: https://github.com/apache/incubator-doris/pull/3054
For #3053
----------------------------------------------------------------
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
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
[GitHub] [incubator-doris] WingsGo commented on issue #3054: [Bug]Fix
invalid rollback for stream load txn
Posted by GitBox <gi...@apache.org>.
WingsGo commented on issue #3054: [Bug]Fix invalid rollback for stream load txn
URL: https://github.com/apache/incubator-doris/pull/3054#issuecomment-596299092
@morningman I change the `ctx->need_rollback = false` when PUBLISH_TIMEOUT and use clang-format to reformat the file
----------------------------------------------------------------
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
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
[GitHub] [incubator-doris] morningman commented on a change in pull request
#3054: [Bug]Fix invalid rollback for stream load txn
Posted by GitBox <gi...@apache.org>.
morningman commented on a change in pull request #3054: [Bug]Fix invalid rollback for stream load txn
URL: https://github.com/apache/incubator-doris/pull/3054#discussion_r389451034
##########
File path: be/src/runtime/stream_load/stream_load_executor.cpp
##########
@@ -178,19 +180,24 @@ Status StreamLoadExecutor::commit_txn(StreamLoadContext* ctx) {
TLoadTxnCommitResult result;
#ifndef BE_TEST
RETURN_IF_ERROR(ThriftRpcHelper::rpc<FrontendServiceClient>(
- master_addr.hostname, master_addr.port,
- [&request, &result] (FrontendServiceConnection& client) {
- client->loadTxnCommit(result, request);
- }, config::txn_commit_rpc_timeout_ms));
+ master_addr.hostname, master_addr.port,
+ [&request, &result](FrontendServiceConnection& client) {
+ client->loadTxnCommit(result, request);
+ },
+ config::txn_commit_rpc_timeout_ms));
#else
result = k_stream_load_commit_result;
#endif
- // Return if this transaction is committed successful; otherwise, we need try to
+ // Return if this transaction is committed successful; otherwise, we need try
+ // to
// rollback this transaction
Status status(result.status);
- if (!status.ok() && status.code() != TStatusCode::PUBLISH_TIMEOUT) {
+ if (!status.ok()) {
LOG(WARNING) << "commit transaction failed, errmsg=" << status.get_error_msg()
- << ctx->brief();
+ << ctx->brief();
+ if (status.code() != TStatusCode::PUBLISH_TIMEOUT) {
Review comment:
```suggestion
if (status.code() == TStatusCode::PUBLISH_TIMEOUT) {
```
----------------------------------------------------------------
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
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
[GitHub] [incubator-doris] WingsGo commented on a change in pull request
#3054: [Bug]Fix invalid rollback for stream load txn
Posted by GitBox <gi...@apache.org>.
WingsGo commented on a change in pull request #3054: [Bug]Fix invalid rollback for stream load txn
URL: https://github.com/apache/incubator-doris/pull/3054#discussion_r389497385
##########
File path: be/src/runtime/stream_load/stream_load_executor.cpp
##########
@@ -178,19 +180,24 @@ Status StreamLoadExecutor::commit_txn(StreamLoadContext* ctx) {
TLoadTxnCommitResult result;
#ifndef BE_TEST
RETURN_IF_ERROR(ThriftRpcHelper::rpc<FrontendServiceClient>(
- master_addr.hostname, master_addr.port,
- [&request, &result] (FrontendServiceConnection& client) {
- client->loadTxnCommit(result, request);
- }, config::txn_commit_rpc_timeout_ms));
+ master_addr.hostname, master_addr.port,
+ [&request, &result](FrontendServiceConnection& client) {
+ client->loadTxnCommit(result, request);
+ },
+ config::txn_commit_rpc_timeout_ms));
#else
result = k_stream_load_commit_result;
#endif
- // Return if this transaction is committed successful; otherwise, we need try to
+ // Return if this transaction is committed successful; otherwise, we need try
+ // to
// rollback this transaction
Status status(result.status);
- if (!status.ok() && status.code() != TStatusCode::PUBLISH_TIMEOUT) {
+ if (!status.ok()) {
LOG(WARNING) << "commit transaction failed, errmsg=" << status.get_error_msg()
- << ctx->brief();
+ << ctx->brief();
+ if (status.code() != TStatusCode::PUBLISH_TIMEOUT) {
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
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
[GitHub] [incubator-doris] morningman commented on a change in pull request
#3054: [Bug]Fix invalid rollback for stream load txn
Posted by GitBox <gi...@apache.org>.
morningman commented on a change in pull request #3054: [Bug]Fix invalid rollback for stream load txn
URL: https://github.com/apache/incubator-doris/pull/3054#discussion_r389430341
##########
File path: be/src/runtime/stream_load/stream_load_executor.cpp
##########
@@ -188,7 +188,7 @@ Status StreamLoadExecutor::commit_txn(StreamLoadContext* ctx) {
// Return if this transaction is committed successful; otherwise, we need try to
// rollback this transaction
Status status(result.status);
- if (!status.ok()) {
+ if (!status.ok() && status.code() != TStatusCode::PUBLISH_TIMEOUT) {
Review comment:
If you change this code, when FE return PUBLISH_TIMEOUT, here it will just return Status:OK() to the upper caller?
I think we should return PUBLISH_TIMEOUT directly, but set ctx->need_rollback = false to false
----------------------------------------------------------------
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
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org
[GitHub] [incubator-doris] morningman merged pull request #3054: [Bug]Fix
invalid rollback for stream load txn
Posted by GitBox <gi...@apache.org>.
morningman merged pull request #3054: [Bug]Fix invalid rollback for stream load txn
URL: https://github.com/apache/incubator-doris/pull/3054
----------------------------------------------------------------
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
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org