fbaligand / kibana-enhanced-table

Kibana visualization like a Data Table, but with enhanced features like computed columns, filter bar, and “Split Cols” bucket
Apache License 2.0
305 stars 65 forks source link

Suport for Kibana 8.9 in dev mode #330

Closed edmarmoretti closed 5 months ago

edmarmoretti commented 10 months ago

Hello.

I need to make changes to the tables (translation into Portuguese, for example) but I can't make the plugin work in a development environment.

I'm following the guidelines in the README and using Elasticsearch through the 'yarn es snapshot' command. When I remove the plugin from the kibana/plugins folder, Kibana starts correctly, however, when I add the plugin, Kibana does not start and presents an error message, as if Elasticsearch is not responding to requests.

Could you please help me.

fbaligand commented 10 months ago

Hi,

To make it work with Kibana 8.9.0, I strongly recommend you to use official elasticsearch package 8.9.0: https://www.elastic.co/fr/downloads/past-releases/elasticsearch-8-9-0

Or use Elasticsearch official Docker image: https://www.elastic.co/guide/en/elasticsearch/reference/current/docker.html

Concerning Kibana, I strongly recommend you to just checkout 8.9 branch and use the very last commit.

edmarmoretti commented 10 months ago

Hello. Unfortunately it didn't work. I tried in different ways and was unsuccessful. I can start Elasticsearch and Kibana but when I add the plugin and restart Kibana it stops working

fbaligand commented 10 months ago

Sad to hear that. Could you share the error message(s) you get in Kibana logs? Do you start Kibana in prod mode (official package provided by Elastic) or in dev mode (start from Kibana GitHub repository) ? If you use dev mode, could you list all the commands that you execute since "git clone https://github.com/elastic/kibana.git" ?

I say that to help you to find what's wrong.

fbaligand commented 10 months ago

By the way, I just published Enhanced Table package for Kibana 8.9.1 here: https://github.com/fbaligand/kibana-enhanced-table/releases/tag/v1.13.4

edmarmoretti commented 10 months ago

Thank you for your attention and support. Follow the sequence of commands. I'm using Ubuntu.

//terminal 1 git clone --depth 1 -b v8.9.1 https://github.com/elastic/kibana.git cd kibana nvm use yarn install yarn kbn bootstrap --no-validate

//other terminal yarn es snapshot

//terminal 1 yarn start

//open Kibana in Firefox - ok

// stop kibana and add plugin cd kibana/plugins git clone https://github.com/fbaligand/kibana-enhanced-table.git cd kibana-enhanced-table/ yarn install cd ../.. yarn start

//open kibana in Firefox - error Elastic did not load properly. Check the server output for more information.

//Firefox logs: O recurso de “http://localhost:5601/dbp/9007199254740991/bundles/plugin/enhancedTable/kibana/enhancedTable.plugin.js” foi bloqueado devido ao tipo MIME (“application/json”) não corresponder (X-Content-Type-Options: nosniff).

fbaligand commented 10 months ago

Thanks for sharing the commands you executed.

I recommend you to:

edmarmoretti commented 10 months ago

I ran the following sequence of commands, but it didn't work. Still with the same error message

git clone --depth 1 -b v8.9.1 https://github.com/elastic/kibana.git cd kibana/plugins git clone https://github.com/fbaligand/kibana-enhanced-table.git enhancedTable cd .. yarn kbn bootstrap cd plugins/enhancedTable yarn install yarn start

Browser message: Elastic did not load properly. Check the server output for more information.

fbaligand commented 10 months ago

Well, I'm very surprised, as it works fine for me, and also sad for you.

I have one last suggestion: when you clone, can you checkout 8.9 branch instead of v8.9.1? git clone --depth 1 -b 8.9 https://github.com/elastic/kibana.git

edmarmoretti commented 10 months ago

Thanks again for your attention. I did the "git clone" as you suggested, but I still get the same error message. In Chrome the message is more complete:

{"statusCode":401,"error":"Unauthorized","message":"missing authentication credentials for REST request [/.kibana_8.9.2/_doc/config%3A8.9.2]: security_exception\n\tRoot causes:\n\t\tsecurity_exception: missing authentication credentials for REST request [/.kibana_8.9.2/_doc/config%3A8.9.2]"}

fbaligand commented 10 months ago

Well the message seems to be very different. There’s nothing about enhanced table and error says that credentials are missing. Personally, in dev mode, I disable elasticsearch security and also https. That is in elasticsearch .yml.

edmarmoretti commented 10 months ago

Yes, but when I remove the plugin, Kibana works and this error message does not appear.

edmarmoretti commented 10 months ago

Security is disabled, I used the following parameters in the elasticsearch.yml file:

xpack.security.enabled: false
xpack.security.transport.ssl.enabled: false
xpack.security.http.ssl.enabled: false

The error message 'Elastic did not load properly. Check the server output for more information.' it continues to appear, but what calls attention is that in the console (firebug) the message appears

image

edmarmoretti commented 10 months ago

I found a similar problem

https://github.com/elastic/kibana/issues/157440

fbaligand commented 9 months ago

This issue is interesting. It gives me two ideas:

edmarmoretti commented 9 months ago

I have good news. The first option worked, after a few tries! I will review all the steps and share them here. I still need to test the process of changing the code and generating a new build. Thanks again.

image

fbaligand commented 9 months ago

Thanks for all your tests and all the time you spend on it. Once you shared the steps, I will update documentation.

edmarmoretti commented 9 months ago

This is the sequence of commands I used

git clone --depth 1 -b 8.9 https://github.com/elastic/kibana.git
cd kibana/plugins
git clone https://github.com/fbaligand/kibana-enhanced-table.git enhancedTable
cd enhancedTable
yarn install
cd ../..
nvm use
yarn kbn bootstrap
cd plugins/enhancedTable
yarn compile
yarn start
fbaligand commented 9 months ago

Great! Thanks for the share! I will update documentation in this way.

fbaligand commented 9 months ago

I just fixed documentation here: https://github.com/fbaligand/kibana-enhanced-table/#development

fbaligand commented 5 months ago

I close the issue as it is fixed