AntonShuvaev / elasticsearch4idea

Elasticsearch Plugin for JetBrains IDEs
https://plugins.jetbrains.com/plugin/14512-elasticsearch
58 stars 8 forks source link

Console doesn't automatically open table view #111

Closed lookingcloudy closed 1 year ago

lookingcloudy commented 1 year ago

Describe the bug On Mac Datagrip: After closing data grip, reopening, then opening your console and running GET /index-01 I simply get JSON text response. There is no table view or options to change the view. Not sure how to get back to the table view.

Steps to reproduce Close data grip tabs Close data grip application Open data grip Open "Elasticsearch" Open default console Run a GET /index

Expected behavior I would expect the results window to open where I can select table/json and export the data.

Environment information:

AntonShuvaev commented 1 year ago

You need to run GET /index-01/_search instead of GET /index-01 to get the table view.

lookingcloudy commented 1 year ago

Ok - from a UX perspective - it would be nice to have the same result window regardless, just like datagrip does. The table view would just be greyed out if there is no table data.

lookingcloudy commented 1 year ago

Ok - so running this request:

GET /_cat/indices/prod-triton-*?v=true&s=index

I now get a table view, but no controls at the top of the page. I really want this list in raw/json view.

default_–_console___localhost_
AntonShuvaev commented 1 year ago

The table view is displayed only for the request GET /index_or_alias/_search.

lookingcloudy commented 1 year ago

What is the view above? Looks like a table view. It isn't the raw json returned by the elastic api.

AntonShuvaev commented 1 year ago

The table view is displayed only for the search requests. All other requests are displayed in JSON or plain text format depending on the response type. /_cat/* API response has compact and aligned text (CAT) format and is displayed in plain text view as it is. If you want to display the response in JSON format, you can use parameter /_cat/*?format=json.

lookingcloudy commented 1 year ago

Ok - thank you.