zalando-zmon / zmon-controller

ZMON UI and REST API
https://docs.zmon.io/
Other
21 stars 17 forks source link

Grafana2: redirect to signin on 401 #98

Closed elauria closed 8 years ago

elauria commented 8 years ago

When a user doesn't have a session (it has not authenticated yet or it expired) Grafana2 loads but charts fail to fetch data. Backend responds with 401.

By reloading the grafana2 page, spring will take care of all redirection forth and back from authentication.

elauria commented 8 years ago

Grafana2 will now location.reload() whenever it gets a 401.

There is one downside to this solution and would require the next conditions to happen at the same time:

After this the user will be redirected to authenticate and then back to an un existing page (/grafana2/dashboard/new) showing an Error page instead.

elauria commented 8 years ago

110 updates to Grafana3, this will be closed and deprecated.