Skip to content

feat(hub): add actors billing preview #2466

New issue

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

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Closed
wants to merge 1 commit into from

Conversation

jog1t
Copy link
Contributor

@jog1t jog1t commented May 21, 2025

Changes

Copy link

cloudflare-workers-and-pages bot commented May 21, 2025

Deploying rivet-studio with  Cloudflare Pages  Cloudflare Pages

Latest commit: 76ea7d9
Status:🚫  Build failed.

View logs

Copy link
Contributor Author

jog1t commented May 21, 2025


How to use the Graphite Merge Queue

Add the label merge-queue to this PR to add it to the merge queue.

You must have a Graphite account in order to use the merge queue. # using this link.

An organization admin has enabled the Graphite Merge Queue in this repository.

Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue.

This stack of pull requests is managed by Graphite. Learn more about stacking.

@jog1t jog1t marked this pull request as ready for review May 21, 2025 19:09
Copy link
Contributor

graphite-app bot commented May 21, 2025

Graphite Automations

"Test" took an action on this PR • (05/21/25)

1 assignee was added to this PR based on Kacper Wojciechowski's automation.

Copy link

cloudflare-workers-and-pages bot commented May 21, 2025

Deploying rivet-hub with  Cloudflare Pages  Cloudflare Pages

Latest commit: 76ea7d9
Status:🚫  Build failed.

View logs

Copy link

cloudflare-workers-and-pages bot commented May 21, 2025

Deploying rivet with  Cloudflare Pages  Cloudflare Pages

Latest commit: 76ea7d9
Status:🚫  Build failed.

View logs

Copy link

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

PR Summary

Introduces actor-based billing preview functionality with a new ActorsBillingUsage component and refactored billing calculations.

  • Added ActorsBillingUsage component in /frontend/apps/hub/src/domains/project/components/billing/actors-billing-usage.tsx to display billing usage for actors
  • Refactored billing context in billing-context.tsx to use server-side aggregate billing queries instead of local calculations
  • Added new calculateUsedActorCredits function in billing-calculate-usage.ts with a 1.1x overhead factor
  • Changed actor query pagination to Number.POSITIVE_INFINITY in multiple files which may impact performance
  • Missing required projectId prop in billing-view.tsx when rendering ActorsBillingUsage alongside MissingPaymentMethod

16 file(s) reviewed, 10 comment(s)
Edit PR Review Bot Settings | Greptile

projectId={projectId}
groupId={developerGroupId}
/>
<ActorsBillingUsage />
Copy link

Choose a reason for hiding this comment

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

logic: Missing required projectId prop for ActorsBillingUsage component. This will cause runtime errors since the component uses this prop internally.

Suggested change
<ActorsBillingUsage />
<ActorsBillingUsage projectId={projectId} />

@jog1t jog1t force-pushed the 05-21-feat_hub_add_actors_billing_preview branch from ac1b42f to edb251e Compare May 22, 2025 12:09
@jog1t jog1t force-pushed the 05-21-feat_hub_add_actors_billing_preview branch 4 times, most recently from 9aea382 to c027938 Compare June 4, 2025 21:03
@jog1t jog1t force-pushed the 05-21-feat_hub_add_actors_billing_preview branch from c027938 to 20a4f29 Compare June 4, 2025 21:36
@jog1t jog1t force-pushed the 05-21-feat_hub_add_actors_billing_preview branch from 20a4f29 to 76ea7d9 Compare June 4, 2025 21:50
Copy link
Contributor

graphite-app bot commented Jun 4, 2025

Merge activity

  • Jun 4, 11:12 PM UTC: jog1t added this pull request to the Graphite merge queue.
  • Jun 4, 11:13 PM UTC: CI is running for this pull request on a draft pull request (#2546) due to your merge queue CI optimization settings.
  • Jun 4, 11:14 PM UTC: Merged by the Graphite merge queue via draft PR: #2546.

graphite-app bot pushed a commit that referenced this pull request Jun 4, 2025
<!-- Please make sure there is an issue that this PR is correlated to. -->

## Changes

<!-- If there are frontend changes, please include screenshots. -->
@graphite-app graphite-app bot closed this Jun 4, 2025
@graphite-app graphite-app bot deleted the 05-21-feat_hub_add_actors_billing_preview branch June 4, 2025 23:14
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant