-
Notifications
You must be signed in to change notification settings - Fork 8.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Intermittent 406 with short URLs #10456
Comments
I'm seeing this as well after upgrading from 4.4.2 to 4.6.4. It seems target URL validation landed in the following commit: However, this breaks older existing short URLs which seemed to have absolute URLs in the target URL. This can be seen when looking at |
This is also the error returned when a short url is not found, instead of a 404. |
Is there any update on this? Currently running 5.3.0 and it's become impossible to share links with people. |
This error occurs when Kibana gets an error while querying it's ES index for the short-url document. The true error is swallowed and a default value of "/" is returned when trying to get the target path for the short URL. In our case this was due to our ES using authentication which the server-side code failed to supply. The problem is that short_url_lookup.js->getUrlDoc uses callWithRequest to access ES. callWithRequest tries to use the credentials passed to the request kibana got, but requests to /goto/{id} path do not require auth, and hence will be missing it in some cases. Hacky workaround: I just changed getUrlDoc code to use callWithInternalUser instead. This bypasses the need for authentication. Works perfectly for us. Not sure, but maybe forcing auth on the goto path might be a more reasonable approach. |
Kibana version: 5.2.0
Elasticsearch version: 5.2.0
Server OS version: Ubuntu 16.04.2
Browser version: Firefox 50.1.0
Browser OS version: Ubuntu 14.04.5
Original install method (e.g. download page, yum, from source, etc.): Apt
Description of the problem including expected versus actual behavior: Visiting a short URL sometimes produces a 406 error, rather than the expected dashboard.
Steps to reproduce:
{"statusCode":406,"error":"Not Acceptable","message":"Short url target path must be in the format \"/app/{{appId}}\", found \"/\""}
I have only seen this error twice and am unable to reproduce it for this issue. However I did notice that although the error persists over time (days), as soon as a second short URL is created for the same dashboard, the error no longer occurs.
First occurred immediately after upgrading from 5.1.0 to 5.2.0 .
The text was updated successfully, but these errors were encountered: