We currently fetch all of the config errors in order to decide whether or
not to show the bell icon in the web ui (which indicates that there are
errors). We recently added a tenant-status endpoint which returns a simple
error count instead of the entire data structure. Use that to decide
whether to show the bell instead.
This builds on the previous change that fetches the config errors on-demand
rather than storing them in the redux store. With that change and this
combined, we no longer need to store the errors in redux. Instead we will
store the error count in redux so we only have to fetch it once when
switching tenants.
Change-Id: I3dfd911af9ba55dd55ca3649ee5ecf6edaa3581a
If we encounter network delays loading the config errors endpoint
(which is likely if it's large), then we can end up issuing multiple
outstanding GET requests for the same endpoint. Avoid that by using
the isFetching pattern used by other members of the store.
Also, store the tenant name for the most recent fetch so that we
*can* have multiple outstanding requests for different tenants, but
we only accept the most recent one.
Change-Id: Ic49027e137b8c30004d43059db259d10c5443812
This updates the web UI to support the requirement for authn/z
for read-only access.
If authz is required for read access, we will automatically redirect.
If we return and still aren't authorized, we will display an
"Authorization required" page (rather than continuing and popping up
API error notifications).
The API methods are updated to send an authorization token whenever
one is present.
Change-Id: I31c13c943d05819b4122fcbcf2eaf41515c5b1d9
This change applies best practices to split the current reducers module
in logical unit. Each reducer and its actions are moved into different
modules to ease further refactor and follow-up tests.
Change-Id: I75cc41ca3d31a61046868aafbc84505de661a99d