Skip to content

Add daily-active-accounts computation job - #57

Merged
christabel888 merged 1 commit into
Stellar-Insightss:mainfrom
ndii-dev:issue-2-daa-job
Aug 28, 2026
Merged

Add daily-active-accounts computation job#57
christabel888 merged 1 commit into
Stellar-Insightss:mainfrom
ndii-dev:issue-2-daa-job

Conversation

@ndii-dev

Copy link
Copy Markdown

Closes #2

Adds src/jobs/daily_active_accounts.rs, following the existing
asset_revalidation.rs/contract_event_listener.rs job shape (config
struct with enabled/interval_seconds from env, start() loop with
JobMetricsCollector).

Note: JobScheduler::start() itself doesn't appear to be called anywhere
in main.rs yet (pre-existing, not introduced by this PR) — the job is
registered correctly and will run once the scheduler is wired up.

New src/jobs/daily_active_accounts.rs, following the asset_revalidation.rs/
contract_event_listener.rs job pattern: counts distinct source_account rows
in payments for the current UTC calendar day and upserts into
network_daily_metrics (migration 031, included here since Stellar-Insightss#45 may not have
landed yet). Registered in the scheduler and JOB_DAA_ENABLED/
JOB_DAA_INTERVAL_SECONDS documented in .env.example.
@christabel888
christabel888 merged commit d8cae6d into Stellar-Insightss:main Aug 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add daily-active-accounts computation job in src/jobs

3 participants