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

[SIEM] Fixes cypress build by removing alerting version within the saved object data.json.gz #73550

Merged
merged 1 commit into from
Jul 28, 2020

Conversation

FrankHassanabad
Copy link
Contributor

@FrankHassanabad FrankHassanabad commented Jul 28, 2020

Summary

Fixes cypress build by removing alerting version within the saved objects

Fix within the binary is:

84,86d83
<       "migrationVersion": {
<         "alert": "7.9.0"
<       },

That removes the error which was during Cypress test runs when it would start up it blows up with this error:

11:38:23        info [o.e.c.r.a.AllocationService] [kibana-ci-immutable-debian-tests-xl-1595955761968494513] updating number_of_replicas to [0] for indices [.kibana_2]
11:38:23        proc [kibana]   log   [17:38:22.774] [info][savedobjects-service] Migrating .kibana_1 saved objects to .kibana_2
11:38:23        proc [kibana] /dev/shm/workspace/install/kibana-/src/core/server/saved_objects/migrations/core/document_migrator.js:261
11:38:23        proc [kibana]       throw _boom.default.badData(`Document "${doc.id}" has property "${p}" which belongs to a more recent` + ` version of Kibana [${docVersion}]. The last known version is [${latestVersion}]`, doc);
11:38:23        proc [kibana]       ^
11:38:23        proc [kibana] 
11:38:23        proc [kibana] Error: Document "a4772daa-a3ef-44a3-8035-6abd1bf2893a" has property "alert" which belongs to a more recent version of Kibana [7.9.0]. The last known version is [undefined]
11:38:23        proc [kibana]     at props.find.p (/dev/shm/workspace/install/kibana-/src/core/server/saved_objects/migrations/core/document_migrator.js:261:27)
11:38:23        proc [kibana]     at Array.find (<anonymous>)
11:38:23        proc [kibana]     at nextUnmigratedProp (/dev/shm/workspace/install/kibana-/src/core/server/saved_objects/migrations/core/document_migrator.js:247:21)
11:38:23        proc [kibana]     at applyMigrations (/dev/shm/workspace/install/kibana-/src/core/server/saved_objects/migrations/core/document_migrator.js:175:18)
11:38:23        proc [kibana]     at DocumentMigrator.transformAndValidate [as transformDoc] (/dev/shm/workspace/install/kibana-/src/core/server/saved_objects/migrations/core/document_migrator.js:160:43)
11:38:23        proc [kibana]     at DocumentMigrator.doc (/dev/shm/workspace/install/kibana-/src/core/server/saved_objects/migrations/core/document_migrator.js:53:19)
11:38:23        proc [kibana]     at Immediate.setImmediate (/dev/shm/workspace/install/kibana-/src/core/server/saved_objects/migrations/core/migrate_raw_docs.js:75:15)
11:38:23        proc [kibana]     at runCallback (timers.js:705:18)
11:38:23        proc [kibana]     at tryOnImmediate (timers.js:676:5)
11:38:23        proc [kibana]     at processImmediate (timers.js:658:5)

This is related to this PR which removes the migration which was used to set that version information but then removed:
#73420

Checklist

…ect that causes migration issue while the cypress tests run
@FrankHassanabad FrankHassanabad changed the title [SIEM] Fixes cypress build by removing alerting version within the saved obj… [SIEM] Fixes cypress build by removing alerting version within the saved object data.json.gz Jul 28, 2020
@FrankHassanabad FrankHassanabad self-assigned this Jul 28, 2020
@FrankHassanabad FrankHassanabad added v8.0.0 v7.9.0 release_note:skip Skip the PR/issue when compiling release notes labels Jul 28, 2020
@elasticmachine
Copy link
Contributor

Pinging @elastic/siem (Team:SIEM)

@rylnd
Copy link
Contributor

rylnd commented Jul 28, 2020

For posterity, here's the diff of the unzipped JSON (diff data.json.old data.json.new):

84,86d83
<       "migrationVersion": {
<         "alert": "7.9.0"
<       },

Copy link
Contributor

@rylnd rylnd left a comment

Choose a reason for hiding this comment

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

Change looks simple enough, let's see if CI agrees!

@tylersmalley
Copy link
Contributor

@tylersmalley
Copy link
Contributor

It passed cypress tests, so merging to unblock CI. Thanks for the PR!

@tylersmalley tylersmalley merged commit d57a379 into elastic:master Jul 28, 2020
tylersmalley pushed a commit that referenced this pull request Jul 28, 2020
…ect that causes migration issue while the cypress tests run (#73550)
@tylersmalley
Copy link
Contributor

7.x/7.10: fcbbbf5
7.9: pending, as there are conflicts

@kibanamachine
Copy link
Contributor

💚 Build Succeeded

Build metrics

✅ unchanged

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

@FrankHassanabad FrankHassanabad deleted the fix-cypress-build branch July 29, 2020 00:18
@FrankHassanabad
Copy link
Contributor Author

Backport is here for 7.9:
#73564

@FrankHassanabad FrankHassanabad added the backport:skip This commit does not require backporting label Jul 29, 2020
@FrankHassanabad
Copy link
Contributor Author

Added skip backport label just in case so the bot doesn't bother us.

@elasticmachine
Copy link
Contributor

Pinging @elastic/security-solution (Team: SecuritySolution)

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 release_note:skip Skip the PR/issue when compiling release notes Team: SecuritySolution Security Solutions Team working on SIEM, Endpoint, Timeline, Resolver, etc. Team:SIEM v7.9.0 v7.10.0 v8.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants