Skip to content

[Security Solution ] Unified Timeline - Enables unified components by default and inverts the feature flag. #187460

Merged
logeekal merged 15 commits intoelastic:mainfrom
logeekal:fix/unified_feature_flag_invert
Jul 15, 2024
Merged

[Security Solution ] Unified Timeline - Enables unified components by default and inverts the feature flag. #187460
logeekal merged 15 commits intoelastic:mainfrom
logeekal:fix/unified_feature_flag_invert

Conversation

@logeekal
Copy link
Copy Markdown
Contributor

@logeekal logeekal commented Jul 3, 2024

Summary

This PR inverts the feature flag from unifiedComponentsInTimelineEnabled to unifiedComponentsInTimelineDisabled with a defualt value of false.

  • This is done so that users have the option to turn off the unified components.
  • This also adapts all relevant jest and cypress tests to assume that unified components are enabled.

@logeekal logeekal added backport:skip This PR does not require backporting Team:Threat Hunting:Investigations Security Solution Threat Hunting Investigations Team v8.15.0 labels Jul 3, 2024
@logeekal
Copy link
Copy Markdown
Contributor Author

logeekal commented Jul 3, 2024

/ci

@logeekal
Copy link
Copy Markdown
Contributor Author

logeekal commented Jul 3, 2024

/ci

@logeekal
Copy link
Copy Markdown
Contributor Author

logeekal commented Jul 4, 2024

/ci

@logeekal
Copy link
Copy Markdown
Contributor Author

/ci

@logeekal logeekal marked this pull request as ready for review July 10, 2024 10:47
@logeekal logeekal requested review from a team as code owners July 10, 2024 10:47
@logeekal logeekal requested a review from xcrzx July 10, 2024 10:47
@elasticmachine
Copy link
Copy Markdown
Contributor

Pinging @elastic/security-threat-hunting-investigations (Team:Threat Hunting:Investigations)

@logeekal logeekal removed request for a team July 10, 2024 11:38
Copy link
Copy Markdown
Contributor

@PhilippeOberti PhilippeOberti left a comment

Choose a reason for hiding this comment

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

code LGTM for the Threat Hunting Investigations team!

One small note though, there are a few places in the code where you changed

const something = unifiedComponentsInTimelineEnabled ? this : that;

into

const something = !!unifiedComponentsInTimelineDisabled ? this : that;

but for readability I feel like this would be easier on the eye?

const something = unifiedComponentsInTimelineDisabled ? that : this;

But maybe that's just me...

@logeekal
Copy link
Copy Markdown
Contributor Author

logeekal commented Jul 10, 2024

@PhilippeOberti

One small note though, there are a few places in the code where you changed


const something = !!unifiedComponentsInTimelineDisabled ? this : that;

You are right. It is mistake most probably. I will change it. Thanks for the feedback.

@logeekal
Copy link
Copy Markdown
Contributor Author

/ci

@logeekal
Copy link
Copy Markdown
Contributor Author

logeekal commented Jul 11, 2024

const something = !!unifiedComponentsInTimelineDisabled ? this : that;

@PhilippeOberti , I could not find double exclamation in the code as you mentioned above. I think you meant single exclamation.

I kept it like it because it will be easier to remove as when removing we will automatically keep only the truthy value. ( because !unifiedComponentsInTimelineDisabled is the truth). That is why I kept it like this. Let me know if it makes sense.

Copy link
Copy Markdown
Contributor

@semd semd left a comment

Choose a reason for hiding this comment

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

LGTM!

Copy link
Copy Markdown
Contributor

@dplumlee dplumlee left a comment

Choose a reason for hiding this comment

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

Rule management changes lgtm!

@PhilippeOberti
Copy link
Copy Markdown
Contributor

const something = !!unifiedComponentsInTimelineDisabled ? this : that;

@PhilippeOberti , I could not find double exclamation in the code as you mentioned above. I think you meant single exclamation.

I kept it like it because it will be easier to remove as when removing we will automatically keep only the truthy value. ( because !unifiedComponentsInTimelineDisabled is the truth). That is why I kept it like this. Let me know if it makes sense.

I'm so sorry I didn't mean to have 2 exclamation marks. My original message was about switching !unifiedComponentsInTimelineDisabled to unifiedComponentsInTimelineDisabled as I felt the double negation was harder to read. But like you said it's meant to be short lived so it's ok!

@elasticmachine
Copy link
Copy Markdown
Contributor

⏳ Build in-progress, with failures

Failed CI Steps

Test Failures

  • [job] [logs] Jest Tests #8 / query tab with unified timeline columns should move column left/right correctly
  • [job] [logs] Jest Tests #8 / query tab with unified timeline columns should move column left/right correctly
  • [job] [logs] Jest Tests #8 / query tab with unified timeline columns should remove column
  • [job] [logs] Jest Tests #8 / query tab with unified timeline columns should remove column
  • [job] [logs] Jest Tests #8 / query tab with unified timeline columns should sort date column
  • [job] [logs] Jest Tests #8 / query tab with unified timeline columns should sort date column
  • [job] [logs] Jest Tests #8 / query tab with unified timeline columns should sort number column
  • [job] [logs] Jest Tests #8 / query tab with unified timeline columns should sort number column
  • [job] [logs] Jest Tests #8 / query tab with unified timeline columns should sort string column correctly
  • [job] [logs] Jest Tests #8 / query tab with unified timeline columns should sort string column correctly
  • [job] [logs] Jest Tests #8 / query tab with unified timeline Leading actions - notes securitySolutionNotesEnabled = false should have the notification dot & correct tooltip
  • [job] [logs] Jest Tests #8 / query tab with unified timeline Leading actions - notes securitySolutionNotesEnabled = false should have the notification dot & correct tooltip
  • [job] [logs] Jest Tests #8 / query tab with unified timeline Leading actions - notes securitySolutionNotesEnabled = true should be able to add notes through expandable flyout
  • [job] [logs] Jest Tests #8 / query tab with unified timeline Leading actions - notes securitySolutionNotesEnabled = true should be able to add notes through expandable flyout
  • [job] [logs] Jest Tests #8 / query tab with unified timeline Leading actions - notes securitySolutionNotesEnabled = true should have the notification dot & correct tooltip
  • [job] [logs] Jest Tests #8 / query tab with unified timeline Leading actions - notes securitySolutionNotesEnabled = true should have the notification dot & correct tooltip
  • [job] [logs] Jest Tests #8 / query tab with unified timeline left controls should be able to sort by multiple columns
  • [job] [logs] Jest Tests #8 / query tab with unified timeline left controls should be able to sort by multiple columns
  • [job] [logs] Jest Tests #8 / query tab with unified timeline left controls should clear all sorting
  • [job] [logs] Jest Tests #8 / query tab with unified timeline left controls should clear all sorting
  • [job] [logs] Jest Tests #8 / query tab with unified timeline pagination should load more records according to sample size correctly
  • [job] [logs] Jest Tests #8 / query tab with unified timeline pagination should load more records according to sample size correctly
  • [job] [logs] Jest Tests #8 / query tab with unified timeline pagination should paginate correctly
  • [job] [logs] Jest Tests #8 / query tab with unified timeline pagination should paginate correctly
  • [job] [logs] Jest Tests #8 / query tab with unified timeline render should hide row-renderers when disabled
  • [job] [logs] Jest Tests #8 / query tab with unified timeline render should hide row-renderers when disabled
  • [job] [logs] Jest Tests #8 / query tab with unified timeline render should render unified-field-list in timeline
  • [job] [logs] Jest Tests #8 / query tab with unified timeline render should render unified-field-list in timeline
  • [job] [logs] Jest Tests #8 / query tab with unified timeline render should render unifiedDataTable in timeline
  • [job] [logs] Jest Tests #8 / query tab with unified timeline render should render unifiedDataTable in timeline
  • [job] [logs] Jest Tests #8 / query tab with unified timeline render should show row-renderers correctly by default
  • [job] [logs] Jest Tests #8 / query tab with unified timeline render should show row-renderers correctly by default
  • [job] [logs] Jest Tests #8 / query tab with unified timeline unified fields list should add the column when clicked on ⊕ sign
  • [job] [logs] Jest Tests #8 / query tab with unified timeline unified fields list should add the column when clicked on ⊕ sign
  • [job] [logs] Jest Tests #8 / query tab with unified timeline unified fields list should remove the column when clicked on X sign
  • [job] [logs] Jest Tests #8 / query tab with unified timeline unified fields list should remove the column when clicked on X sign
  • [job] [logs] Jest Tests #8 / query tab with unified timeline unified fields list should should show callout when field search does not matches any field
  • [job] [logs] Jest Tests #8 / query tab with unified timeline unified fields list should should show callout when field search does not matches any field
  • [job] [logs] Jest Tests #8 / query tab with unified timeline unified fields list should toggle side bar correctly
  • [job] [logs] Jest Tests #8 / query tab with unified timeline unified fields list should toggle side bar correctly

History

'Unsaved Timeline query tab',
{
tags: ['@ess', '@serverless', '@skipInServerlessMKI'],
env: {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

If the FF is not needed anymore, consider to remove the @skipInServerlessMKI.

'Unified Timeline table Row Actions',
{
tags: ['@ess', '@serverless', '@skipInServerlessMKI'],
env: {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

If the FF is not needed anymore, consider to remove the @skipInServerlessMKI.

Copy link
Copy Markdown
Contributor

@paul-tavares paul-tavares left a comment

Choose a reason for hiding this comment

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

Changes owned by security-defend-workflows team looks good 👍

@kibanamachine
Copy link
Copy Markdown
Contributor

Flaky Test Runner Stats

🟠 Some tests failed. - kibana-flaky-test-suite-runner#6547

[✅] Security Solution Investigations - Cypress: 25/25 tests passed.
[❌] [Serverless] Security Solution Investigations - Cypress: 12/25 tests passed.

see run history

@logeekal
Copy link
Copy Markdown
Contributor Author

💚 All backports created successfully

Status Branch Result
8.15

Note: Successful backport PRs will be merged automatically after passing CI.

Questions ?

Please refer to the Backport tool documentation

@logeekal
Copy link
Copy Markdown
Contributor Author

💚 All backports created successfully

Status Branch Result
8.15

Note: Successful backport PRs will be merged automatically after passing CI.

Questions ?

Please refer to the Backport tool documentation

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

release_note:skip Skip the PR/issue when compiling release notes Team:Threat Hunting:Investigations Security Solution Threat Hunting Investigations Team v8.15.0 v8.16.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

8 participants