Skip to content
Snippets Groups Projects

Add support for querying c-in-d + d-in-r

Merged vlorentz requested to merge c-in-d-in-r into main
4 unresolved threads

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
434 schema,
435 "c_in_d", // table name, for error messages
436 "cnt",
437 "dir",
438 node_ids,
439 None, // no limit
440 )
441 .await
442 .context("Could not query c_in_d")?;
443 tracing::trace!("Got c_in_d_stream");
444 tracing::debug!("Scan init metrics: {:#?}", scan_init_metrics);
445
446 Ok((scan_init_metrics, scan_metrics, c_in_d_stream))
447 }
448
449 /// Given a [`NodeId`], returns some records from the contents-in-revision table
  • David Douard
    David Douard @douardda started a thread on commit cf567031
  • 467 let limit = 1;
    468 let (scan_init_metrics, scan_metrics, d_in_r_stream) = query_x_in_y_table(
    469 &self.db.d_in_r,
    470 schema,
    471 "d_in_r", // table name, for error messages
    472 "dir",
    473 "revrel",
    474 node_ids,
    475 Some(limit),
    476 )
    477 .await
    478 .context("Could not query d_in_r")?;
    479 tracing::trace!("Got d_in_r_stream");
    480 tracing::debug!("Scan init metrics: {:#?}", scan_init_metrics);
    481
    482 // Read batches of rows, stopping after the first one
  • vlorentz mentioned in merge request !187 (merged)

    mentioned in merge request !187 (merged)

    • lgtm (but who am I to judge? :-)

      Would be nice to have a bit more comment/doc. Eg. in metrics.rs, it would be nice to have some context on how and this code is used for (without digging in queries). (Also it's not clear to me why this MR adds so much code in this metrics.rs file).

      Anyway, thanks

    • Author Maintainer

      Eg. in metrics.rs, it would be nice to have some context on how and this code is used for (without digging in queries).

      I agree. I'm planning to document this once I'm done changing everything all the time.

      (Also it's not clear to me why this MR adds so much code in this metrics.rs file).

      so we can use the obvious operators elsewhere in the code. It's a shame Rust can't auto-generate those.

    • Please register or sign in to reply
  • David Douard approved this merge request

    approved this merge request

  • note: did not really reviewed the refactoring ('deduplicate ...') revision

  • merged

  • Please register or sign in to reply
    Loading