Skip to content
Snippets Groups Projects
This project is mirrored from https://github.com/metabase/metabase. Pull mirroring updated .
  1. Oct 02, 2024
  2. Oct 01, 2024
  3. Sep 30, 2024
    • Jeff Bruemmer's avatar
      Update WebhookChannelEdit.tsx (#48211) · a5466e05
      Jeff Bruemmer authored
      Unverified
      a5466e05
    • Noah Moss's avatar
    • Vamsi Peri's avatar
    • John Swanson's avatar
      Do not cache all token check failures (#48147) · 0ef2052f
      John Swanson authored
      * Do not cache all token check failures
      
      We want to cache token checks to avoid an issue where we repeatedly ask
      the store "hey, is this token valid?? is this token valid?? is this
      token valid??" for the same token.
      
      However, transient errors can also occur. For example, maybe a network
      issue causes the HTTP request to fail entirely. In this case, if we
      cache the result, the user needs to restart metabase (or wait 5 minutes
      until the cache is cleared) before they can attempt to validate their
      token again.
      
      This PR moves the cache logic deeper into the stack. We want to cache
      "successful" responses from the store API - cases where the store has
      told us categorically that the token is or is not valid. We don't want
      or need to cache other things that might happen. Maybe your token isn't
      the right length - we can recalculate that, it's ok. Maybe you get a 503
      error from the Store - we should let you retry. Maybe your network is
      having issues and you can't contact the Store at all - again, we should
      let you retry.
      
      The one potential issue I see here is that if the store goes down, we'll
      massively increase the number of requests we send to the store,
      potentially making it harder to recover. If this is a concern, I can add
      a circuit breaker: if we repeatedly get errors back from the store, back
      off and stop making requests for a while.
      
      * Add a circuit breaker to store API requests
      
      In the pathological case where the store goes down for >5 minutes, the
      cache will expire and all instances everywhere will start repeatedly
      making requests for token validation at once. This might make recovering
      from an outage more difficult.
      
      This adds a circuit breaker around the API request. If the call
      repeatedly throws (5XX errors, socket timeouts, etc.) then we'll pause
      for 1 minute, during which time all calls to token validation will
      immediately fail without making any request to the API.
      
      After one minute, we'll allow one request through to the API. If it
      succeeds, we'll go back to normal operation. Otherwise, we'll wait
      another minute.
      Unverified
      0ef2052f
    • Noah Moss's avatar
    • Nicolò Pretto's avatar
      updateSetting e2e typed helper (#48161) · dcc33ceb
      Nicolò Pretto authored
      
      * putSetting helper
      
      * change all usages of cy.request("PUT" "api/setting/..." to putSetting(...) in e2e tests
      
      * Update e2e/support/helpers/api/putSetting.ts
      
      Co-authored-by: default avatarKamil Mielnik <kamil@kamilmielnik.com>
      
      * Update e2e/support/helpers/api/putSetting.ts
      
      Co-authored-by: default avatarKamil Mielnik <kamil@kamilmielnik.com>
      
      * sort exports
      
      * putSetting -> updateSetting as per PR suggestion
      
      ---------
      
      Co-authored-by: default avatarKamil Mielnik <kamil@kamilmielnik.com>
      Unverified
      dcc33ceb
    • Romeo Van Snick's avatar
      Disable "Compare to the past" UI components (#48134) · 474b137a
      Romeo Van Snick authored
      * Temporarily disable compare to the past ui components
      
      * Temporarily disable compare to the past tests
      
      * Skip Compare to past unit tests
      Unverified
      474b137a
Loading