Skip to content

feat(mrt-utilities): Add MRT-prefixed env configuration for dev data-store#385

Merged
bendvc merged 1 commit intomainfrom
bendvc/fix-data-store-env-vars
Apr 27, 2026
Merged

feat(mrt-utilities): Add MRT-prefixed env configuration for dev data-store#385
bendvc merged 1 commit intomainfrom
bendvc/fix-data-store-env-vars

Conversation

@bendvc
Copy link
Copy Markdown
Collaborator

@bendvc bendvc commented Apr 27, 2026

PR Description

Summary

  • rename development data-store environment variables to MRT_DATA_STORE_DEFAULTS and MRT_DATA_STORE_WARN_ON_MISSING to make the feature generic beyond SFNEXT-specific consumers
  • keep backward compatibility by falling back to legacy SFNEXT_DATA_STORE_DEFAULTS and SFNEXT_DATA_STORE_WARN_ON_MISSING when the new MRT_* variables are not set
  • update tests and docs to use the MRT_* names, while intentionally not documenting the legacy SFNEXT_* variables

Test Plan

  • pnpm --filter @salesforce/mrt-utilities run lint:agent
  • pnpm --filter @salesforce/mrt-utilities run test:agent
  • pnpm --filter @salesforce/mrt-utilities run typecheck:agent
  • manual validation with node --conditions dev-data-store confirms env-backed values resolve and missing keys throw DataStoreNotFoundError

@bendvc bendvc requested a review from clavery as a code owner April 27, 2026 20:34
@bendvc bendvc changed the title feat(mrt-utilities): add dev data-store export and MRT-prefixed env configuration feat(mrt-utilities): MRT-prefixed env configuration Apr 27, 2026
@bendvc bendvc requested a review from kieran-sf April 27, 2026 20:43
@bendvc bendvc changed the title feat(mrt-utilities): MRT-prefixed env configuration feat(mrt-utilities): Add MRT-prefixed env configuration for dev data-store Apr 27, 2026

function readDefaultsFromEnv(): Record<string, Record<string, unknown>> {
const raw = process.env.SFNEXT_DATA_STORE_DEFAULTS;
const raw = process.env.MRT_DATA_STORE_DEFAULTS ?? process.env.SFNEXT_DATA_STORE_DEFAULTS;
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

wanna leave a comment here to explain why there is SFNEXT_DATA_STORE_DEFAULTS in the code base?

@bendvc bendvc merged commit 933ea84 into main Apr 27, 2026
6 checks passed
@bendvc bendvc deleted the bendvc/fix-data-store-env-vars branch April 27, 2026 21:31
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.

2 participants