Skip to content

Instantly share code, notes, and snippets.

@hpjaj
Created September 26, 2018 21:02
Show Gist options
  • Select an option

  • Save hpjaj/2f276226583816228245bbefd40e71be to your computer and use it in GitHub Desktop.

Select an option

Save hpjaj/2f276226583816228245bbefd40e71be to your computer and use it in GitHub Desktop.

Questions for TeamSite sync up on 09/26/2018

Whitelisting

Whitelisted pages:

['/', '/disability', '/facilities', '/welcome-kit']

Goal

Store a whitelist (an array of strings):

  • in a place that is accessible to both the FE and BE
  • does not require the FE to repeatedly make a call to the BE to retrieve the list

Whitelisting Implementation Ideas

  1. Maintaining two individual flat files on both BE/FE

    • Have to maintain same content in two places
    • FE & BE both whitelist
  2. Only the FE maintains the list

    • Single source of truth for whitelist
    • Only the FE does the whitelisting
    • Exposes BE endpoint to DoS attacks
  3. Adding to DevOps config as environment var for both FE and BE

    • Single source of truth for whitelist
    • Would not require a network request by either
    • FE & BE both whitelist

Sampling

Goal

We want to avoid recording metrics for every pageload on whitelisted paths.

Implementation Ideas

  • Do the FE eng have suggestions for how best to throttle & sample?

    • Current method is to randomly sample a given percentage of users
  • Will we desire varying densities/settings per environment?

    • I.e. va.gov to have 10% but preview.va.gov to have 100%

Additional concerns

  • Which environments SHOULD have metrics enabled?
    • Just in preview.va.gov & ultimately va.gov?
    • Is there a use case for staging or dev?
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment