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

[Ingest Manager] Set _meta in the index.mappings #72026

Merged

Conversation

afharo
Copy link
Member

@afharo afharo commented Jul 16, 2020

Summary

Add the _meta payload to the template's mappings. This way it is copied over to the indices created based on that template (under mappings._meta).

This way, GET {DATASTREAM_NAME}/_mapping?filter_path=*.mappings._meta will return the indices created based of the data-stream and it will contain Ingest Manager's custom _meta for the UI to identify them.

Related to #71419 and #59195.

Checklist

Delete any items that are not applicable to this PR.

For maintainers

@afharo afharo added v8.0.0 Feature:EPM Fleet team's Elastic Package Manager (aka Integrations) project v7.10.0 labels Jul 16, 2020
@afharo afharo requested review from jfsiii and removed request for jfsiii July 16, 2020 10:23
@afharo afharo added the release_note:skip Skip the PR/issue when compiling release notes label Jul 16, 2020
@afharo afharo marked this pull request as ready for review July 16, 2020 13:04
@afharo afharo requested a review from a team July 16, 2020 13:04
@elasticmachine
Copy link
Contributor

Pinging @elastic/ingest-management (Feature:EPM)

@botelastic botelastic bot added the Team:Fleet Team label for Observability Data Collection Fleet team label Jul 16, 2020
@ph ph requested a review from neptunian July 16, 2020 13:07
@afharo
Copy link
Member Author

afharo commented Jul 20, 2020

@elasticmachine merge upstream

@kibanamachine
Copy link
Contributor

💛 Build succeeded, but was flaky


Test Failures

Kibana Pipeline / kibana-xpack-agent / X-Pack Endpoint Functional Tests.x-pack/test/security_solution_endpoint/apps/endpoint.endpoint "before all" hook in "endpoint"

Link to Jenkins

Standard Out

Failed Tests Reporter:
  - Test has not failed recently on tracked branches

[00:00:00]       │
[00:00:00]         └-: endpoint
[00:00:00]           └-> "before all" hook
[00:00:00]           └-> "before all" hook
[00:00:00]             │ info [o.e.c.m.MetadataCreateIndexService] [kibana-ci-immutable-ubuntu-16-tests-xl-1595240833054335465] [logs-index_pattern_placeholder] creating index, cause [api], templates [], shards [1]/[1]
[00:00:00]             │ info [o.e.c.m.MetadataCreateIndexService] [kibana-ci-immutable-ubuntu-16-tests-xl-1595240833054335465] [metrics-index_pattern_placeholder] creating index, cause [api], templates [], shards [1]/[1]
[00:00:00]             │ info [o.e.c.m.MetadataCreateIndexService] [kibana-ci-immutable-ubuntu-16-tests-xl-1595240833054335465] [events-index_pattern_placeholder] creating index, cause [api], templates [], shards [1]/[1]
[00:00:00]             │ proc [kibana]  error  [11:46:57.414] [warning][process] UnhandledPromiseRejectionWarning: Error: Cannot install or update to an out-of-date package
[00:00:00]             │ proc [kibana]     at installPackage (/dev/shm/workspace/install/kibana-8/x-pack/plugins/ingest_manager/server/services/epm/packages/install.js:127:82)
[00:00:00]             │ proc [kibana]     at process._tickCallback (internal/process/next_tick.js:68:7)
[00:00:00]             │ proc [kibana]     at emitWarning (internal/process/promises.js:97:15)
[00:00:00]             │ proc [kibana]     at emitPromiseRejectionWarnings (internal/process/promises.js:143:7)
[00:00:00]             │ proc [kibana]     at process._tickCallback (internal/process/next_tick.js:69:34)
[00:00:00]             │ proc [kibana]  error  [11:46:57.415] [warning][process] Error: Cannot install or update to an out-of-date package
[00:00:00]             │ proc [kibana]     at installPackage (/dev/shm/workspace/install/kibana-8/x-pack/plugins/ingest_manager/server/services/epm/packages/install.js:127:82)
[00:00:00]             │ proc [kibana]     at process._tickCallback (internal/process/next_tick.js:68:7)
[00:00:00]             │ info [o.e.x.s.a.r.TransportPutRoleAction] [kibana-ci-immutable-ubuntu-16-tests-xl-1595240833054335465] added role [fleet_enroll]
[00:00:00]             │ info [o.e.x.s.a.u.TransportPutUserAction] [kibana-ci-immutable-ubuntu-16-tests-xl-1595240833054335465] added user [fleet_enroll]
[00:00:00]             │ info Taking screenshot "/dev/shm/workspace/kibana/x-pack/test/functional/screenshots/failure/endpoint _before all_ hook.png"
[00:00:00]             │ proc [kibana]  error  [11:46:57.291]  Error: Internal Server Error
[00:00:00]             │ proc [kibana]     at HapiResponseAdapter.toError (/dev/shm/workspace/install/kibana-8/src/core/server/http/router/response_adapter.js:132:19)
[00:00:00]             │ proc [kibana]     at HapiResponseAdapter.toHapiResponse (/dev/shm/workspace/install/kibana-8/src/core/server/http/router/response_adapter.js:86:19)
[00:00:00]             │ proc [kibana]     at HapiResponseAdapter.handle (/dev/shm/workspace/install/kibana-8/src/core/server/http/router/response_adapter.js:81:17)
[00:00:00]             │ proc [kibana]     at Router.handle (/dev/shm/workspace/install/kibana-8/src/core/server/http/router/router.js:162:34)
[00:00:00]             │ proc [kibana]     at process._tickCallback (internal/process/next_tick.js:68:7)
[00:00:00]             │ info Current URL is: data:/,
[00:00:00]             │ info Saving page source to: /dev/shm/workspace/kibana/x-pack/test/functional/failure_debug/html/endpoint _before all_ hook.html
[00:00:00]             └- ✖ fail: endpoint "before all" hook in "endpoint"
[00:00:00]             │      Error: expected 200 "OK", got 500 "Internal Server Error"
[00:00:00]             │       at Test._assertStatus (/dev/shm/workspace/kibana/node_modules/supertest/lib/test.js:268:12)
[00:00:00]             │       at Test._assertFunction (/dev/shm/workspace/kibana/node_modules/supertest/lib/test.js:283:11)
[00:00:00]             │       at Test.assert (/dev/shm/workspace/kibana/node_modules/supertest/lib/test.js:173:18)
[00:00:00]             │       at assert (/dev/shm/workspace/kibana/node_modules/supertest/lib/test.js:131:12)
[00:00:00]             │       at /dev/shm/workspace/kibana/node_modules/supertest/lib/test.js:128:5
[00:00:00]             │       at Test.Request.callback (/dev/shm/workspace/kibana/node_modules/superagent/lib/node/index.js:718:3)
[00:00:00]             │       at parser (/dev/shm/workspace/kibana/node_modules/superagent/lib/node/index.js:906:18)
[00:00:00]             │       at IncomingMessage.res.on (/dev/shm/workspace/kibana/node_modules/superagent/lib/node/parsers/json.js:19:7)
[00:00:00]             │       at endReadableNT (_stream_readable.js:1145:12)
[00:00:00]             │       at process._tickCallback (internal/process/next_tick.js:63:19)
[00:00:00]             │ 
[00:00:00]             │ 

