Skip to content

remove unused fields from the sourcerer hook result#206030

Merged
lgestc merged 4 commits intoelastic:mainfrom
lgestc:remove_unused_fields
Jan 15, 2025
Merged

remove unused fields from the sourcerer hook result#206030
lgestc merged 4 commits intoelastic:mainfrom
lgestc:remove_unused_fields

Conversation

@lgestc
Copy link
Contributor

@lgestc lgestc commented Jan 9, 2025

Summary

Some properties returned from this hook are no longer in the sourcerer model (and the declared result type).
This PR removes them.

@lgestc lgestc added Team:Threat Hunting:Investigations Security Solution Threat Hunting Investigations Team backport:skip This PR does not require backporting release_note:skip Skip the PR/issue when compiling release notes labels Jan 9, 2025
@elastic elastic deleted a comment from elasticmachine Jan 10, 2025
@elastic elastic deleted a comment from elasticmachine Jan 13, 2025
@lgestc lgestc marked this pull request as ready for review January 13, 2025 14:10
@lgestc lgestc requested a review from a team as a code owner January 13, 2025 14:10
@elasticmachine
Copy link
Contributor

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

@logeekal
Copy link
Contributor

@lgestc

I am just curious why there was no type error even though these fields do not exist in type. I tried to check and i am not sure what am i missing.

@elastic elastic deleted a comment from elasticmachine Jan 14, 2025
@lgestc lgestc force-pushed the remove_unused_fields branch from acf5623 to 789284d Compare January 14, 2025 12:47
@elastic elastic deleted a comment from elasticmachine Jan 14, 2025
@elasticmachine
Copy link
Contributor

💛 Build succeeded, but was flaky

Failed CI Steps

Test Failures

  • [job] [logs] x-pack/test/api_integration/deployment_agnostic/configs/serverless/oblt.serverless.config.ts / Serverless Observability - Deployment-agnostic API integration tests observability AI Assistant When there are knowledge base entries (from 8.15 or earlier) that does not contain semantic_text embeddings "after all" hook in "When there are knowledge base entries (from 8.15 or earlier) that does not contain semantic_text embeddings"
  • [job] [logs] x-pack/test/api_integration/deployment_agnostic/configs/serverless/oblt.serverless.config.ts / Serverless Observability - Deployment-agnostic API integration tests observability AI Assistant When there are knowledge base entries (from 8.15 or earlier) that does not contain semantic_text embeddings "before all" hook in "When there are knowledge base entries (from 8.15 or earlier) that does not contain semantic_text embeddings"

Metrics [docs]

Module Count

Fewer modules leads to a faster build time

id before after diff
threatIntelligence 138 139 +1

Async chunks

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

id before after diff
securitySolution 21.2MB 21.2MB -1.1KB
threatIntelligence 57.3KB 57.2KB -78.0B
total -1.1KB

Copy link
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.

nice cleanup! Code LGTM and I desk tested the Intelligence page.
I left one comment, feel free to ignore it as it is purely subjective!

@lgestc lgestc enabled auto-merge (squash) January 15, 2025 15:41
@lgestc lgestc merged commit da04c93 into elastic:main Jan 15, 2025
viduni94 pushed a commit to viduni94/kibana that referenced this pull request Jan 23, 2025
## Summary

Some properties returned from this hook are no longer in the sourcerer
model (and the declared result type).
This PR removes them.
christineweng pushed a commit to christineweng/kibana that referenced this pull request Jun 5, 2025
Some properties returned from this hook are no longer in the sourcerer
model (and the declared result type).
This PR removes them.
christineweng added a commit to christineweng/kibana that referenced this pull request Jun 5, 2025
Some properties returned from this hook are no longer in the sourcerer
model (and the declared result type).
This PR removes them.
christineweng pushed a commit to christineweng/kibana that referenced this pull request Jun 5, 2025
Some properties returned from this hook are no longer in the sourcerer
model (and the declared result type).
This PR removes them.
christineweng pushed a commit to christineweng/kibana that referenced this pull request Jun 5, 2025
Some properties returned from this hook are no longer in the sourcerer
model (and the declared result type).
This PR removes them.
christineweng added a commit that referenced this pull request Jun 6, 2025
…190113) And other sourcerer clean ups (#222889)

# Backport

This will backport the following commits from `main` to `8.19`:
- [[Security Solution] Remove index pattern field from Sourcerer
(#190113)](#190113)
- [remove unused fields from the sourcerer hook result
#206030](#206030)
- [[Security Solution][Sourcerer] Rename index pattern props to data
view #216542](#216542)

<!--- Backport version: 10.0.0 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sorenlouv/backport)

<!--BACKPORT [{"author":{"name":"Luke
Gmys","email":"11671118+lgestc@users.noreply.github.com"},"sourceCommit":{"committedDate":"2024-10-28T11:11:00Z","message":"[Security
Solution] Remove index pattern field from Sourcerer (#190113)\n\n##
Summary\r\n\r\nThis PR removes index pattern field from the sourcerer
model, replacing\r\nit with direct access to data view spec.\r\n\r\nThe
end goal for the sourcerer is to just utilize platform wide Data\r\nView
Types, instead of some custom abstractions / containers such
as\r\nindexPattern field which is effectively a DataViewSpec, just
packed
up\r\ndifferently.","sha":"a8048ddf6b3f6623c87236c875a0ef1506a39fe2","branchLabelMapping":{"^v9.0.0$":"main","^v8.17.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","backport:skip","v9.0.0","Team:Threat
Hunting:Investigations","Team:Threat
Hunting:Explore"],"title":"[Security Solution] Remove index pattern
field from
Sourcerer","number":190113,"url":"https://github.com/elastic/kibana/pull/190113","mergeCommit":{"message":"[Security
Solution] Remove index pattern field from Sourcerer (#190113)\n\n##
Summary\r\n\r\nThis PR removes index pattern field from the sourcerer
model, replacing\r\nit with direct access to data view spec.\r\n\r\nThe
end goal for the sourcerer is to just utilize platform wide Data\r\nView
Types, instead of some custom abstractions / containers such
as\r\nindexPattern field which is effectively a DataViewSpec, just
packed
up\r\ndifferently.","sha":"a8048ddf6b3f6623c87236c875a0ef1506a39fe2"}},"sourceBranch":"main","suggestedTargetBranches":[],"targetPullRequestStates":[{"branch":"main","label":"v9.0.0","branchLabelMappingKey":"^v9.0.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/190113","number":190113,"mergeCommit":{"message":"[Security
Solution] Remove index pattern field from Sourcerer (#190113)\n\n##
Summary\r\n\r\nThis PR removes index pattern field from the sourcerer
model, replacing\r\nit with direct access to data view spec.\r\n\r\nThe
end goal for the sourcerer is to just utilize platform wide Data\r\nView
Types, instead of some custom abstractions / containers such
as\r\nindexPattern field which is effectively a DataViewSpec, just
packed
up\r\ndifferently.","sha":"a8048ddf6b3f6623c87236c875a0ef1506a39fe2"}}]}]
BACKPORT-->

---------

Co-authored-by: Luke Gmys <11671118+lgestc@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport:skip This PR does not require backporting release_note:skip Skip the PR/issue when compiling release notes Team:Threat Hunting:Investigations Security Solution Threat Hunting Investigations Team v9.0.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants