Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

A large number of traces are in a pending state? #94

Open
wangxiaojia-wxj opened this issue Dec 5, 2024 · 2 comments
Open

A large number of traces are in a pending state? #94

wangxiaojia-wxj opened this issue Dec 5, 2024 · 2 comments

Comments

@wangxiaojia-wxj
Copy link

A large number of traces are in a pending state, but they have indeed been completed

Pending traces: 329966 Pending edges: 1543 Broken traces: 429

For example, one of them:trace_id='ycqOqX6papQ/CXrFY2Mu7ukytoFhExbz/PxhnNAIb9c='

@wangxiaojia-wxj
Copy link
Author

For example, one of them:trace_id='ycqOqX6papQ/CXrFY2Mu7ukytoFhExbz/PxhnNAIb9c='
{
"trace_id": "ycqOqX6papQ/CXrFY2Mu7ukytoFhExbz/PxhnNAIb9c=",
"external_hash": "0ioaUAVoZqChAO0aHZMhfmWK96OoWICtlVIh/GJwXIU=",
"mc_seqno_start": "42339034",
"mc_seqno_end": "42339037",
"start_lt": "51239066000003",
"start_utime": 1732531647,
"end_lt": "51239069000002",
"end_utime": 1732531655,
"trace_info": {
"trace_state": "pending",
"messages": 13,
"transactions": 13,
"pending_messages": 2,
"classification_state": "unclassified"
},

Block 42339038 does indeed exist in the database,but mc_deqno_end=42339037
Can you give me some advice? What might be the problem?

@wangxiaojia-wxj
Copy link
Author

Is there a problem with this modification statement in the InsertManagerial Postgres. cpp file?
if (!is_first_trace) {
traces_query << " ON CONFLICT (trace_id) DO UPDATE SET "
<< "mc_seqno_end = EXCLUDED.mc_seqno_end, "
<< "end_lt = EXCLUDED.end_lt, "
<< "end_utime = EXCLUDED.end_utime, "
<< "state = EXCLUDED.state, "
<< "pending_edges_ = EXCLUDED.pending_edges_, "
<< "edges_ = EXCLUDED.edges_, "
<< "nodes_ = EXCLUDED.nodes_ "
<< "WHERE traces.end_lt < EXCLUDED.end_lt;\n";

It should be like this, right?
traces_query << " ON CONFLICT (trace_id) DO UPDATE SET "
<< "mc_seqno_end = EXCLUDED.mc_seqno_end, "
<< "end_lt = EXCLUDED.end_lt, "
<< "end_utime = EXCLUDED.end_utime, "
<< "state = EXCLUDED.state, "
<< "pending_edges_ = EXCLUDED.pending_edges_, "
<< "edges_ = EXCLUDED.edges_, "
<< "nodes_ = EXCLUDED.nodes_ "
<< "WHERE traces.end_lt < EXCLUDED.end_lt or traces.mc_seqno_end < EXCLUDED.mc_seqno_end ;\n";

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant