Skip to content

[7.x] Adapt es-archiver to call _migrate endpoint instead of creating a migrator (#56971)#58575

Merged
pgayvallet merged 1 commit intoelastic:7.xfrom
pgayvallet:backport/7.x/pr-56971
Feb 26, 2020
Merged

[7.x] Adapt es-archiver to call _migrate endpoint instead of creating a migrator (#56971)#58575
pgayvallet merged 1 commit intoelastic:7.xfrom
pgayvallet:backport/7.x/pr-56971

Conversation

@pgayvallet
Copy link
Copy Markdown
Contributor

Backports the following commits to 7.x:

…igrator (elastic#56971)

* es-archiver call _migrate endpoint instead of creating a migrator

* fix crlf....

* use promise instead of callback accessor

* attempt with disabled authent

* enable security again

* set mapping to dynamic before calling migration endpoint

* rename space data from non-spaced tests

* add documentation on the `rerun` flag

* create router with the `/api/saved_objects` prefix

* add unit test about strict mapping

* add integration test on migrate endpoint

* wrap route handler with handleLegacyErrors

* add remark about limitations of the rerun flag

* Apply suggestions from code review

Co-Authored-By: Aleh Zasypkin <aleh.zasypkin@gmail.com>

* do not return detailed index result

* add access tag to migrate route

* use /internal prefix for migrate endpoint

* fix integ tests

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
Co-authored-by: Josh Dover <me@joshdover.com>
Co-authored-by: Aleh Zasypkin <aleh.zasypkin@gmail.com>
@pgayvallet pgayvallet added the backport This PR is a backport of another PR label Feb 26, 2020
@kibanamachine
Copy link
Copy Markdown
Contributor

💛 Build succeeded, but was flaky


Test Failures

Kibana Pipeline / kibana-xpack-agent / X-Pack API Integration Tests.x-pack/test/api_integration/apis/uptime/graphql/monitor_states·ts.apis uptime graphql monitor states monitor state scoping query document scoping with mismatched check statuses should return all IPs

Link to Jenkins

Standard Out

Failed Tests Reporter:
  - Test has failed 2 times on tracked branches: https://github.com/elastic/kibana/issues/58558

[00:00:00]       │
[00:00:00]         └-: apis
[00:00:00]           └-> "before all" hook
[00:05:47]           └-: uptime
[00:05:47]             └-> "before all" hook
[00:05:47]             └-> "before all" hook
[00:05:54]             └-: graphql
[00:05:54]               └-> "before all" hook
[00:05:56]               └-: monitor states
[00:05:56]                 └-> "before all" hook
[00:06:00]                 └-: monitor state scoping
[00:06:00]                   └-> "before all" hook
[00:06:00]                   └-> "before all" hook: load heartbeat data
[00:06:00]                     │ info [uptime/blank] Loading "mappings.json"
[00:06:00]                     │ info [uptime/blank] Loading "data.json"
[00:06:00]                     │ info [o.e.c.m.MetaDataCreateIndexService] [kibana-ci-immutable-oraclelinux-tests-xl-1582710042093263841] [heartbeat-8-test] creating index, cause [api], templates [], shards [1]/[1], mappings [_doc]
[00:06:00]                     │ info [uptime/blank] Created index "heartbeat-8-test"
[00:06:00]                     │ debg [uptime/blank] "heartbeat-8-test" settings {"index":{"mapping":{"total_fields":{"limit":"10000"}},"number_of_replicas":"1","number_of_shards":"1","query":{"default_field":["message","tags","agent.ephemeral_id","agent.id","agent.name","agent.type","agent.version","as.organization.name","client.address","client.as.organization.name","client.domain","client.geo.city_name","client.geo.continent_name","client.geo.country_iso_code","client.geo.country_name","client.geo.name","client.geo.region_iso_code","client.geo.region_name","client.mac","client.user.domain","client.user.email","client.user.full_name","client.user.group.id","client.user.group.name","client.user.hash","client.user.id","client.user.name","cloud.account.id","cloud.availability_zone","cloud.instance.id","cloud.instance.name","cloud.machine.type","cloud.provider","cloud.region","container.id","container.image.name","container.image.tag","container.name","container.runtime","destination.address","destination.as.organization.name","destination.domain","destination.geo.city_name","destination.geo.continent_name","destination.geo.country_iso_code","destination.geo.country_name","destination.geo.name","destination.geo.region_iso_code","destination.geo.region_name","destination.mac","destination.user.domain","destination.user.email","destination.user.full_name","destination.user.group.id","destination.user.group.name","destination.user.hash","destination.user.id","destination.user.name","dns.answers.class","dns.answers.data","dns.answers.name","dns.answers.type","dns.header_flags","dns.id","dns.op_code","dns.question.class","dns.question.name","dns.question.registered_domain","dns.question.type","dns.response_code","dns.type","ecs.version","error.code","error.id","error.message","event.action","event.category","event.code","event.dataset","event.hash","event.id","event.kind","event.module","event.original","event.outcome","event.provider","event.timezone","event.type","file.device","file.directory","file.extension","file.gid","file.group","file.hash.md5","file.hash.sha1","file.hash.sha256","file.hash.sha512","file.inode","file.mode","file.name","file.owner","file.path","file.target_path","file.type","file.uid","geo.city_name","geo.continent_name","geo.country_iso_code","geo.country_name","geo.name","geo.region_iso_code","geo.region_name","group.id","group.name","hash.md5","hash.sha1","hash.sha256","hash.sha512","host.architecture","host.geo.city_name","host.geo.continent_name","host.geo.country_iso_code","host.geo.country_name","host.geo.name","host.geo.region_iso_code","host.geo.region_name","host.hostname","host.id","host.mac","host.name","host.os.family","host.os.full","host.os.kernel","host.os.name","host.os.platform","host.os.version","host.type","host.user.domain","host.user.email","host.user.full_name","host.user.group.id","host.user.group.name","host.user.hash","host.user.id","host.user.name","http.request.body.content","http.request.method","http.request.referrer","http.response.body.content","http.version","log.level","log.logger","log.original","network.application","network.community_id","network.direction","network.iana_number","network.name","network.protocol","network.transport","network.type","observer.geo.city_name","observer.geo.continent_name","observer.geo.country_iso_code","observer.geo.country_name","observer.geo.name","observer.geo.region_iso_code","observer.geo.region_name","observer.hostname","observer.mac","observer.os.family","observer.os.full","observer.os.kernel","observer.os.name","observer.os.platform","observer.os.version","observer.serial_number","observer.type","observer.vendor","observer.version","organization.id","organization.name","os.family","os.full","os.kernel","os.name","os.platform","os.version","process.args","process.executable","process.hash.md5","process.hash.sha1","process.hash.sha256","process.hash.sha512","process.name","process.thread.name","process.title","process.working_directory","server.address","server.as.organization.name","server.domain","server.geo.city_name","server.geo.continent_name","server.geo.country_iso_code","server.geo.country_name","server.geo.name","server.geo.region_iso_code","server.geo.region_name","server.mac","server.user.domain","server.user.email","server.user.full_name","server.user.group.id","server.user.group.name","server.user.hash","server.user.id","server.user.name","service.ephemeral_id","service.id","service.name","service.state","service.type","service.version","source.address","source.as.organization.name","source.domain","source.geo.city_name","source.geo.continent_name","source.geo.country_iso_code","source.geo.country_name","source.geo.name","source.geo.region_iso_code","source.geo.region_name","source.mac","source.user.domain","source.user.email","source.user.full_name","source.user.group.id","source.user.group.name","source.user.hash","source.user.id","source.user.name","tracing.trace.id","tracing.transaction.id","url.domain","url.fragment","url.full","url.original","url.password","url.path","url.query","url.scheme","url.username","user.domain","user.email","user.full_name","user.group.id","user.group.name","user.hash","user.id","user.name","user_agent.device.name","user_agent.name","user_agent.original","user_agent.os.family","user_agent.os.full","user_agent.os.kernel","user_agent.os.name","user_agent.os.platform","user_agent.os.version","user_agent.version","agent.hostname","error.type","timeseries.instance","cloud.project.id","cloud.image.id","host.os.build","host.os.codename","kubernetes.pod.name","kubernetes.pod.uid","kubernetes.namespace","kubernetes.node.name","kubernetes.replicaset.name","kubernetes.deployment.name","kubernetes.statefulset.name","kubernetes.container.name","kubernetes.container.image","jolokia.agent.version","jolokia.agent.id","jolokia.server.product","jolokia.server.version","jolokia.server.vendor","jolokia.url","monitor.type","monitor.name","monitor.id","monitor.status","monitor.check_group","http.response.body.hash","fields.*"]},"refresh_interval":"5s"}}
[00:06:00]                   └-: query document scoping with mismatched check statuses
[00:06:00]                     └-> "before all" hook
[00:06:00]                     └-> "before all" hook
[00:06:00]                     └-> should return all IPs
[00:06:00]                       └-> "before each" hook: global before each
[00:06:00]                       └- ✖ fail: "apis uptime graphql monitor states monitor state scoping query document scoping with mismatched check statuses should return all IPs"
[00:06:00]                       │

Stack Trace

TypeError: Cannot read property 'state' of undefined
    at Context.it (test/api_integration/apis/uptime/graphql/monitor_states.ts:126:42)

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

@pgayvallet pgayvallet merged commit b9fa2f7 into elastic:7.x Feb 26, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport This PR is a backport of another PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants