Skip to content
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

Add type murmur3 into the lens fields list #129029

Merged
merged 17 commits into from
Apr 12, 2022
Merged

Add type murmur3 into the lens fields list #129029

merged 17 commits into from
Apr 12, 2022

Conversation

ebuildy
Copy link
Contributor

@ebuildy ebuildy commented Mar 31, 2022

Summary

Related to issue #129007 (Fields of type murmur3 dont appear in the lens fields list).

This PR add field of type murmur3 in the fields listing for lens visualization.

Checklist

Delete any items that are not applicable to this PR.

Risk Matrix

For maintainers

@ebuildy ebuildy requested a review from a team as a code owner March 31, 2022 10:17
@kibanamachine
Copy link
Contributor

Since this is a community submitted pull request, a Jenkins build has not been kicked off automatically. Can an Elastic organization member please verify the contents of this patch and then kick off a build manually?

@flash1293
Copy link
Contributor

This is super unlucky timing, but 8.3 just got branched off and there's no snapshot builds yet for the elasticsearch plugins https://artifacts-api.elastic.co/v1/search/8.3.0-SNAPSHOT

They should become available soon, I will check daily and once they are built I will give it a test-run to see whether something breaks unexpectedly.

@flash1293 flash1293 self-assigned this Mar 31, 2022
@ebuildy
Copy link
Contributor Author

ebuildy commented Mar 31, 2022

it works like a charm! I have just understood the "operation" idea behind Lens, really clever!

So, I have only enabled murmur3 for cardinality operations.

Capture d’écran 2022-03-31 à 21 11 27

@flash1293
Copy link
Contributor

@elasticmachine merge upstream

@flash1293
Copy link
Contributor

flash1293 commented Apr 1, 2022

This looks pretty good already! Some rough edges I noticed:

Screenshot 2022-04-01 at 15 47 29

"Top values" don't really make any sense for murmur3 - we should opt out of fetching a field summary for this field type like we do for ranges:

} else if (field.type.includes('range')) {

The file icon is not exactly pretty, but I'm not sure which one to use, maybe tokenSearchType - @MichaelMarcialis do you have a suggestion? We would need to adjust it here:

murmur3: { iconType: 'tokenFile' },

Please do not add translations, there's a separate process for that, it will be handled outside of this PR.

@ebuildy
Copy link
Contributor Author

ebuildy commented Apr 4, 2022

We are using this fix on prod for 3 days now (we are using kibana v7.17.1), very happy with it!

I will squash commits when this is ready for review, thanks you.

@flash1293
Copy link
Contributor

@elasticmachine merge upstream

@flash1293
Copy link
Contributor

Buildkite, test this

@flash1293 flash1293 added enhancement New value added to drive a business result Team:Visualizations Visualization editors, elastic-charts and infrastructure Feature:Lens backport:skip This commit does not require backporting v8.3.0 labels Apr 4, 2022
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-vis-editors @elastic/kibana-vis-editors-external (Team:VisEditors)

@flash1293 flash1293 added release_note:enhancement and removed enhancement New value added to drive a business result labels Apr 4, 2022
@MichaelMarcialis
Copy link
Contributor

The file icon is not exactly pretty, but I'm not sure which one to use, maybe tokenSearchType - @MichaelMarcialis do you have a suggestion?

Given what we have available in our EUI tokens, I agree that tokenSearchType appears to be the best fit.

@flash1293
Copy link
Contributor

@ebuildy Could you adapt the icon for murmur3 in here?

murmur3: { iconType: 'tokenFile' },

Also there seems to be a small issue with the linting.

Apart from that I think we can get this PR ready to merge, thank you so much for your contribution 💚

I will squash commits when this is ready for review, thanks you.

No need to do that, Github will take care of it on merge.

@ebuildy ebuildy requested a review from a team as a code owner April 4, 2022 19:14
@ebuildy
Copy link
Contributor Author

ebuildy commented Apr 4, 2022

lint issue seem have been fixed / committed automatically

@flash1293
Copy link
Contributor

@elasticmachine merge upstream

@@ -460,7 +460,7 @@ function FieldItemPopoverContents(props: State & FieldItemProps) {

if (props.isLoading) {
return <EuiLoadingSpinner />;
} else if (field.type.includes('range')) {
} else if (field.type.includes('range') || field.type === 'murmur3') {
return (
<>
<EuiPopoverTitle>{panelHeader}</EuiPopoverTitle>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The message specifically calls out "range type fields" which doesn't match the murmur3 case. Could you add a separate branch for this case with a new i18n phrase Summary information is not available for murmur3 fields?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just went ahead and pushed this change

@flash1293
Copy link
Contributor

One last thing I noticed, otherwise this looks great! #129029 (comment)

@flash1293
Copy link
Contributor

Buildkite, test this.

@flash1293 flash1293 changed the title [draft] Add type murmur3 into the lens fields list Add type murmur3 into the lens fields list Apr 7, 2022
@flash1293
Copy link
Contributor

@elasticmachine merge upstream

@flash1293
Copy link
Contributor

Buildkite, test this

@flash1293
Copy link
Contributor

@elasticmachine run elasticsearch-ci/docs

@flash1293
Copy link
Contributor

@elasticmachine merge upstream

@flash1293
Copy link
Contributor

Buildkite, test this

@flash1293
Copy link
Contributor

@elasticmachine run elasticsearch-ci/docs

@kibana-ci
Copy link
Collaborator

💚 Build Succeeded

Metrics [docs]

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
dataVisualizer 539.6KB 539.6KB +6.0B
discover 407.0KB 407.0KB +12.0B
graph 476.8KB 476.8KB +6.0B
lens 1.0MB 1.0MB +403.0B
maps 2.7MB 2.7MB +6.0B
presentationUtil 136.8KB 136.8KB +6.0B
securitySolution 4.8MB 4.8MB +6.0B
stackAlerts 202.8KB 202.8KB +6.0B
total +451.0B

Page load bundle

Size of the bundles that are downloaded on every page load. Target size is below 100kb

id before after diff
osquery 16.2KB 16.2KB +6.0B

History

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

cc @flash1293

@flash1293
Copy link
Contributor

Apologies for taking this over a bit @ebuildy . Merging now as this looks fine, thanks for your contribution 💚

@flash1293 flash1293 merged commit 062be57 into elastic:main Apr 12, 2022
@ebuildy
Copy link
Contributor Author

ebuildy commented Apr 12, 2022

@flash1293 I see kibana is a really big project ^^ no worries, I am very happy about this feature.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport:skip This commit does not require backporting 💝community Feature:Lens release_note:enhancement Team:Visualizations Visualization editors, elastic-charts and infrastructure v8.3.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants