Skip to content

Conversation

@dimitrovmaksim
Copy link
Member

Resolves #4579

What this PR does:

  1. Adds a new materialized view info.table_stats that aggregates statistics from pg_stats for subgraph entity tables, calculating estimated unique entities, total versions, and uniqueness ratio.
  2. Adds a optional experimental background job querying the view to find eligible tables and setting the is_account_like flag. The job can be enabled by setting the following env vars
  • GRAPH_STORE_ACCOUNT_LIKE_SCAN_INTERVAL_HOURS
  • GRAPH_STORE_ACCOUNT_LIKE_MIN_VERSION_COUNT
  • GRAPH_STORE_ACCOUNT_LIKE_MAX_UNIQUE_RATIO
  1. Updates the ENV vars documentation with the new variables and their usage.

@dimitrovmaksim dimitrovmaksim changed the title Feature/automate account like optimization Feat: Automate account-like optimization Nov 6, 2025
@dimitrovmaksim dimitrovmaksim self-assigned this Nov 6, 2025
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.

[Feature] Automate setting of account-like optimization

1 participant