Coder Social home page Coder Social logo

maggiesfitness's People

Watchers

 avatar  avatar

maggiesfitness's Issues

Kibana not compressing some HTTP responses

Kibana version: 7.11.1

Elasticsearch version: 7.11.1

Server OS version: CentOS Linux release 7.9.2009

Browser version: Chrome 88.0.4324.192 and also Linux Curl

Browser OS version: MacOS 11.1

Original install method: RPM from official download page

Description of the problem including expected versus actual behavior:

As described in this thread, Kibana does not compress HTTP responses from /internal/bsearch even when the browser includes Accept-Encoding: gzip, deflate headers.
It is expected for these responses to be compressed with a default Kibana configuration.

This has performance implications when dealing with big datasets or slow links.

Steps to reproduce:

  1. In Kibana (on port 5601 without proxy) open Discover and browser your data.
  2. Open Chrome "Developer Tools" tool, select Network tab and inspect your requests.
  3. Most of them are compressed (the response includes the header Content-Encoding: gzip) but responses from /internal/bsearch are not (screenshots).
  4. Alternatively, we can use Linux Curl command in the server to reproduce the same issue (see below)

Errors in browser console: No errors.

Provide logs and/or server output:

Using Curl:

# curl -s -v -u elastic:elastic -XPOST 'localhost:5601/internal/bsearch' -H 'Content-Type: application/json' -H 'Accept-Encoding: gzip, deflate' -H 'kbn-xsrf: kibana' -d '{"batch":[{"request":{"params":{"index":"logs*:*","body":{"version":true,"size":500,"sort":[{"@timestamp":{"order":"desc","numeric_type":"date","unmapped_type":"boolean"}}],"aggs":{"2":{"date_histogram":{"field":"@timestamp","fixed_interval":"30s","time_zone":"Europe/Dublin","min_doc_count":1}}},"fields":[],"script_fields":{},"stored_fields":["*"],"_source":{"excludes":[]},"query":{"bool":{"must":[],"filter":[{"match_all":{}},{"range":{"@timestamp":{"gte":"2021-03-18T21:46:39.629Z","lte":"2021-03-18T22:01:39.629Z","format":"strict_date_optional_time"}}}],"should":[],"must_not":[]}},"highlight":{"pre_tags":["@kibana-highlighted-field@"],"post_tags":["@/kibana-highlighted-field@"],"fields":{"*":{}},"fragment_size":2147483647}},"preference":1616104872586}},"options":{"strategy":"ese","isStored":false,"isRestore":false}}]}'

