lightweight com.atproto.sync.listReposByCollection
45
fork

Configure Feed

Select the types of activity you want to include in your feed.

fix token sleep logic

+15 -5
+5 -3
hacking.md
··· 118 118 - [x] account status convergeance: if we receive commits from apparently-inactive accounts, should we check upstream status to make sure we're not stale? 119 119 - [x] resync short-circuit: tiny repos may actually return their entire CAR for getRecord 120 120 - [x] use jacquard's built-in inductive proof methods 121 - - [~] repo-stream: drop record block contents with processor fn 121 + - [x] repo-stream: drop record block contents with processor fn 122 122 - [x] in getRecord before describeRepo 123 - - [ ] in commit handling 124 - - [ ] commit CAR handling: generate a list of keys with gaps noted, to reliably detect missing adjacent keys 123 + - [x] in commit handling 124 + - [x] commit CAR handling: generate a list of keys with gaps noted, to reliably detect missing adjacent keys 125 + - [ ] watch logs for errors now that we're strict 125 126 - [ ] meta/metrics keyspace for general stats 126 127 - [ ] total repos (hyperloglog estimate?) 127 128 - [ ] resync queue size ··· 140 141 - [ ] bad word filtering? (collectiondir has it) 141 142 - [ ] check response headers and adjust self-throttling rate limits per-host if present 142 143 - [ ] make backfill go _really fast_ 144 + - [ ] clean up commit validation (eg we're checking signatures twice, lenient handling is weird) 143 145 144 146 going to be annoying but doable 145 147 - [ ] multi-relay subscriber
+9 -1
src/main.rs
··· 164 164 ); 165 165 sub.run(token) 166 166 .await 167 + .inspect(|_| info!("firehose subscriber done.")) 167 168 .inspect_err(|e| warn!(error = %e, "firehose exited")) 168 169 } 169 170 }); ··· 176 177 async move { 177 178 if backfill::run(host, db, client, token.clone(), None) 178 179 .await 180 + .inspect(|_| info!("backfill done.")) 179 181 .inspect_err(|e| warn!(error = %e, "backfill exited"))? 180 182 { 181 183 info!("backfill task idling"); ··· 202 204 force_get_repo: args.heavy, 203 205 }) 204 206 .await 207 + .inspect(|_| info!("resync done.")) 205 208 .inspect_err(|e| warn!(error = %e, "resync exited")) 206 209 } 207 210 }); ··· 219 222 async move { 220 223 lightrail::server::serve(addr, db, token, admin_config) 221 224 .await 225 + .inspect(|_| info!("server done.")) 222 226 .inspect_err(|e| warn!(error = %e, "server exited")) 223 227 } 224 228 }); ··· 240 244 resolver, 241 245 ) 242 246 .await 247 + .inspect(|_| info!("deep crawl done.")) 243 248 .inspect_err(|e| warn!(error = %e, "deep crawl exited")) 244 249 } 245 250 }); ··· 252 257 eprintln!("Shutting down..."); 253 258 None 254 259 } 255 - r = tasks.join_next() => r, 260 + r = tasks.join_next() => { 261 + eprintln!("=== a task exited with: {r:?} ==="); 262 + r 263 + }, 256 264 }; 257 265 token.cancel(); 258 266
+1 -1
src/util.rs
··· 23 23 async fn sleep(&self, d: tokio::time::Duration) -> bool { 24 24 self.run_until_cancelled(tokio::time::sleep(d)) 25 25 .await 26 - .is_none() 26 + .is_some() 27 27 } 28 28 }