Skip to content

Commit

Permalink
chore: add tags to gql query
Browse files Browse the repository at this point in the history
  • Loading branch information
dtfiedler committed Jun 7, 2024
1 parent d1a6e9f commit b40c1d4
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions src/store/turbo-report-sink.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,10 @@ async function createReportDataItem(
name: 'AR-IO-Component',
value: 'observer',
},
{
name: 'AR-IO-Epoch-Start-Height',
value: report.epochStartHeight.toString(),
},
{
name: 'AR-IO-Epoch-Start-Timestamp',
value: report.epochStartTimestamp.toString(),
Expand Down Expand Up @@ -150,6 +154,8 @@ export class TurboReportSink implements ReportSink {

async getReportTxId(report: ObserverReport): Promise<string | undefined> {
const epochStartTimestamp = report.epochStartTimestamp;
const epochStartHeight = report.epochStartHeight;
const epochIndex = report.epochIndex;

// Find the first report TX ID for the given epoch start height
const queryObject = {
Expand All @@ -159,6 +165,14 @@ export class TurboReportSink implements ReportSink {
first:1,
owners: [ "${this.walletAddress}" ],
tags: [
{
name: "AR-IO-Epoch-Start-Height",
values: [ "${epochStartHeight}" ]
},
{
name: "AR-IO-Epoch-Index",
values: [ "${epochIndex}" ]
}
{
name: "AR-IO-Epoch-Start-Timestamp",
values: [ "${epochStartTimestamp}" ]
Expand Down

0 comments on commit b40c1d4

Please sign in to comment.