* About to connect() to localhost port 5601 (#0)
*   Trying ::1...
* Connection refused
*   Trying 127.0.0.1...
* Connected to localhost (127.0.0.1) port 5601 (#0)
* Server auth using Basic with user 'elastic'
> POST /internal/bsearch HTTP/1.1
> Authorization: Basic xxxxxxxxx
> User-Agent: curl/7.29.0
> Host: localhost:5601
> Accept: */*
> Content-Type: application/json
> Accept-Encoding: gzip, deflate
> kbn-xsrf: kibana
> Content-Length: 830
>
* upload completely sent off: 830 out of 830 bytes
< HTTP/1.1 200 OK
< content-type: application/x-ndjson
< connection: keep-alive
< transfer-encoding: chunked
< kbn-name: xxxxxxxxx
< kbn-license-sig: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
< cache-control: private, no-cache, no-store, must-revalidate
< Date: Thu, 18 Mar 2021 22:26:59 GMT
<
{"id":0,"result":{"rawResponse":{"took":133,"timed_out":false,"_shards":{"total":394,"successful":394,"skipped":344,"failed":0},"_clusters":{"total":1,"successful":1,"skipped":0},"hits":{"total":1713499,"max_score":null,"hits":[{...
...
...
...
(10 KBytes of documents)

For comparison, other search API return compressed responses:

# curl -s -v -u elastic:elastic -XPOST 'localhost:5601/api/console/proxy?path=_mapping&method=GET' -H 'Content-Type: application/json' -H 'Accept-Encoding: gzip, deflate' -H 'kbn-xsrf: kibana'

* About to connect() to localhost port 5601 (#0)
*   Trying ::1...
* Connection refused
*   Trying 127.0.0.1...
* Connected to localhost (127.0.0.1) port 5601 (#0)
* Server auth using Basic with user 'elastic'
> POST /api/console/proxy?path=_mapping&method=GET HTTP/1.1
> Authorization: Basic xxxxxxxx
> User-Agent: curl/7.29.0
> Host: localhost:5601
> Accept: */*
> Content-Type: application/json
> Accept-Encoding: gzip, deflate
> kbn-xsrf: kibana
>
< HTTP/1.1 200 OK
< warning: 299 Elasticsearch-7.11.1-ff17057114c2199c9c1bbecc727003a907c0db7a "this request accesses system indices: [.async-search, .kibana_task_manager_1, .security-7, .tasks], but in a future major version, direct access to system indices will be prevented by default"
< content-type: application/json; charset=UTF-8
< kbn-name: xxxxxxxx
< kbn-license-sig: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
< cache-control: private, no-cache, no-store, must-revalidate
< vary: accept-encoding
< content-encoding: gzip
< Date: Thu, 18 Mar 2021 22:42:55 GMT
< Connection: keep-alive
< Keep-Alive: timeout=120
< Transfer-Encoding: chunked
<
?e??l?6?I?Q??lR[??$!f?????Z???u?????ͧ/w߫??s'Ȝp????͗?(?VΦ.'H0??U?ӆ]???˯5Ő?vE?uվ?/X?o??z??4Np?8?Wr?_? ?.F?q???c???}?????o??5??+???(+?8u?i\$:?>R_?Xd?с??0&?m?? ??<?#SAY\????#?||O??@a?[???$??͙?Q
>?[?b?i??f?|?F????cu?"?8???f?G]&SY<?A????0?0??>?_?S?'=DK?MI???(N1ي?E??q?Y?i??B???Y?ؘ ????'?&???$ɂ/dۭ??m?7??R??e?hNeS?dd?Sp??m?ژ?????k??Ѳ1??zs|?ז,?0????ӕ?Ѻa$??.?D(?9ӯ.??&GYt?<?K?Vq??K?s3?V"??8
...
...
...

Drilldown no longer working with TSVB pannel

**Kibana version:**7.11.1

Elasticsearch version: 7.11.1

Describe the bug:
Drilldown is not working with TSVB panels.
The documentation indicates that it should work. Could this be a regression?

Steps to reproduce:

  1. Create a cluster with 7.11.1
  2. Create a TSVB visualization and add it to a dashboard
  3. Create a drilldown for the TSVB panel and save it
    image

Action for the drilldown
image

  1. Nothing happens when clicking on the panel
    I enabled developer mode and no call is generated. With a working panel, I get a _bulk_get

Any additional context:
I discussed this already with @rashmivkulkarni and @Dosant didn't reproduce this on master.

Documentation: add xpack.security.cookieName to the page "Use Kibana in a production environment"

Hey folks,

The documentation about Kibana in a production environment talks about having Kibana being behind a load balancer but doesn't mention the issue that might arise when having multiple Kibana instances on different port on the same load balancer.

Indeed, in this case, the default value for xpack.security.cookieName is "sid" and this creates a conflict between the cookies when trying to access multiple kibana instances on the same browser. Setting explicitly xpack.security.cookieName to a different value fixes this while keeping a session active even if one Kibana instance crashes (in case of Kibana in HA).

Having this behavior documented in the above-mentioned page would be great.

This was first mentioned in the forums.

Cheers,

Julien

ps: if it's ok for you, I will create a PR for this next week.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.