Stack Trace

Error: expected 200 "OK", got 500 "Internal Server Error"
    at Test._assertStatus (/dev/shm/workspace/kibana/node_modules/supertest/lib/test.js:268:12)
    at Test._assertFunction (/dev/shm/workspace/kibana/node_modules/supertest/lib/test.js:283:11)
    at Test.assert (/dev/shm/workspace/kibana/node_modules/supertest/lib/test.js:173:18)
    at assert (/dev/shm/workspace/kibana/node_modules/supertest/lib/test.js:131:12)
    at /dev/shm/workspace/kibana/node_modules/supertest/lib/test.js:128:5
    at Test.Request.callback (/dev/shm/workspace/kibana/node_modules/superagent/lib/node/index.js:718:3)
    at parser (/dev/shm/workspace/kibana/node_modules/superagent/lib/node/index.js:906:18)
    at IncomingMessage.res.on (/dev/shm/workspace/kibana/node_modules/superagent/lib/node/parsers/json.js:19:7)
    at endReadableNT (_stream_readable.js:1145:12)
    at process._tickCallback (internal/process/next_tick.js:63:19)

Build metrics

✅ unchanged

History

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

@afharo afharo merged commit f331cc8 into elastic:master Jul 20, 2020
@afharo afharo deleted the ingest_manager/set-_meta-in-index-mappings branch July 20, 2020 12:54
afharo added a commit to afharo/kibana that referenced this pull request Jul 20, 2020
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
afharo added a commit that referenced this pull request Jul 20, 2020
…2426)

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
afharo added a commit that referenced this pull request Jul 20, 2020
…2430)

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
gmmorris added a commit to gmmorris/kibana that referenced this pull request Jul 20, 2020
* master: (60 commits)
  [SIEM][Detection Engine][Lists] Adds list permissions (elastic#72335)
  [SIEM][Detection Engine][Lists] Adds conflict versioning and io-ts improvements to lists (elastic#72337)
  [Resolver] no longer pass related event stats to process node component (elastic#72435)
  Revert "skip flaky suite (elastic#72146)"
  [Security Solution] Cleanup endpoint telemetry (elastic#71950)
  Unskip dashboard embeddable rendering tests (elastic#71824)
  [ENDPOINT] Added unerolling status for host. (elastic#72303)
  [Alerting][Connectors] Increase the size of the logos (elastic#72419)
  [SECURITY] [Timeline] Raw events not displayed (elastic#72387)
  [ML] Fixes display of regression stop stats if one is NaN (elastic#72412)
  [Ingest Pipelines] Processor Editor Move Tooltip (elastic#72239)
  Fix match phrase and not match phrase comparators (elastic#71850)
  [Plugin Generator] Generate tsconfig and useDefaultBehaviors (elastic#72040)
  [Security Solution][Timeline] Fix timeline styling and createFrom beh… (elastic#72152)
  [Resolver] Selector performance (elastic#72380)
  [Ingest Manager] Set `_meta` in the index.mappings (elastic#72026)
  [Ingest Manager] Do not bumb config revision during config creation (elastic#72270)
  [ML] Adding missing index pattern name to new job wizards (elastic#72400)
  [ML] improve annotation flyout performance (elastic#72299)
  [APM] Testing error rate API and restructuring folders (elastic#72257)
  ...
gmmorris added a commit to gmmorris/kibana that referenced this pull request Jul 20, 2020
* master: (26 commits)
  [SIEM][Detection Engine][Lists] Adds list permissions (elastic#72335)
  [SIEM][Detection Engine][Lists] Adds conflict versioning and io-ts improvements to lists (elastic#72337)
  [Resolver] no longer pass related event stats to process node component (elastic#72435)
  Revert "skip flaky suite (elastic#72146)"
  [Security Solution] Cleanup endpoint telemetry (elastic#71950)
  Unskip dashboard embeddable rendering tests (elastic#71824)
  [ENDPOINT] Added unerolling status for host. (elastic#72303)
  [Alerting][Connectors] Increase the size of the logos (elastic#72419)
  [SECURITY] [Timeline] Raw events not displayed (elastic#72387)
  [ML] Fixes display of regression stop stats if one is NaN (elastic#72412)
  [Ingest Pipelines] Processor Editor Move Tooltip (elastic#72239)
  Fix match phrase and not match phrase comparators (elastic#71850)
  [Plugin Generator] Generate tsconfig and useDefaultBehaviors (elastic#72040)
  [Security Solution][Timeline] Fix timeline styling and createFrom beh… (elastic#72152)
  [Resolver] Selector performance (elastic#72380)
  [Ingest Manager] Set `_meta` in the index.mappings (elastic#72026)
  [Ingest Manager] Do not bumb config revision during config creation (elastic#72270)
  [ML] Adding missing index pattern name to new job wizards (elastic#72400)
  [ML] improve annotation flyout performance (elastic#72299)
  [APM] Testing error rate API and restructuring folders (elastic#72257)
  ...
gmmorris added a commit to gmmorris/kibana that referenced this pull request Jul 21, 2020
…feature-privileges

* alerting/consumer-based-rbac: (45 commits)
  fixed alerts test
  [SIEM][Detection Engine][Lists] Adds list permissions (elastic#72335)
  [SIEM][Detection Engine][Lists] Adds conflict versioning and io-ts improvements to lists (elastic#72337)
  [Resolver] no longer pass related event stats to process node component (elastic#72435)
  Revert "skip flaky suite (elastic#72146)"
  [Security Solution] Cleanup endpoint telemetry (elastic#71950)
  Unskip dashboard embeddable rendering tests (elastic#71824)
  [ENDPOINT] Added unerolling status for host. (elastic#72303)
  [Alerting][Connectors] Increase the size of the logos (elastic#72419)
  [SECURITY] [Timeline] Raw events not displayed (elastic#72387)
  [ML] Fixes display of regression stop stats if one is NaN (elastic#72412)
  [Ingest Pipelines] Processor Editor Move Tooltip (elastic#72239)
  Fix match phrase and not match phrase comparators (elastic#71850)
  [Plugin Generator] Generate tsconfig and useDefaultBehaviors (elastic#72040)
  [Security Solution][Timeline] Fix timeline styling and createFrom beh… (elastic#72152)
  allow user to disable alert even if they dont have privileges to the underlying action
  [Resolver] Selector performance (elastic#72380)
  [Ingest Manager] Set `_meta` in the index.mappings (elastic#72026)
  [Ingest Manager] Do not bumb config revision during config creation (elastic#72270)
  [ML] Adding missing index pattern name to new job wizards (elastic#72400)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature:EPM Fleet team's Elastic Package Manager (aka Integrations) project release_note:skip Skip the PR/issue when compiling release notes Team:Fleet Team label for Observability Data Collection Fleet team v7.9.0 v7.10.0 v8.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants