Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

feat(coderd/database): adddbrollup service to rollup insights#12665

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
mafredri merged 2 commits intomainfrommafredri/add-dbrollup-service-for-insights
Mar 22, 2024

Conversation

mafredri
Copy link
Member

@mafredrimafredri commentedMar 19, 2024
edited
Loading

This PR adds the dbrollup service that runs theUpsertTemplateUsageStats query every 5 minutes, on the minute. This allows us to have fairly real-time data when viewing "today".

@mafredriGraphite App
Copy link
MemberAuthor

mafredri commentedMar 19, 2024
edited
Loading

This was referencedMar 19, 2024
@mafredrimafredriforce-pushed themafredri/add-template-usage-stats-table-and-rollup-query branch from5a49791 toc9fe7c5CompareMarch 19, 2024 16:24
@mafredrimafredriforce-pushed themafredri/add-dbrollup-service-for-insights branch from6364b79 todcc3811CompareMarch 19, 2024 16:24
Copy link
Member

@johnstcnjohnstcn left a comment
edited
Loading

Choose a reason for hiding this comment

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

👍 once CI is happy

@@ -0,0 +1,127 @@
package dbrollup
Copy link
Member

Choose a reason for hiding this comment

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

I see a potential abstraction here -- the PR I'm working on in parallel#12659 has a similar logic of "run a query every interval". There are definitely other areas of the codebase that could benefit from a similar framework.

}
}

func (r *Rolluper) Close() error {
Copy link
Member

Choose a reason for hiding this comment

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

Is the error return value here to satisfy an interface? Do we need it?

Copy link
MemberAuthor

Choose a reason for hiding this comment

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

Yeah, I feel the io.Closer interface is so common it's worth using this signature even if the error is not used at the moment or ever in the future.

@mafredrimafredriforce-pushed themafredri/add-template-usage-stats-table-and-rollup-query branch fromc9fe7c5 to46bc0f0CompareMarch 20, 2024 10:25
@mafredrimafredriforce-pushed themafredri/add-dbrollup-service-for-insights branch 2 times, most recently from7fc6fb5 to91fb8e4CompareMarch 20, 2024 10:37
@mafredrimafredriforce-pushed themafredri/add-template-usage-stats-table-and-rollup-query branch fromb64c291 tob3bdea2CompareMarch 20, 2024 13:56
@mafredrimafredriforce-pushed themafredri/add-dbrollup-service-for-insights branch 3 times, most recently from32a5d2c toe77ca25CompareMarch 20, 2024 16:02
@mafredrimafredriforce-pushed themafredri/add-template-usage-stats-table-and-rollup-query branch fromdf37ae9 tocafcc7bCompareMarch 20, 2024 19:03
@mafredrimafredriforce-pushed themafredri/add-dbrollup-service-for-insights branch 4 times, most recently from28c5885 to4374753CompareMarch 20, 2024 19:43
@mafredrimafredriforce-pushed themafredri/add-template-usage-stats-table-and-rollup-query branch from8f207e3 to310f545CompareMarch 20, 2024 19:55
@mafredrimafredriforce-pushed themafredri/add-dbrollup-service-for-insights branch from4374753 to7145189CompareMarch 20, 2024 19:55
@mafredrimafredriforce-pushed themafredri/add-template-usage-stats-table-and-rollup-query branch from310f545 tofc0b87cCompareMarch 21, 2024 15:06
@mafredrimafredriforce-pushed themafredri/add-dbrollup-service-for-insights branch from7145189 toc2926efCompareMarch 21, 2024 15:06
@mafredrimafredriforce-pushed themafredri/add-template-usage-stats-table-and-rollup-query branch fromfc0b87c tocba0c08CompareMarch 21, 2024 17:53
@mafredrimafredriforce-pushed themafredri/add-dbrollup-service-for-insights branch fromc2926ef to8ccae5fCompareMarch 21, 2024 17:54
@mafredrimafredriforce-pushed themafredri/add-template-usage-stats-table-and-rollup-query branch fromcba0c08 to8b96a59CompareMarch 22, 2024 15:40
@mafredrimafredriforce-pushed themafredri/add-dbrollup-service-for-insights branch from8ccae5f toc8221f3CompareMarch 22, 2024 15:40
@mafredrimafredri marked this pull request as ready for reviewMarch 22, 2024 16:21
@mafredriGraphite App
Copy link
MemberAuthor

mafredri commentedMar 22, 2024
edited
Loading

Merge activity

  • Mar 22, 12:33 PM EDT:@mafredri started a stack merge that includes this pull request viaGraphite.
  • Mar 22, 12:34 PM EDT:Graphite rebased this pull request as part of a merge.
  • Mar 22, 12:42 PM EDT:@mafredri merged this pull request withGraphite.

Base automatically changed frommafredri/add-template-usage-stats-table-and-rollup-query tomainMarch 22, 2024 16:33
@mafredrimafredriforce-pushed themafredri/add-dbrollup-service-for-insights branch fromc8221f3 to2040b87CompareMarch 22, 2024 16:33
@mafredrimafredri merged commit12e6fbf intomainMar 22, 2024
@mafredrimafredri deleted the mafredri/add-dbrollup-service-for-insights branchMarch 22, 2024 16:42
@github-actionsgithub-actionsbot locked and limited conversation to collaboratorsMar 22, 2024
Sign up for freeto subscribe to this conversation on GitHub. Already have an account?Sign in.
Reviewers

@johnstcnjohnstcnjohnstcn left review comments

@mtojekmtojekmtojek approved these changes

Assignees

@mafredrimafredri

Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

3 participants
@mafredri@johnstcn@mtojek

[8]ページ先頭

©2009-2025 Movatter.jp