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

[7.x] [Expressions] Refactor expression functions to use observables underneath (#100409) #101988

Merged
merged 1 commit into from
Jun 11, 2021

Conversation

dokmic
Copy link
Contributor

@dokmic dokmic commented Jun 11, 2021

Backports the following commits to 7.x:

@dokmic dokmic enabled auto-merge (squash) June 11, 2021 07:54
@kibanamachine
Copy link
Contributor

💛 Build succeeded, but was flaky


Test Failures

Kibana Pipeline / general / Chrome UI Functional Tests.test/functional/apps/discover/_sidebar·ts.discover app discover sidebar field filtering should reveal and hide the filter form when the toggle is clicked

Link to Jenkins

Standard Out

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

[00:00:00]       │
[00:09:42]         └-: discover app
[00:09:42]           └-> "before all" hook in "discover app"
[00:09:42]           └-> "before all" hook in "discover app"
[00:26:22]           └-: discover sidebar
[00:26:22]             └-> "before all" hook in "discover sidebar"
[00:26:22]             └-> "before all" hook in "discover sidebar"
[00:26:22]               │ info [test/functional/fixtures/es_archiver/logstash_functional] Loading "mappings.json"
[00:26:22]               │ info [test/functional/fixtures/es_archiver/logstash_functional] Loading "data.json.gz"
[00:26:22]               │ info [test/functional/fixtures/es_archiver/logstash_functional] Skipped restore for existing index "logstash-2015.09.22"
[00:26:22]               │ info [test/functional/fixtures/es_archiver/logstash_functional] Skipped restore for existing index "logstash-2015.09.20"
[00:26:22]               │ info [test/functional/fixtures/es_archiver/logstash_functional] Skipped restore for existing index "logstash-2015.09.21"
[00:26:23]               │ info [test/functional/fixtures/es_archiver/discover] Loading "mappings.json"
[00:26:23]               │ info [test/functional/fixtures/es_archiver/discover] Loading "data.json"
[00:26:23]               │ info [o.e.c.m.MetadataDeleteIndexService] [kibana-ci-immutable-ubuntu-16-tests-xxl-1623398128294952568] [.kibana_7.14.0_001/x8X5f1ZJTv20Xyk2UI7omw] deleting index
[00:26:23]               │ info [o.e.c.m.MetadataDeleteIndexService] [kibana-ci-immutable-ubuntu-16-tests-xxl-1623398128294952568] [.kibana_1/jr1qusTYSS6FsROcMAIDkg] deleting index
[00:26:23]               │ info [test/functional/fixtures/es_archiver/discover] Deleted existing index ".kibana_7.14.0_001"
[00:26:23]               │ info [test/functional/fixtures/es_archiver/discover] Deleted existing index ".kibana_1"
[00:26:23]               │ info [o.e.c.m.MetadataCreateIndexService] [kibana-ci-immutable-ubuntu-16-tests-xxl-1623398128294952568] [.kibana_7.14.0_001] creating index, cause [api], templates [], shards [1]/[0]
[00:26:23]               │ info [o.e.c.r.a.AllocationService] [kibana-ci-immutable-ubuntu-16-tests-xxl-1623398128294952568] Cluster health status changed from [YELLOW] to [GREEN] (reason: [shards started [[.kibana_7.14.0_001][0]]]).
[00:26:23]               │ info [test/functional/fixtures/es_archiver/discover] Created index ".kibana_7.14.0_001"
[00:26:23]               │ debg [test/functional/fixtures/es_archiver/discover] ".kibana_7.14.0_001" settings {"index":{"auto_expand_replicas":"0-1","number_of_replicas":"0","number_of_shards":"1","priority":"10","refresh_interval":"1s","routing_partition_size":"1"}}
[00:26:23]               │ info [test/functional/fixtures/es_archiver/discover] Indexed 2 docs into ".kibana"
[00:26:23]               │ debg Migrating saved objects
[00:26:23]               │ proc [kibana]   log   [08:41:19.171] [info][savedobjects-service] [.kibana] INIT -> OUTDATED_DOCUMENTS_SEARCH_OPEN_PIT. took: 6ms.
[00:26:23]               │ proc [kibana]   log   [08:41:19.176] [info][savedobjects-service] [.kibana] OUTDATED_DOCUMENTS_SEARCH_OPEN_PIT -> OUTDATED_DOCUMENTS_SEARCH_READ. took: 6ms.
[00:26:23]               │ proc [kibana]   log   [08:41:19.182] [info][savedobjects-service] [.kibana] OUTDATED_DOCUMENTS_SEARCH_READ -> OUTDATED_DOCUMENTS_SEARCH_CLOSE_PIT. took: 6ms.
[00:26:23]               │ proc [kibana]   log   [08:41:19.186] [info][savedobjects-service] [.kibana] OUTDATED_DOCUMENTS_SEARCH_CLOSE_PIT -> UPDATE_TARGET_MAPPINGS. took: 4ms.
[00:26:23]               │ proc [kibana]   log   [08:41:19.206] [info][savedobjects-service] [.kibana] UPDATE_TARGET_MAPPINGS -> UPDATE_TARGET_MAPPINGS_WAIT_FOR_TASK. took: 20ms.
[00:26:23]               │ info [o.e.t.LoggingTaskListener] [kibana-ci-immutable-ubuntu-16-tests-xxl-1623398128294952568] 13838 finished with response BulkByScrollResponse[took=15.8ms,timed_out=false,sliceId=null,updated=2,created=0,deleted=0,batches=1,versionConflicts=0,noops=0,retries=0,throttledUntil=0s,bulk_failures=[],search_failures=[]]
[00:26:23]               │ proc [kibana]   log   [08:41:19.312] [info][savedobjects-service] [.kibana] UPDATE_TARGET_MAPPINGS_WAIT_FOR_TASK -> DONE. took: 106ms.
[00:26:23]               │ proc [kibana]   log   [08:41:19.313] [info][savedobjects-service] [.kibana] Migration completed after 149ms
[00:26:23]               │ debg [test/functional/fixtures/es_archiver/discover] Migrated Kibana index after loading Kibana data
[00:26:23]               │ debg applying update to kibana config: {"accessibility:disableAnimations":true,"dateFormat:tz":"UTC","visualization:visualize:legacyChartsLibrary":true}
[00:26:23]               │ info [o.e.c.m.MetadataMappingService] [kibana-ci-immutable-ubuntu-16-tests-xxl-1623398128294952568] [.kibana_7.14.0_001/G1NJmmJwR1qUAuVdd1M28Q] update_mapping [_doc]
[00:26:25]               │ debg applying update to kibana config: {"accessibility:disableAnimations":true,"dateFormat:tz":"UTC","visualization:visualize:legacyChartsLibrary":true}
[00:26:26]               │ debg replacing kibana config doc: {"defaultIndex":"logstash-*"}
[00:26:27]               │ debg applying update to kibana config: {"timepicker:timeDefaults":"{ \"from\": \"2015-09-18T06:31:44.000Z\", \"to\": \"2015-09-23T18:31:44.000Z\"}"}
[00:26:27]               │ info [o.e.c.m.MetadataMappingService] [kibana-ci-immutable-ubuntu-16-tests-xxl-1623398128294952568] [.kibana_7.14.0_001/G1NJmmJwR1qUAuVdd1M28Q] update_mapping [_doc]
[00:26:28]               │ debg navigating to discover url: http://localhost:61191/app/discover#/
[00:26:28]               │ debg navigate to: http://localhost:61191/app/discover#/
[00:26:28]               │ debg browser[INFO] http://localhost:61191/app/discover?_t=1623400884154#/ 339 Refused to execute inline script because it violates the following Content Security Policy directive: "script-src 'unsafe-eval' 'self'". Either the 'unsafe-inline' keyword, a hash ('sha256-P5polb1UreUSOe5V/Pv7tc+yeZuJXiOi/3fqhGsU7BE='), or a nonce ('nonce-...') is required to enable inline execution.
[00:26:28]               │
[00:26:28]               │ debg browser[INFO] http://localhost:61191/bootstrap.js 41:19 "^ A single error about an inline script not firing due to content security policy is expected!"
[00:26:28]               │ debg ... sleep(700) start
[00:26:29]               │ debg ... sleep(700) end
[00:26:29]               │ debg returned from get, calling refresh
[00:26:30]               │ debg browser[INFO] http://localhost:61191/app/discover?_t=1623400884154#/ 339 Refused to execute inline script because it violates the following Content Security Policy directive: "script-src 'unsafe-eval' 'self'". Either the 'unsafe-inline' keyword, a hash ('sha256-P5polb1UreUSOe5V/Pv7tc+yeZuJXiOi/3fqhGsU7BE='), or a nonce ('nonce-...') is required to enable inline execution.
[00:26:30]               │
[00:26:30]               │ debg browser[INFO] http://localhost:61191/bootstrap.js 41:19 "^ A single error about an inline script not firing due to content security policy is expected!"
[00:26:30]               │ debg currentUrl = http://localhost:61191/app/discover#/
[00:26:30]               │          appUrl = http://localhost:61191/app/discover#/
[00:26:30]               │ debg TestSubjects.find(kibanaChrome)
[00:26:30]               │ debg Find.findByCssSelector('[data-test-subj="kibanaChrome"]') with timeout=60000
[00:26:30]               │ debg ... sleep(501) start
[00:26:31]               │ debg ... sleep(501) end
[00:26:31]               │ debg in navigateTo url = http://localhost:61191/app/discover#/?_g=(filters:!(),refreshInterval:(pause:!t,value:0),time:(from:%272015-09-18T06:31:44.000Z%27,to:%272015-09-23T18:31:44.000Z%27))&_a=(columns:!(),filters:!(),index:%27logstash-*%27,interval:auto,query:(language:kuery,query:%27%27),sort:!(!(%27@timestamp%27,desc)))
[00:26:31]               │ debg --- retry.tryForTime error: URL changed, waiting for it to settle
[00:26:31]               │ debg ... sleep(501) start
[00:26:32]               │ debg ... sleep(501) end
[00:26:32]               │ debg in navigateTo url = http://localhost:61191/app/discover#/?_g=(filters:!(),refreshInterval:(pause:!t,value:0),time:(from:%272015-09-18T06:31:44.000Z%27,to:%272015-09-23T18:31:44.000Z%27))&_a=(columns:!(),filters:!(),index:%27logstash-*%27,interval:auto,query:(language:kuery,query:%27%27),sort:!(!(%27@timestamp%27,desc)))
[00:26:32]             └-: field filtering
[00:26:32]               └-> "before all" hook for "should reveal and hide the filter form when the toggle is clicked"
[00:26:32]               └-> should reveal and hide the filter form when the toggle is clicked
[00:26:32]                 └-> "before each" hook: global before each for "should reveal and hide the filter form when the toggle is clicked"
[00:26:32]                 │ debg TestSubjects.click(toggleFieldFilterButton)
[00:26:32]                 │ debg Find.clickByCssSelector('[data-test-subj="toggleFieldFilterButton"]') with timeout=10000
[00:26:32]                 │ debg Find.findByCssSelector('[data-test-subj="toggleFieldFilterButton"]') with timeout=10000
[00:26:32]                 │ debg TestSubjects.exists(filterSelectionPanel)
[00:26:32]                 │ debg Find.existsByDisplayedByCssSelector('[data-test-subj="filterSelectionPanel"]') with timeout=120000
[00:26:32]                 │ debg TestSubjects.click(toggleFieldFilterButton)
[00:26:32]                 │ debg Find.clickByCssSelector('[data-test-subj="toggleFieldFilterButton"]') with timeout=10000
[00:26:32]                 │ debg Find.findByCssSelector('[data-test-subj="toggleFieldFilterButton"]') with timeout=10000
[00:26:32]                 │ debg TestSubjects.missingOrFail(filterSelectionPanel)
[00:26:32]                 │ debg Find.waitForDeletedByCssSelector('[data-test-subj="filterSelectionPanel"]') with timeout=2500
[00:26:35]                 │ info Taking screenshot "/dev/shm/workspace/parallel/19/kibana/test/functional/screenshots/failure/discover app discover sidebar field filtering should reveal and hide the filter form when the toggle is clicked.png"
[00:26:35]                 │ info Current URL is: http://localhost:61191/app/discover#/?_g=(filters:!(),refreshInterval:(pause:!t,value:0),time:(from:%272015-09-18T06:31:44.000Z%27,to:%272015-09-23T18:31:44.000Z%27))&_a=(columns:!(),filters:!(),index:%27logstash-*%27,interval:auto,query:(language:kuery,query:%27%27),sort:!(!(%27@timestamp%27,desc)))
[00:26:35]                 │ info Saving page source to: /dev/shm/workspace/parallel/19/kibana/test/functional/failure_debug/html/discover app discover sidebar field filtering should reveal and hide the filter form when the toggle is clicked.html
[00:26:35]                 └- ✖ fail: discover app discover sidebar field filtering should reveal and hide the filter form when the toggle is clicked
[00:26:35]                 │      TimeoutError: The element [data-test-subj="filterSelectionPanel"] was still present when it should have disappeared.
[00:26:35]                 │ Wait timed out after 2869ms
[00:26:35]                 │       at /dev/shm/workspace/parallel/19/kibana/node_modules/selenium-webdriver/lib/webdriver.js:842:17
[00:26:35]                 │       at runMicrotasks (<anonymous>)
[00:26:35]                 │       at processTicksAndRejections (internal/process/task_queues.js:95:5)
[00:26:35]                 │ 
[00:26:35]                 │ 

Stack Trace

TimeoutError: The element [data-test-subj="filterSelectionPanel"] was still present when it should have disappeared.
Wait timed out after 2869ms
    at /dev/shm/workspace/parallel/19/kibana/node_modules/selenium-webdriver/lib/webdriver.js:842:17
    at runMicrotasks (<anonymous>)
    at processTicksAndRejections (internal/process/task_queues.js:95:5) {
  remoteStacktrace: ''
}

Metrics [docs]

Async chunks

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

id before after diff
canvas 1.3MB 1.3MB +2.0B

Page load bundle

Size of the bundles that are downloaded on every page load. Target size is below 100kb

id before after diff
canvas 529.6KB 529.9KB +285.0B
expressions 202.4KB 202.7KB +281.0B
total +566.0B

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

@dokmic dokmic merged commit f09704d into elastic:7.x Jun 11, 2021
@dokmic dokmic deleted the backport/7.x/pr-100409 branch June 11, 2021 10:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants