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

move oss features registration to KP #66524

Merged
merged 11 commits into from
May 15, 2020

Conversation

mshustov
Copy link
Contributor

@mshustov mshustov commented May 14, 2020

Summary

Moves OSS feature registration to the KP.
Fix #65461

Checklist

Delete any items that are not applicable to this PR.

For maintainers

Dev Docs

Fixed bug not allowing Features plugin getFeatures method to be invoked within the Start lifecycle.

@mshustov mshustov added Team:Core Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc Feature:New Platform v7.9.0 labels May 14, 2020
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-platform (Team:Platform)

@mshustov mshustov added release_note:skip Skip the PR/issue when compiling release notes chore labels May 14, 2020
@mshustov mshustov force-pushed the move-feature-registraion-kp branch from e429320 to c9ebc3a Compare May 14, 2020 09:26
const registry = savedObjects.getTypeRegistry();
const savedObjectTypes = registry
.getAllTypes()
.filter(t => !t.hidden)
Copy link
Contributor Author

Choose a reason for hiding this comment

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

@pgayvallet I wrongly assumed that getAllTypes should return already filtered types, as savedObjects.type did in LP. Do we consider it's a problem that a plugin can expose all types to a consumer?

Copy link
Contributor

Choose a reason for hiding this comment

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

When we use the type registry in the repository we need to know all types, but I think consumers of this API should usually only operate on types that are visible so I think it would make sense to make that the default. If we have a use case where this should be exposed outside of core we could have an option like includedHiddenTypes: true

Copy link
Contributor

@pgayvallet pgayvallet May 15, 2020

Choose a reason for hiding this comment

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

I named it getAllTypes in an attempt to distinguish it from the legacy types, but it's probably not enough and jsdoc is lacking.

const service = {
types: visibleTypes,

It shouldn't be a problem for a plugin to access / expose all types to a consumer. AFAIK, hidden types were already consumed in legacy, but for different usages, via the schema property that contains both visible and hidden types. Also I think some consumers need to access all types, even if I can't remember exactly for which usages, probably security/spaces)

However I agree that 1/ the jsdoc for getAllTypes should be more explicit, and 2/ the type registry should have a getVisibleTypes method.

I will create a issue for that improvement

Copy link
Contributor

Choose a reason for hiding this comment

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

created #66818

@mshustov mshustov added release_note:plugin_api_changes Contains a Plugin API changes section for the breaking plugin API changes section. and removed release_note:skip Skip the PR/issue when compiling release notes labels May 14, 2020
@mshustov mshustov marked this pull request as ready for review May 14, 2020 14:23
@mshustov mshustov requested review from a team as code owners May 14, 2020 14:23
@mshustov
Copy link
Contributor Author

@elasticmachine merge upstream

1 similar comment
@mshustov
Copy link
Contributor Author

@elasticmachine merge upstream

Copy link
Contributor

@jonathan-buttner jonathan-buttner left a comment

Choose a reason for hiding this comment

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

Endpoint change lgtm

Copy link
Contributor

@pgayvallet pgayvallet left a comment

Choose a reason for hiding this comment

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

LGTM

`);
});

it('returns OSS + registered features with timielion when available', async () => {
Copy link
Contributor

Choose a reason for hiding this comment

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

typo: timielion

const registry = savedObjects.getTypeRegistry();
const savedObjectTypes = registry
.getAllTypes()
.filter(t => !t.hidden)
Copy link
Contributor

@pgayvallet pgayvallet May 15, 2020

Choose a reason for hiding this comment

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

I named it getAllTypes in an attempt to distinguish it from the legacy types, but it's probably not enough and jsdoc is lacking.

const service = {
types: visibleTypes,

It shouldn't be a problem for a plugin to access / expose all types to a consumer. AFAIK, hidden types were already consumed in legacy, but for different usages, via the schema property that contains both visible and hidden types. Also I think some consumers need to access all types, even if I can't remember exactly for which usages, probably security/spaces)

However I agree that 1/ the jsdoc for getAllTypes should be more explicit, and 2/ the type registry should have a getVisibleTypes method.

I will create a issue for that improvement

@mshustov mshustov force-pushed the move-feature-registraion-kp branch from e6b497c to 0b45f68 Compare May 15, 2020 15:26
@@ -37,7 +35,8 @@ export function defineRoutes({ router, featureRegistry, getLegacyAPI }: RouteDef
request.query.ignoreValidLicenses ||
!feature.validLicenses ||
!feature.validLicenses.length ||
getLegacyAPI().xpackInfo.license.isOneOf(feature.validLicenses)
(context.licensing!.license.type &&
Copy link
Contributor

@FrankHassanabad FrankHassanabad May 15, 2020

Choose a reason for hiding this comment

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

Did you want the ! or the ? type here? Isn't ? the safe one where instead of turning off the type assertion it will resolve all of this as null/undefined rather than causing a null pointer exception.

Copy link
Contributor Author

@mshustov mshustov May 15, 2020

Choose a reason for hiding this comment

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

I want ! here. License is always available, otherwise features plugin won't start without licensing plugin. There is no way in our typings to mark a field as required.

Copy link
Contributor

@FrankHassanabad FrankHassanabad left a comment

Choose a reason for hiding this comment

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

LGTM from a representative of SIEM, just left one comment about the bang operator but I am fine if it runs correctly and tests pass so that is an optional question I left.

@mshustov mshustov merged commit 915ff5d into elastic:master May 15, 2020
@mshustov mshustov deleted the move-feature-registraion-kp branch May 15, 2020 18:01
mshustov added a commit to mshustov/kibana that referenced this pull request May 15, 2020
* register OSS features with KP SO types only

* use Licensing plugin API in features plugin

* add plugin tests

* filter hidden types out

* cleanup tests

* rename

* add degug logging

* add warning for setup contract

* fix typo
gmmorris added a commit to gmmorris/kibana that referenced this pull request May 15, 2020
* master: (191 commits)
  [Maps] Get number of categories from palette (elastic#66454)
  move oss features registration to KP (elastic#66524)
  [kbn/plugin-helpers] typescript-ify (elastic#66513)
  Add kibana-operations as codeowners for .ci/es-snapshots and vars/ (elastic#66746)
  FTR: move basic services under common folder (elastic#66563)
  Migrate Beats Management UI to KP (elastic#65791)
  [CI] Add 20 minutes to overall build timeout
  lint import from restricted zones for export exressions (elastic#66588)
  [SIEM][Detection Engine] Add validation for Rule Actions (elastic#63332)
  KP plugins shouldn't need package.json (elastic#66654)
  Replace agent metrics link with the new one (elastic#66632)
  [CI] Add one retry to setup step (elastic#66638)
  [CI] Add slack alerts to tracked branch jobs, change default channel, change formatting (elastic#66580)
  [docLinks] Add docLinks to CoreSetup. (elastic#66631)
  [DOCS] Rename monitoring collection from internal to legacy (elastic#65781)
  unskip newsfeed tests (elastic#66562)
  [NP] Migrate uiSettings owned by Kibana app (elastic#64321)
  [ML] Functional tests - stabilize typing in DFA mml input (elastic#66706)
  [Map] return bounding box for static feature collection without joins (elastic#66607)
  remove trailing slash in graph sample data links (elastic#66358)
  ...
mshustov added a commit that referenced this pull request May 16, 2020
* register OSS features with KP SO types only

* use Licensing plugin API in features plugin

* add plugin tests

* filter hidden types out

* cleanup tests

* rename

* add degug logging

* add warning for setup contract

* fix typo
jloleysens added a commit that referenced this pull request May 18, 2020
…ine-editor

* 'master' of github.com:elastic/kibana: (157 commits)
  [ML] fix url assertion (#66850)
  Skip failing lens test(s). #66779
  [SOM] Preserve saved object references when saving the object (#66584)
  Use ES API from start contract (#66157)
  Reorganize Management apps into Ingest, Data, Alerts and Insights, Security, Kibana, and Stack groups (#65796)
  [Uptime] Fix flaky navigation to certs page in tests (#66806)
  [Maps] Do not check count for blended layers when layer is not visible (#66460)
  [SIEM] Fixes glob patterns from directory changes recently for GraphQL
  chore(NA): bump static-fs to 1.0.2 (#66775)
  [Maps] Handle cross cluster index _settings resp (#66797)
  [SIEM][Lists] Adds 90% of the REST API and client API for exception lists and exception items
  allow any type for customResponseHeaders config (#66689)
  [APM] Disable map layout animation (#66763)
  [ML] Add linking to dataframe from job management tab (#65778)
  [Maps] Get number of categories from palette (#66454)
  move oss features registration to KP (#66524)
  [kbn/plugin-helpers] typescript-ify (#66513)
  Add kibana-operations as codeowners for .ci/es-snapshots and vars/ (#66746)
  FTR: move basic services under common folder (#66563)
  Migrate Beats Management UI to KP (#65791)
  ...

# Conflicts:
#	x-pack/plugins/ingest_pipelines/public/application/components/pipeline_form/pipeline_form.tsx
#	x-pack/plugins/ingest_pipelines/public/application/components/pipeline_form/pipeline_form_fields.tsx
@kibanamachine
Copy link
Contributor

💔 Build Failed

Failed CI Steps


Test Failures

Kibana Pipeline / kibana-intake-agent / Jest Integration Tests.packages/kbn-optimizer/src/integration_tests.builds expected bundles, saves bundle counts to metadata

Link to Jenkins

Standard Out

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


Stack Trace

Error: expected optimizer to produce two or three "running" states, states: [ { state:
     { phase: 'initializing',
       compilerStates: [],
       offlineBundles: [],
       onlineBundles: [],
       startTime: 1596549988523,
       durSec: 0 } },
  { event:
     { type: 'bundle not cached',
       reason: 'missing optimizer cache key',
       bundle:
        Bundle {
          type: 'plugin',
          id: 'bar',
          entry: './public/index',
          contextDir:
           '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar',
          sourceRoot:
           '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo',
          outputDir:
           '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/target/public',
          cache:
           BundleCache {
             path:
              '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/target/public/.kbn-optimizer-cache',
             state: {} } } },
    state:
     { phase: 'initializing',
       compilerStates: [],
       offlineBundles:
        [ Bundle {
            type: 'plugin',
            id: 'foo',
            entry: './public/index',
            contextDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo',
            sourceRoot:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo',
            outputDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/target/public',
            cache:
             BundleCache {
               path:
                '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/target/public/.kbn-optimizer-cache',
               state: {} } } ],
       onlineBundles:
        [ Bundle {
            type: 'plugin',
            id: 'bar',
            entry: './public/index',
            contextDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar',
            sourceRoot:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo',
            outputDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/target/public',
            cache:
             BundleCache {
               path:
                '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/target/public/.kbn-optimizer-cache',
               state: {} } } ],
       startTime: 1596549988523,
       durSec: 0.1 } },
  { event:
     { type: 'bundle not cached',
       reason: 'missing optimizer cache key',
       bundle:
        Bundle {
          type: 'plugin',
          id: 'foo',
          entry: './public/index',
          contextDir:
           '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo',
          sourceRoot:
           '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo',
          outputDir:
           '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/target/public',
          cache:
           BundleCache {
             path:
              '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/target/public/.kbn-optimizer-cache',
             state: {} } } },
    state:
     { phase: 'initializing',
       compilerStates: [],
       offlineBundles: [],
       onlineBundles:
        [ Bundle {
            type: 'plugin',
            id: 'bar',
            entry: './public/index',
            contextDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar',
            sourceRoot:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo',
            outputDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/target/public',
            cache:
             BundleCache {
               path:
                '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/target/public/.kbn-optimizer-cache',
               state: {} } },
          Bundle {
            type: 'plugin',
            id: 'foo',
            entry: './public/index',
            contextDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo',
            sourceRoot:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo',
            outputDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/target/public',
            cache:
             BundleCache {
               path:
                '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/target/public/.kbn-optimizer-cache',
               state: {} } } ],
       startTime: 1596549988523,
       durSec: 0.1 } },
  { event: { type: 'optimizer initialized' },
    state:
     { phase: 'initialized',
       compilerStates: [],
       offlineBundles: [],
       onlineBundles:
        [ Bundle {
            type: 'plugin',
            id: 'bar',
            entry: './public/index',
            contextDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar',
            sourceRoot:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo',
            outputDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/target/public',
            cache:
             BundleCache {
               path:
                '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/target/public/.kbn-optimizer-cache',
               state: {} } },
          Bundle {
            type: 'plugin',
            id: 'foo',
            entry: './public/index',
            contextDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo',
            sourceRoot:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo',
            outputDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/target/public',
            cache:
             BundleCache {
               path:
                '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/target/public/.kbn-optimizer-cache',
               state: {} } } ],
       startTime: 1596549988523,
       durSec: 0.1 } },
  { event:
     { type: 'worker started',
       bundles:
        [ Bundle {
            type: 'plugin',
            id: 'foo',
            entry: './public/index',
            contextDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo',
            sourceRoot:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo',
            outputDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/target/public',
            cache:
             BundleCache {
               path:
                '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/target/public/.kbn-optimizer-cache',
               state: {} } },
          Bundle {
            type: 'plugin',
            id: 'bar',
            entry: './public/index',
            contextDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar',
            sourceRoot:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo',
            outputDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/target/public',
            cache:
             BundleCache {
               path:
                '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/target/public/.kbn-optimizer-cache',
               state: {} } } ] },
    state:
     { phase: 'initialized',
       compilerStates: [],
       offlineBundles: [],
       onlineBundles:
        [ Bundle {
            type: 'plugin',
            id: 'bar',
            entry: './public/index',
            contextDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar',
            sourceRoot:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo',
            outputDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/target/public',
            cache:
             BundleCache {
               path:
                '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/target/public/.kbn-optimizer-cache',
               state: {} } },
          Bundle {
            type: 'plugin',
            id: 'foo',
            entry: './public/index',
            contextDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo',
            sourceRoot:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo',
            outputDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/target/public',
            cache:
             BundleCache {
               path:
                '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/target/public/.kbn-optimizer-cache',
               state: {} } } ],
       startTime: 1596549988523,
       durSec: 0.2 } },
  { event: { bundleId: 'foo', type: 'running' },
    state:
     { phase: 'running',
       compilerStates: [ { bundleId: 'foo', type: 'running' } ],
       offlineBundles: [],
       onlineBundles:
        [ Bundle {
            type: 'plugin',
            id: 'bar',
            entry: './public/index',
            contextDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar',
            sourceRoot:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo',
            outputDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/target/public',
            cache:
             BundleCache {
               path:
                '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/target/public/.kbn-optimizer-cache',
               state: {} } },
          Bundle {
            type: 'plugin',
            id: 'foo',
            entry: './public/index',
            contextDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo',
            sourceRoot:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo',
            outputDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/target/public',
            cache:
             BundleCache {
               path:
                '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/target/public/.kbn-optimizer-cache',
               state: {} } } ],
       startTime: 1596549988523,
       durSec: 1.5 } },
  { event: { bundleId: 'bar', type: 'running' },
    state:
     { phase: 'running',
       compilerStates:
        [ { bundleId: 'foo', type: 'running' },
          { bundleId: 'bar', type: 'running' } ],
       offlineBundles: [],
       onlineBundles:
        [ Bundle {
            type: 'plugin',
            id: 'bar',
            entry: './public/index',
            contextDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar',
            sourceRoot:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo',
            outputDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/target/public',
            cache:
             BundleCache {
               path:
                '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/target/public/.kbn-optimizer-cache',
               state: {} } },
          Bundle {
            type: 'plugin',
            id: 'foo',
            entry: './public/index',
            contextDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo',
            sourceRoot:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo',
            outputDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/target/public',
            cache:
             BundleCache {
               path:
                '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/target/public/.kbn-optimizer-cache',
               state: {} } } ],
       startTime: 1596549988523,
       durSec: 1.5 } },
  { event:
     { bundleId: 'foo', type: 'compiler success', moduleCount: 4 },
    state:
     { phase: 'running',
       compilerStates:
        [ { bundleId: 'bar', type: 'running' },
          { bundleId: 'foo', type: 'compiler success', moduleCount: 4 } ],
       offlineBundles: [],
       onlineBundles:
        [ Bundle {
            type: 'plugin',
            id: 'bar',
            entry: './public/index',
            contextDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar',
            sourceRoot:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo',
            outputDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/target/public',
            cache:
             BundleCache {
               path:
                '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/target/public/.kbn-optimizer-cache',
               state: {} } },
          Bundle {
            type: 'plugin',
            id: 'foo',
            entry: './public/index',
            contextDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo',
            sourceRoot:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo',
            outputDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/target/public',
            cache:
             BundleCache {
               path:
                '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/target/public/.kbn-optimizer-cache',
               state: {} } } ],
       startTime: 1596549988523,
       durSec: 2.7 } },
  { event:
     { type: 'worker stdio',
       chunk:
        <Buffer 42 72 6f 77 73 65 72 73 6c 69 73 74 3a 20 63 61 6e 69 75 73 65 2d 6c 69 74 65 20 69 73 20 6f 75 74 64 61 74 65 64 2e 20 50 6c 65 61 73 65 20 72 75 6e ... >,
       stream: 'stderr' },
    state:
     { phase: 'running',
       compilerStates:
        [ { bundleId: 'bar', type: 'running' },
          { bundleId: 'foo', type: 'compiler success', moduleCount: 4 } ],
       offlineBundles: [],
       onlineBundles:
        [ Bundle {
            type: 'plugin',
            id: 'bar',
            entry: './public/index',
            contextDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar',
            sourceRoot:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo',
            outputDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/target/public',
            cache:
             BundleCache {
               path:
                '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/target/public/.kbn-optimizer-cache',
               state: {} } },
          Bundle {
            type: 'plugin',
            id: 'foo',
            entry: './public/index',
            contextDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo',
            sourceRoot:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo',
            outputDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/target/public',
            cache:
             BundleCache {
               path:
                '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/target/public/.kbn-optimizer-cache',
               state: {} } } ],
       startTime: 1596549988523,
       durSec: 3.4 } },
  { event:
     { bundleId: 'bar', type: 'compiler success', moduleCount: 15 },
    state:
     { phase: 'success',
       compilerStates:
        [ { bundleId: 'foo', type: 'compiler success', moduleCount: 4 },
          { bundleId: 'bar', type: 'compiler success', moduleCount: 15 } ],
       offlineBundles: [],
       onlineBundles:
        [ Bundle {
            type: 'plugin',
            id: 'bar',
            entry: './public/index',
            contextDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar',
            sourceRoot:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo',
            outputDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/target/public',
            cache:
             BundleCache {
               path:
                '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/bar/target/public/.kbn-optimizer-cache',
               state: {} } },
          Bundle {
            type: 'plugin',
            id: 'foo',
            entry: './public/index',
            contextDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo',
            sourceRoot:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo',
            outputDir:
             '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/target/public',
            cache:
             BundleCache {
               path:
                '/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/__fixtures__/__tmp__/mock_repo/plugins/foo/target/public/.kbn-optimizer-cache',
               state: {} } } ],
       startTime: 1596549988523,
       durSec: 3.6 } } ]
    at assert (/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/integration_tests/basic_optimization.test.ts:78:13)
    at Object.<anonymous>.it (/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/packages/kbn-optimizer/src/integration_tests/basic_optimization.test.ts:104:3)
    at process._tickCallback (internal/process/next_tick.js:68:7)

Kibana Pipeline / x-pack-intake-agent / X-Pack Jest Tests.x-pack/plugins/uptime/public/components/common/charts/__tests__.PingHistogram component renders the component without errors

Link to Jenkins

Standard Out

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


Stack Trace

Error: expect(received).toMatchSnapshot()

Snapshot name: `PingHistogram component renders the component without errors 1`

- Snapshot
+ Received

@@ -3,11 +3,11 @@
      class="euiTitle euiTitle--xsmall"
    >
      Pings over time
    </h2>,
    <div
-     aria-label="Bar Chart showing uptime status over time from a year ago to a year ago."
+     aria-label="Bar Chart showing uptime status over time from 2 years ago to 2 years ago."
      style="height:100%;opacity:1;transition:opacity 0.2s"
    >
      <div
        class="echChart"
      >
    at Object.it (/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/x-pack/plugins/uptime/public/components/common/charts/__tests__/ping_histogram.test.tsx:53:23)
    at Object.asyncJestTest (/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/node_modules/jest-jasmine2/build/jasmineAsyncInstall.js:102:37)
    at resolve (/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/node_modules/jest-jasmine2/build/queueRunner.js:43:12)
    at new Promise (<anonymous>)
    at mapper (/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/node_modules/jest-jasmine2/build/queueRunner.js:26:19)
    at promise.then (/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/node_modules/jest-jasmine2/build/queueRunner.js:73:41)

Kibana Pipeline / x-pack-intake-agent / X-Pack Jest Tests.x-pack/plugins/uptime/public/components/overview/monitor_list/__tests__.MonitorList component renders the monitor list

Link to Jenkins

Standard Out

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


Stack Trace

Error: expect(received).toMatchSnapshot()

Snapshot name: `MonitorList component renders the monitor list 1`

- Snapshot
+ Received

@@ -304,11 +304,11 @@
                            class="euiText euiText--extraSmall"
                          >
                            <div
                              class="euiTextColor euiTextColor--subdued"
                            >
-                             1897 Yr ago
+                             1898 Yr ago
                            </div>
                          </div>
                        </span>
                      </span>
                    </div>
@@ -481,11 +481,11 @@
                            class="euiText euiText--extraSmall"
                          >
                            <div
                              class="euiTextColor euiTextColor--subdued"
                            >
-                             1895 Yr ago
+                             1896 Yr ago
                            </div>
                          </div>
                        </span>
                      </span>
                    </div>
    at Object.it (/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/x-pack/plugins/uptime/public/components/overview/monitor_list/__tests__/monitor_list.test.tsx:145:23)
    at Object.asyncJestTest (/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/node_modules/jest-jasmine2/build/jasmineAsyncInstall.js:102:37)
    at resolve (/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/node_modules/jest-jasmine2/build/queueRunner.js:43:12)
    at new Promise (<anonymous>)
    at mapper (/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/node_modules/jest-jasmine2/build/queueRunner.js:26:19)
    at promise.then (/var/lib/jenkins/workspace/elastic+kibana+pipeline-pull-request/kibana/node_modules/jest-jasmine2/build/queueRunner.js:73:41)

History

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
chore Feature:New Platform release_note:plugin_api_changes Contains a Plugin API changes section for the breaking plugin API changes section. Team:Core Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc v7.9.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Kibana Platform plugins cannot access available features in start method
7 participants