graphprotocol / graphprotocol/graph-node

[Feature] Windowed aggregates

オープン
#5,302 コメント 3 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

area/aggregations enhancement Stale
主要言語
Rust
スター
3.2k
フォーク
1.1k
平均マージ
4日 1時間
マージ済み PR(30日)
1

説明

Description

Aggregates can be formed either over the current bucket (hour, day) or the entire lifetime of the underlying timeseries. In some cases, it would also be useful to aggregate over a limited window, e.g., the last 6 hours. That could look something like

  recent_max_price: BigDecimal! @aggregate(fn: "max", arg: "price", window: 6)

The current ways to aggregate would be expressed as window: 1 (default) and window: "all" (lifetime/cumulative)

There's a bunch of things that aren't entirely clear:

  • Is it enough if the window is always an integer multiple of the bucket? Or should we offer expressing arbitrary times there, like window: "90 minutes"
  • How would users express that a windowed aggregate should be done for one interval but not the others, e.g., if the above aggregation is done both hourly and daily, how do you express "only add this to the hourly aggregates"

コントリビューションガイド

コントリビューションガイドを開く

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

調査の方向性

ファイル、テスト、エントリポイントは指定されていません。まず、既存の集計構文と、現在のバケットおよびライフタイムの集計がどのように機能するかを確認します。完了の条件は、合意されたウィンドウ表現とインターバルのスコープ設定があり、限定付き、デフォルト、ライフタイムのウィンドウをカバーするテストがあることです。

索引モデルが issue の本文から書いたものです。

評価

技術スタック
graphql, rust
領域
api, data
issue の種類
機能追加
難易度
5/5
見積もり時間
1週間以上
活発さ
停滞
明瞭さ
説明が足りない
初心者へのやさしさ
25/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。