Skip to content

Salsa Audit #665

Closed
Closed

Description

@alilleybrinker

The State of Salsa in Hipcheck Core

  • Database Structs
    • HcEngineImpl
    • Session
  • Database-Subtraits
    • HcEngine
      • (input) core
      • default_policy_expr
      • default_query_explanation
      • query
    • VersionQuery
      • hc_version
      • npm_version
      • eslint_version
      • git_version
    • SourceQuery
      • (input) target
      • local
      • remote
      • head
      • name
      • url
    • ConfigSource
      • config_dir
      • policy
      • poliy_path
      • github_api_token
      • cache_dir
      • unresolved_analysis_tree
      • normalized_unresolved_analysis_tree
    • RiskConfigQuery
      • risk_policy
    • LanguageConfigQuery
      • langs_file_rel
      • langs_file
    • PracticesConfigQuery
      • binary_formats_file_rel
      • binary_formats_file
    • AttacksConfigQuery
      • typo_file_rel
      • typo_file
    • CommitsConfigQuery
      • orgs_file_rel
      • orgs_file
      • contributor_trust_value_threshold
      • contributor_trust_month_count_threshold
  • Query Groups
    • RiskConfigQueryStorage
    • LanguagesConfigQueryStorage
    • PracticesConfigQueryStorage
    • AttacksConfigQueryStorage
    • CommitConfigQueryStorage
    • WeightTreeQueryStorage
    • SourceQueryStorage
    • ReportParamsStorage
    • ScoringProviderStorage
    • VersionQueryStorage
    • HcEngineStorage

Basically at the end of this, out of all of the above, only the use of Salsa for querying should remain. Everything else should be plain functions.

I'd break the stuff above into categories:

  • Caching around the old config format.
  • Caching around version information for external tools.
  • Caching around information for the target of analysis (really, the old Source struct; not clear if that's even still relevant)
  • Caching for queries (keep this)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    product: hc

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions