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

[Synthtrace][Inventory] K8s entities support #197077

Merged
merged 8 commits into from
Oct 22, 2024

Conversation

cauemarcondes
Copy link
Contributor

@cauemarcondes cauemarcondes commented Oct 21, 2024

Part of #196155

New Synthtrace scenario created: k8s_entities.ts

node scripts/synthtrace k8s_entities.ts --clean --live

Cluster sample data:

 {
        "_index": ".entities.v1.latest.builtin_kubernetes_cluster_ecss_from_ecs_data",
        "_id": "2060900000000000",
        "_score": 1,
        "_source": {
          "entity": {
            "type": "kubernetes_cluster_ecs",
            "id": "2060900000000000",
            "definitionId": "builtin_kubernetes_cluster_ecs",
            "displayName": "cluster_foo",
            "lastSeenTimestamp": "2024-10-21T16:15:17.570Z"
          },
          "orchestrator": {
            "cluster": {
              "name": "cluster_foo"
            }
          },
          "event": {
            "ingested": "2024-10-21T16:15:17.570Z"
          }
        }
      },
      {
        "_index": ".entities.v1.latest.builtin_kubernetes_cluster_semconvs_from_ecs_data",
        "_id": "2060900000000000",
        "_score": 1,
        "_source": {
          "entity": {
            "type": "kubernetes_cluster_semconv",
            "id": "2060900000000000",
            "definitionId": "builtin_kubernetes_cluster_semconv",
            "displayName": "cluster_foo",
            "lastSeenTimestamp": "2024-10-21T16:15:17.570Z"
          },
          "k8s": {
            "cluster": {
              "uid": "cluster_foo"
            }
          },
          "event": {
            "ingested": "2024-10-21T16:15:17.570Z"
          }
        }
      },

@cauemarcondes cauemarcondes added release_note:skip Skip the PR/issue when compiling release notes backport:prev-minor Backport to (8.x) the previous minor version (i.e. one version back from main) v8.17.0 labels Oct 21, 2024
@cauemarcondes cauemarcondes marked this pull request as ready for review October 21, 2024 15:02
@cauemarcondes cauemarcondes requested review from a team as code owners October 21, 2024 15:02
@botelastic botelastic bot added ci:project-deploy-observability Create an Observability project Team:obs-ux-infra_services Observability Infrastructure & Services User Experience Team labels Oct 21, 2024
@elasticmachine
Copy link
Contributor

Pinging @elastic/obs-ux-infra_services-team (Team:obs-ux-infra_services)

Copy link
Contributor

🤖 GitHub comments

Expand to view the GitHub comments

Just comment with:

  • /oblt-deploy : Deploy a Kibana instance using the Observability test environments.
  • run docs-build : Re-trigger the docs validation. (use unformatted text in the comment!)

Copy link
Contributor

@crespocarlos crespocarlos left a comment

Choose a reason for hiding this comment

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

LGTM

@cauemarcondes cauemarcondes enabled auto-merge (squash) October 22, 2024 08:34
@elasticmachine
Copy link
Contributor

elasticmachine commented Oct 22, 2024

💛 Build succeeded, but was flaky

  • Buildkite Build
  • Commit: d82f134
  • Kibana Serverless Image: docker.elastic.co/kibana-ci/kibana-serverless:pr-197077-d82f134a4f57

Failed CI Steps

Metrics [docs]

Public APIs missing comments

Total count of every public API that lacks a comment. Target amount is 0. Run node scripts/build_api_docs --plugin [yourplugin] --stats comments for more detailed information.

id before after diff
@kbn/apm-synthtrace-client 247 268 +21

Public APIs missing exports

Total count of every type that is part of your API that should be exported but is not. This will cause broken links in the API documentation system. Target amount is 0. Run node scripts/build_api_docs --plugin [yourplugin] --stats exports for more detailed information.

id before after diff
@kbn/apm-synthtrace-client 36 38 +2
Unknown metric groups

API count

id before after diff
@kbn/apm-synthtrace-client 247 268 +21

History

@cauemarcondes cauemarcondes merged commit 5e40320 into elastic:main Oct 22, 2024
26 checks passed
@cauemarcondes cauemarcondes deleted the inventory-k8s-entities branch October 22, 2024 15:43
@kibanamachine
Copy link
Contributor

Starting backport for target branches: 8.x

https://github.com/elastic/kibana/actions/runs/11463747839

kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Oct 22, 2024
Part of elastic#196155

New Synthtrace scenario created:
[k8s_entities.ts](https://github.com/elastic/kibana/pull/197077/files#diff-33a935a5fb8848d743e40d89b018ed8ac82ae992c0778cd6cea072d091aa0647)

```
node scripts/synthtrace k8s_entities.ts --clean --live
```

Cluster sample data:
```
 {
        "_index": ".entities.v1.latest.builtin_kubernetes_cluster_ecss_from_ecs_data",
        "_id": "2060900000000000",
        "_score": 1,
        "_source": {
          "entity": {
            "type": "kubernetes_cluster_ecs",
            "id": "2060900000000000",
            "definitionId": "builtin_kubernetes_cluster_ecs",
            "displayName": "cluster_foo",
            "lastSeenTimestamp": "2024-10-21T16:15:17.570Z"
          },
          "orchestrator": {
            "cluster": {
              "name": "cluster_foo"
            }
          },
          "event": {
            "ingested": "2024-10-21T16:15:17.570Z"
          }
        }
      },
      {
        "_index": ".entities.v1.latest.builtin_kubernetes_cluster_semconvs_from_ecs_data",
        "_id": "2060900000000000",
        "_score": 1,
        "_source": {
          "entity": {
            "type": "kubernetes_cluster_semconv",
            "id": "2060900000000000",
            "definitionId": "builtin_kubernetes_cluster_semconv",
            "displayName": "cluster_foo",
            "lastSeenTimestamp": "2024-10-21T16:15:17.570Z"
          },
          "k8s": {
            "cluster": {
              "uid": "cluster_foo"
            }
          },
          "event": {
            "ingested": "2024-10-21T16:15:17.570Z"
          }
        }
      },
```

(cherry picked from commit 5e40320)
@kibanamachine
Copy link
Contributor

💚 All backports created successfully

Status Branch Result
8.x

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

Questions ?

Please refer to the Backport tool documentation

@kibanamachine kibanamachine added the backport missing Added to PRs automatically when the are determined to be missing a backport. label Oct 24, 2024
@kibanamachine
Copy link
Contributor

Looks like this PR has a backport PR but it still hasn't been merged. Please merge it ASAP to keep the branches relatively in sync.

5 similar comments
@kibanamachine
Copy link
Contributor

Looks like this PR has a backport PR but it still hasn't been merged. Please merge it ASAP to keep the branches relatively in sync.

@kibanamachine
Copy link
Contributor

Looks like this PR has a backport PR but it still hasn't been merged. Please merge it ASAP to keep the branches relatively in sync.

@kibanamachine
Copy link
Contributor

Looks like this PR has a backport PR but it still hasn't been merged. Please merge it ASAP to keep the branches relatively in sync.

@kibanamachine
Copy link
Contributor

Looks like this PR has a backport PR but it still hasn't been merged. Please merge it ASAP to keep the branches relatively in sync.

@kibanamachine
Copy link
Contributor

Looks like this PR has a backport PR but it still hasn't been merged. Please merge it ASAP to keep the branches relatively in sync.

kibanamachine added a commit that referenced this pull request Nov 1, 2024
# Backport

This will backport the following commits from `main` to `8.x`:
- [[Synthtrace][Inventory] K8s entities support
(#197077)](#197077)

<!--- Backport version: 9.4.3 -->

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

<!--BACKPORT [{"author":{"name":"Cauê
Marcondes","email":"[email protected]"},"sourceCommit":{"committedDate":"2024-10-22T15:43:29Z","message":"[Synthtrace][Inventory]
K8s entities support (#197077)\n\nPart of
https://github.com/elastic/kibana/issues/196155\r\n\r\nNew Synthtrace
scenario
created:\r\n[k8s_entities.ts](https://github.com/elastic/kibana/pull/197077/files#diff-33a935a5fb8848d743e40d89b018ed8ac82ae992c0778cd6cea072d091aa0647)\r\n\r\n```\r\nnode
scripts/synthtrace k8s_entities.ts --clean
--live\r\n```\r\n\r\n\r\nCluster sample data:\r\n```\r\n {\r\n
\"_index\":
\".entities.v1.latest.builtin_kubernetes_cluster_ecss_from_ecs_data\",\r\n
\"_id\": \"2060900000000000\",\r\n \"_score\": 1,\r\n \"_source\": {\r\n
\"entity\": {\r\n \"type\": \"kubernetes_cluster_ecs\",\r\n \"id\":
\"2060900000000000\",\r\n \"definitionId\":
\"builtin_kubernetes_cluster_ecs\",\r\n \"displayName\":
\"cluster_foo\",\r\n \"lastSeenTimestamp\":
\"2024-10-21T16:15:17.570Z\"\r\n },\r\n \"orchestrator\": {\r\n
\"cluster\": {\r\n \"name\": \"cluster_foo\"\r\n }\r\n },\r\n \"event\":
{\r\n \"ingested\": \"2024-10-21T16:15:17.570Z\"\r\n }\r\n }\r\n },\r\n
{\r\n \"_index\":
\".entities.v1.latest.builtin_kubernetes_cluster_semconvs_from_ecs_data\",\r\n
\"_id\": \"2060900000000000\",\r\n \"_score\": 1,\r\n \"_source\": {\r\n
\"entity\": {\r\n \"type\": \"kubernetes_cluster_semconv\",\r\n \"id\":
\"2060900000000000\",\r\n \"definitionId\":
\"builtin_kubernetes_cluster_semconv\",\r\n \"displayName\":
\"cluster_foo\",\r\n \"lastSeenTimestamp\":
\"2024-10-21T16:15:17.570Z\"\r\n },\r\n \"k8s\": {\r\n \"cluster\":
{\r\n \"uid\": \"cluster_foo\"\r\n }\r\n },\r\n \"event\": {\r\n
\"ingested\": \"2024-10-21T16:15:17.570Z\"\r\n }\r\n }\r\n
},\r\n```","sha":"5e40320d9fe2d2c0b676071edf011c5831d43662","branchLabelMapping":{"^v9.0.0$":"main","^v8.17.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","v9.0.0","backport:prev-minor","ci:project-deploy-observability","Team:obs-ux-infra_services","v8.17.0"],"title":"[Synthtrace][Inventory]
K8s entities
support","number":197077,"url":"https://github.com/elastic/kibana/pull/197077","mergeCommit":{"message":"[Synthtrace][Inventory]
K8s entities support (#197077)\n\nPart of
https://github.com/elastic/kibana/issues/196155\r\n\r\nNew Synthtrace
scenario
created:\r\n[k8s_entities.ts](https://github.com/elastic/kibana/pull/197077/files#diff-33a935a5fb8848d743e40d89b018ed8ac82ae992c0778cd6cea072d091aa0647)\r\n\r\n```\r\nnode
scripts/synthtrace k8s_entities.ts --clean
--live\r\n```\r\n\r\n\r\nCluster sample data:\r\n```\r\n {\r\n
\"_index\":
\".entities.v1.latest.builtin_kubernetes_cluster_ecss_from_ecs_data\",\r\n
\"_id\": \"2060900000000000\",\r\n \"_score\": 1,\r\n \"_source\": {\r\n
\"entity\": {\r\n \"type\": \"kubernetes_cluster_ecs\",\r\n \"id\":
\"2060900000000000\",\r\n \"definitionId\":
\"builtin_kubernetes_cluster_ecs\",\r\n \"displayName\":
\"cluster_foo\",\r\n \"lastSeenTimestamp\":
\"2024-10-21T16:15:17.570Z\"\r\n },\r\n \"orchestrator\": {\r\n
\"cluster\": {\r\n \"name\": \"cluster_foo\"\r\n }\r\n },\r\n \"event\":
{\r\n \"ingested\": \"2024-10-21T16:15:17.570Z\"\r\n }\r\n }\r\n },\r\n
{\r\n \"_index\":
\".entities.v1.latest.builtin_kubernetes_cluster_semconvs_from_ecs_data\",\r\n
\"_id\": \"2060900000000000\",\r\n \"_score\": 1,\r\n \"_source\": {\r\n
\"entity\": {\r\n \"type\": \"kubernetes_cluster_semconv\",\r\n \"id\":
\"2060900000000000\",\r\n \"definitionId\":
\"builtin_kubernetes_cluster_semconv\",\r\n \"displayName\":
\"cluster_foo\",\r\n \"lastSeenTimestamp\":
\"2024-10-21T16:15:17.570Z\"\r\n },\r\n \"k8s\": {\r\n \"cluster\":
{\r\n \"uid\": \"cluster_foo\"\r\n }\r\n },\r\n \"event\": {\r\n
\"ingested\": \"2024-10-21T16:15:17.570Z\"\r\n }\r\n }\r\n
},\r\n```","sha":"5e40320d9fe2d2c0b676071edf011c5831d43662"}},"sourceBranch":"main","suggestedTargetBranches":["8.x"],"targetPullRequestStates":[{"branch":"main","label":"v9.0.0","branchLabelMappingKey":"^v9.0.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/197077","number":197077,"mergeCommit":{"message":"[Synthtrace][Inventory]
K8s entities support (#197077)\n\nPart of
https://github.com/elastic/kibana/issues/196155\r\n\r\nNew Synthtrace
scenario
created:\r\n[k8s_entities.ts](https://github.com/elastic/kibana/pull/197077/files#diff-33a935a5fb8848d743e40d89b018ed8ac82ae992c0778cd6cea072d091aa0647)\r\n\r\n```\r\nnode
scripts/synthtrace k8s_entities.ts --clean
--live\r\n```\r\n\r\n\r\nCluster sample data:\r\n```\r\n {\r\n
\"_index\":
\".entities.v1.latest.builtin_kubernetes_cluster_ecss_from_ecs_data\",\r\n
\"_id\": \"2060900000000000\",\r\n \"_score\": 1,\r\n \"_source\": {\r\n
\"entity\": {\r\n \"type\": \"kubernetes_cluster_ecs\",\r\n \"id\":
\"2060900000000000\",\r\n \"definitionId\":
\"builtin_kubernetes_cluster_ecs\",\r\n \"displayName\":
\"cluster_foo\",\r\n \"lastSeenTimestamp\":
\"2024-10-21T16:15:17.570Z\"\r\n },\r\n \"orchestrator\": {\r\n
\"cluster\": {\r\n \"name\": \"cluster_foo\"\r\n }\r\n },\r\n \"event\":
{\r\n \"ingested\": \"2024-10-21T16:15:17.570Z\"\r\n }\r\n }\r\n },\r\n
{\r\n \"_index\":
\".entities.v1.latest.builtin_kubernetes_cluster_semconvs_from_ecs_data\",\r\n
\"_id\": \"2060900000000000\",\r\n \"_score\": 1,\r\n \"_source\": {\r\n
\"entity\": {\r\n \"type\": \"kubernetes_cluster_semconv\",\r\n \"id\":
\"2060900000000000\",\r\n \"definitionId\":
\"builtin_kubernetes_cluster_semconv\",\r\n \"displayName\":
\"cluster_foo\",\r\n \"lastSeenTimestamp\":
\"2024-10-21T16:15:17.570Z\"\r\n },\r\n \"k8s\": {\r\n \"cluster\":
{\r\n \"uid\": \"cluster_foo\"\r\n }\r\n },\r\n \"event\": {\r\n
\"ingested\": \"2024-10-21T16:15:17.570Z\"\r\n }\r\n }\r\n
},\r\n```","sha":"5e40320d9fe2d2c0b676071edf011c5831d43662"}},{"branch":"8.x","label":"v8.17.0","branchLabelMappingKey":"^v8.17.0$","isSourceBranch":false,"state":"NOT_CREATED"}]}]
BACKPORT-->

Co-authored-by: Cauê Marcondes <[email protected]>
@kibanamachine kibanamachine removed the backport missing Added to PRs automatically when the are determined to be missing a backport. label Nov 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport:prev-minor Backport to (8.x) the previous minor version (i.e. one version back from main) ci:project-deploy-observability Create an Observability project release_note:skip Skip the PR/issue when compiling release notes Team:obs-ux-infra_services Observability Infrastructure & Services User Experience Team v8.17.0 v9.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants