storacha-network / w3infra

🏗️ Infra for the w3up UCAN protocol implementation
Other
13 stars 5 forks source link

Add logging to space state changes, tests of billing usage #394

Closed hannahhoward closed 1 month ago

hannahhoward commented 1 month ago

Goals

Better debug https://github.com/storacha-network/project-tracking/issues/75

Implementation

This PR does 2 things:

  1. Add logging to the ucanstream handler for Billing API, to see if it is properly parsing and saving space diffs when a user uploads
  2. Adds checks of before and after on usage from the billing system to the blob and store integration tests -- this is based almost exactly on the way the UsageBar component fetches data in the console.
seed-deploy[bot] commented 1 month ago
View stack outputs - **pr394-w3infra-BillingDbStack** Name | Value -- | -- customerTableName | pr394-w3infra-customer spaceDiffTableName | pr394-w3infra-space-diff spaceSnapshotTableName | pr394-w3infra-space-snapshot usageTable | pr394-w3infra-usage - **pr394-w3infra-BillingStack** Name | Value -- | -- ApiEndpoint | https://9w726auh01.execute-api.us-east-2.amazonaws.com billingCronHandlerURL | https://tageef3vnclqjszpkdw5ow5be40rxsys.lambda-url.us-east-2.on.aws/ CustomDomain | https://pr394.billing.web3.storage - **pr394-w3infra-CarparkStack** Name | Value -- | -- BucketName | carpark-pr394-0 Region | us-east-2 - **pr394-w3infra-RoundaboutStack** Name | Value -- | -- ApiEndpoint | https://bnx6h4lnsa.execute-api.us-east-2.amazonaws.com CustomDomain | https://pr394.roundabout.web3.storage - **pr394-w3infra-UcanInvocationStack** Name | Value -- | -- invocationBucketName | invocation-store-pr394-0 taskBucketName | task-store-pr394-0 workflowBucketName | workflow-store-pr394-0 - **pr394-w3infra-UploadApiStack** Name | Value -- | -- ApiEndpoint | https://2i4013bcul.execute-api.us-east-2.amazonaws.com CustomDomain | https://pr394.up.web3.storage - **pr394-w3infra-BusStack** - **pr394-w3infra-FilecoinStack** - **pr394-w3infra-ReplicatorStack** - **pr394-w3infra-UcanFirehoseStack** - **pr394-w3infra-UploadDbStack**