* move configuration validation to NP
* update generated docs
* fix integration test
* ensure correct prototype for custom error
* typealiases KibanaConfig to LegacyConfig
* migrate test file to ts
* move getUnusedConfigKeys to NP
* method no longer async
* getUnusedConfigKeys: switch to named arguments
* introduce CriticalError error type
* create service skeleton
* move registerCapabilitiesModifier to capabilities service and rename to registerCapabilitiesSwitcher
* starts to move capabilities logic to CapabilitiesService
* move capabilities route to service
* add initial integration test for capabilities route
* capabilitiesMixin now delegates to capability service
* use server-side Capabilities import in server code
* update generated doc
* remove capabilities from injectedMetadatas
* use applications sent from client instead of server-registered navLinks
* disable authRequired for capabilities route
* (temp) exposes two endpoints for capabilities
* Add fetch-mock on capabilities call for karma tests
* adapt xpack Capabilities test - first attempt
* adapt x-pack ui_capabilities test
* add '/status' to the list of anonymous pages
* Add documentation on Capabilities APIs
* move Capabilities to core/types
* update generated docs
* add service tests
* protecting resolveCapabilities against added/removed capabilities
* update generated docs
* adapt mocks due to rebase
* add forgotten exports
* improve capabilities routes registering
* name capabilities registering methods
* resolve conflicts due to merge
* address review issues
* add comment about reason for exposing two routes
* extract createHttpServer test helper
* fix merge conflicts
* improve documentation
* remove `/status` anon registration as now done in NP status plugin
* fix merge conflicts
Set up the APM public NP plugin to expose the stack version
Since we're not yet running as an NP plugin, we don't get passed a pluginInitializerContext,
so we use a shim in the plugin setup that gets the branch values from ui/metadata for the time being.
Fixes#49327.
* [APM] getInjectedVars shim
Set up the APM public NP plugin to expose the config variables on its context,
and replace use of getInjectedVars with that.
Since we're not yet running as an NP plugin, we don't get passed a `pluginInitializerContext`,
so we use a shim in the plugin setup that gets the config values from injected vars for the time being.
Also:
* Move toggle app link in nav shim to plugin setup
* Replace the routes exported from Main/route_config with a function that takes a configuration object
* Experimenting with delay in test startup
* Move firefox tests sooner becuase they take a long time to run
* Move functional test parallel process delay to a spot that should work better for flaky test runner
* [ML] Adds functional tests for the index based data visualizer
* [ML] Address comments from review on data viz tests
* [ML] Skip data visualizer functional tests on Firefox
* Make a copy of index_patterns module inside NP
* Sync changes of index patterns
* Remove UI component from service
* Remove redundant exports from index_patterns
* Sync old index_patters changes
* Make common namespace of IndexPattern
* Make re-exports of old IndexPatter dependencies
* Remove utils and error of the old indexPattern
* Plug InterPatternService in data plugin
* Make shortenDotString in new data plugin
* Remove field folder
* Fix wrong merge
* Remove index_pattern folder
* Remove _LEGACY from service
* Remove static code from service
* Fix start contract
* Remove services from the old plugin
* Remove index_patterns_service
* Fix filter.meta.index type
* Fix reviews
* Fix type error
Shims discover app within local angular instance (or so called inner angular in the code) to enable migration to the new platform without getting rid of all Angular. Note that apart from Discover's main app, also context, doc view and embeddable are part of this shim.
There a 2 sorts of local angular used, one for the main plugin, and a slimmer one for it's embeddable, that's needed to render the data table. Both are built on first demand.
There are 2 changes of URLs inside
/context/ becomes /discover/context
/doc/ becomes /discover/doc
Legacy url's are redirected, so they are still valid.
The main goal of this PR is to get rid of explorer_controller.js to unblock the migration to react-router. Previously we already used rxjs observables to migrate away from angular events. Observables were used to trigger actions to manage the react component's state as well as AppState. This PR builds upon this previous work. The actions already were done similar to redux, now the use of observables has been extended to use scan (see rxjs docs) which allows us to transform the actions into state updates.