Skip to content
This repository was archived by the owner on Sep 5, 2025. It is now read-only.

chore: add load example amd query CLI#91

Merged
matthewmcneely merged 7 commits intomainfrom
matthewmcneely/add-load-example
May 1, 2025
Merged

chore: add load example amd query CLI#91
matthewmcneely merged 7 commits intomainfrom
matthewmcneely/add-load-example

Conversation

@matthewmcneely
Copy link
Contributor

Description

This PR adds a load example and a query cli

Checklist

  • Code compiles correctly and linting passes locally

@matthewmcneely matthewmcneely requested review from a team and Copilot April 30, 2025 23:46
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR introduces two new command-line tools—a loader for the 1million dataset and a query CLI—while updating existing logging calls to use the configured logger.

  • Introduces a new load example CLI in the examples/load folder.
  • Adds a query CLI in the cmd/query folder along with associated documentation.
  • Updates logging calls in live_test.go, live.go, and client.go to consistently use the logger.

Reviewed Changes

Copilot reviewed 9 out of 9 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
load_test/live_test.go Updates logging to use stdr logger for engine configuration.
live.go Replaces standard logging with engine.logger for consistency.
examples/load/main.go New loader CLI with download and progress tracking logic.
examples/load/README.md Documentation for the new load CLI tool.
examples/basic/main.go Adjusted verbosity flag parsing logic.
cmd/query/main.go New query CLI implementation for executing DQL queries.
cmd/query/README.md Documentation for the query CLI tool.
client.go Modified QueryRaw to leverage engine namespace queries.
README.md Updated CLI commands and example usage details.
Comments suppressed due to low confidence (1)

live.go:84

  • [nitpick] Consider logging the 'rate' value as a numeric type rather than formatting it as a string using fmt.Sprintf, if the logger supports numeric values. This may enable better downstream processing and filtering of log data.
n.engine.logger.Info("Data loading progress", "elapsed", x.FixedDuration(elapsed), "quads", nqudsProcessed, "rate", fmt.Sprintf("%5.0f", rate))

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@matthewmcneely matthewmcneely enabled auto-merge (squash) May 1, 2025 00:17
@matthewmcneely matthewmcneely merged commit 9425512 into main May 1, 2025
7 checks passed
@matthewmcneely matthewmcneely deleted the matthewmcneely/add-load-example branch May 1, 2025 01:55
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants