tangled
alpha
login
or
join now
ptr.pet
/
aturlist
0
fork
atom
aturi indexer with listRecords and countRecords endpoints
0
fork
atom
overview
issues
pulls
pipelines
only add to ops count if the op was actually handled
ptr.pet
1 month ago
094521b4
69ae82f9
verified
This commit was signed with the committer's
known signature
.
ptr.pet
SSH Key Fingerprint:
SHA256:Abmvag+juovVufZTxyWY8KcVgrznxvBjQpJesv071Aw=
+2
-2
1 changed file
expand all
collapse all
unified
split
src
main.rs
+2
-2
src/main.rs
···
143
143
let mut handled = true;
144
144
145
145
if let Event::Record(rec) = event {
146
146
-
ops_count.fetch_add(1, Ordering::Relaxed);
147
147
-
148
146
match db.keyspace(&rec.collection, KeyspaceCreateOptions::default) {
149
147
Ok(ks) => {
150
148
let counts = counts.clone();
149
149
+
let ops_count = ops_count.clone();
151
150
handled =
152
151
tokio::task::spawn_blocking(move || {
153
152
if let Err(e) = handle_record(&counts, &ks, rec) {
154
153
error!("error handling record: {}", e);
155
154
false
156
155
} else {
156
156
+
ops_count.fetch_add(1, Ordering::Relaxed);
157
157
true
158
158
}
159
159
})