Skip to content

Commit

Permalink
Merge branch 'main' into elastic#79656
Browse files Browse the repository at this point in the history
  • Loading branch information
kibanamachine authored Sep 12, 2022
2 parents f2939d2 + 6a2fa9f commit 0b55c19
Show file tree
Hide file tree
Showing 1,633 changed files with 28,796 additions and 12,564 deletions.
1 change: 1 addition & 0 deletions .buildkite/ftr_configs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,7 @@ enabled:
- x-pack/test/detection_engine_api_integration/security_and_spaces/group7/config.ts
- x-pack/test/detection_engine_api_integration/security_and_spaces/group8/config.ts
- x-pack/test/detection_engine_api_integration/security_and_spaces/group9/config.ts
- x-pack/test/detection_engine_api_integration/security_and_spaces/group10/config.ts
- x-pack/test/encrypted_saved_objects_api_integration/config.ts
- x-pack/test/endpoint_api_integration_no_ingest/config.ts
- x-pack/test/examples/config.ts
Expand Down
9 changes: 8 additions & 1 deletion .buildkite/scripts/steps/checks/bazel_packages.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,12 @@ source .buildkite/scripts/common/util.sh

echo --- Check Bazel Packages Manifest
node scripts/generate packages_build_manifest

check_for_changed_files 'node scripts/generate packages_build_manifest' true

echo --- Check Codeowners Manifest
if [ -f ".github/CODEOWNERS" ]; then
node scripts/generate codeowners
check_for_changed_files 'node scripts/generate codeowners' true
else
echo "skipping, no existing .github/CODEOWNERS file found"
fi
19 changes: 9 additions & 10 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,9 @@
const Path = require('path');
const Fs = require('fs');

const globby = require('globby');
const normalizePath = require('normalize-path');
const { discoverPackageManifestPaths, Jsonc } = require('@kbn/bazel-packages');
const { REPO_ROOT } = require('@kbn/utils');

const APACHE_2_0_LICENSE_HEADER = `
/*
Expand Down Expand Up @@ -119,15 +121,10 @@ const VENN_DIAGRAM_HEADER = `
*/
`;

const packagePkgJsons = globby.sync('*/package.json', {
cwd: Path.resolve(__dirname, 'packages'),
absolute: true,
});

/** Packages which should not be included within production code. */
const DEV_PACKAGES = packagePkgJsons.flatMap((path) => {
const pkg = JSON.parse(Fs.readFileSync(path, 'utf8'));
return pkg.kibana && pkg.kibana.devOnly ? Path.dirname(Path.basename(path)) : [];
const DEV_PACKAGE_DIRS = discoverPackageManifestPaths(REPO_ROOT).flatMap((path) => {
const manifest = Jsonc.parse(Fs.readFileSync(path, 'utf8'));
return !!manifest.devOnly ? normalizePath(Path.relative(REPO_ROOT, Path.dirname(path))) : [];
});

/** Directories (at any depth) which include dev-only code. */
Expand All @@ -145,6 +142,7 @@ const DEV_DIRECTORIES = [
'integration_tests',
'manual_tests',
'mock',
'mocks',
'storybook',
'scripts',
'test',
Expand All @@ -153,6 +151,7 @@ const DEV_DIRECTORIES = [
'test_utilities',
'test_helpers',
'tests_client_integration',
'tsd_tests',
];

/** File patterns for dev-only code. */
Expand All @@ -171,7 +170,7 @@ const DEV_FILE_PATTERNS = [

/** Glob patterns which describe dev-only code. */
const DEV_PATTERNS = [
...DEV_PACKAGES.map((pkg) => `packages/${pkg}/**/*`),
...DEV_PACKAGE_DIRS.map((pkg) => `${pkg}/**/*`),
...DEV_DIRECTORIES.map((dir) => `{packages,src,x-pack}/**/${dir}/**/*`),
...DEV_FILE_PATTERNS.map((file) => `{packages,src,x-pack}/**/${file}`),
'packages/kbn-interpreter/tasks/**/*',
Expand Down
381 changes: 310 additions & 71 deletions .github/CODEOWNERS

Large diffs are not rendered by default.

27 changes: 16 additions & 11 deletions .github/workflows/add-to-apm-project.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,36 +12,41 @@ jobs:
- uses: octokit/[email protected]
id: add_to_project
with:
headers: '{"GraphQL-Features": "projects_next_graphql"}'
query: |
mutation add_to_project($projectid:ID!,$contentid:ID!) {
addProjectNextItem(input:{projectId:$projectid contentId:$contentid}) {
projectNextItem {
id
addProjectV2ItemById(input:{projectId:$projectid contentId:$contentid}) {
item {
... on ProjectV2Item {
id
}
}
}
}
projectid: ${{ env.PROJECT_ID }}
contentid: ${{ github.event.issue.node_id }}
env:
PROJECT_ID: "PN_kwDOAGc3Zs0VSg"
PROJECT_ID: "PVT_kwDOAGc3Zs0VSg"
GITHUB_TOKEN: ${{ secrets.APM_TECH_KIBANA_USER_TOKEN }}
- uses: octokit/[email protected]
id: label_team
with:
headers: '{"GraphQL-Features": "projects_next_graphql"}'
query: |
mutation label_team($projectid:ID!,$itemid:ID!,$fieldid:ID!,$value:String!) {
updateProjectNextItemField(input: { projectId:$projectid itemId:$itemid fieldId:$fieldid value:$value }) {
projectNextItem {
updateProjectV2ItemFieldValue(input: { projectId:$projectid itemId:$itemid fieldId:$fieldid value:{singleSelectOptionId: $value} }) {
projectV2Item {
id
content {
... on Issue {
number
}
}
}
}
}
projectid: ${{ env.PROJECT_ID }}
itemid: ${{ fromJSON(steps.add_to_project.outputs.data).addProjectNextItem.projectNextItem.id }}
fieldid: "MDE2OlByb2plY3ROZXh0RmllbGQ0NDE0Ng=="
itemid: ${{ fromJSON(steps.add_to_project.outputs.data).addProjectV2ItemById.item.id }}
fieldid: "PVTSSF_lADOAGc3Zs0VSs2scg"
value: "c33f5c54"
env:
PROJECT_ID: "PN_kwDOAGc3Zs0VSg"
PROJECT_ID: "PVT_kwDOAGc3Zs0VSg"
GITHUB_TOKEN: ${{ secrets.APM_TECH_KIBANA_USER_TOKEN }}
2 changes: 1 addition & 1 deletion api_docs/actions.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/actions
title: "actions"
image: https://source.unsplash.com/400x175/?github
description: API docs for the actions plugin
date: 2022-09-08
date: 2022-09-12
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'actions']
---
import actionsObj from './actions.devdocs.json';
Expand Down
2 changes: 1 addition & 1 deletion api_docs/advanced_settings.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/advancedSettings
title: "advancedSettings"
image: https://source.unsplash.com/400x175/?github
description: API docs for the advancedSettings plugin
date: 2022-09-08
date: 2022-09-12
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'advancedSettings']
---
import advancedSettingsObj from './advanced_settings.devdocs.json';
Expand Down
20 changes: 1 addition & 19 deletions api_docs/aiops.devdocs.json
Original file line number Diff line number Diff line change
Expand Up @@ -48,25 +48,7 @@
"interfaces": [],
"enums": [],
"misc": [],
"objects": [],
"start": {
"parentPluginId": "aiops",
"id": "def-public.AiopsPluginStart",
"type": "Type",
"tags": [],
"label": "AiopsPluginStart",
"description": [
"\naiops plugin public start contract"
],
"signature": [
"void"
],
"path": "x-pack/plugins/aiops/public/types.ts",
"deprecated": false,
"trackAdoption": false,
"lifecycle": "start",
"initialIsOpen": true
}
"objects": []
},
"server": {
"classes": [],
Expand Down
7 changes: 2 additions & 5 deletions api_docs/aiops.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/aiops
title: "aiops"
image: https://source.unsplash.com/400x175/?github
description: API docs for the aiops plugin
date: 2022-09-08
date: 2022-09-12
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'aiops']
---
import aiopsObj from './aiops.devdocs.json';
Expand All @@ -21,13 +21,10 @@ Contact [Machine Learning UI](https://github.com/orgs/elastic/teams/ml-ui) for q

| Public API count | Any count | Items lacking comments | Missing exports |
|-------------------|-----------|------------------------|-----------------|
| 9 | 0 | 0 | 1 |
| 7 | 0 | 0 | 1 |

## Client

### Start
<DocDefinitionList data={[aiopsObj.client.start]}/>

### Functions
<DocDefinitionList data={aiopsObj.client.functions}/>

Expand Down
21 changes: 21 additions & 0 deletions api_docs/alerting.devdocs.json
Original file line number Diff line number Diff line change
Expand Up @@ -2810,6 +2810,16 @@
"section": "def-common.IExecutionLogResult",
"text": "IExecutionLogResult"
},
">; getGlobalExecutionLogWithAuth: ({ dateStart, dateEnd, filter, page, perPage, sort, }: ",
"GetGlobalExecutionLogParams",
") => Promise<",
{
"pluginId": "alerting",
"scope": "common",
"docId": "kibAlertingPluginApi",
"section": "def-common.IExecutionLogResult",
"text": "IExecutionLogResult"
},
">; getActionErrorLog: ({ id, dateStart, dateEnd, filter, page, perPage, sort, }: ",
"GetActionErrorLogByIdParams",
") => Promise<",
Expand Down Expand Up @@ -4128,6 +4138,17 @@
"path": "x-pack/plugins/alerting/common/execution_log_types.ts",
"deprecated": false,
"trackAdoption": false
},
{
"parentPluginId": "alerting",
"id": "def-common.IExecutionLog.rule_id",
"type": "string",
"tags": [],
"label": "rule_id",
"description": [],
"path": "x-pack/plugins/alerting/common/execution_log_types.ts",
"deprecated": false,
"trackAdoption": false
}
],
"initialIsOpen": false
Expand Down
4 changes: 2 additions & 2 deletions api_docs/alerting.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/alerting
title: "alerting"
image: https://source.unsplash.com/400x175/?github
description: API docs for the alerting plugin
date: 2022-09-08
date: 2022-09-12
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'alerting']
---
import alertingObj from './alerting.devdocs.json';
Expand All @@ -21,7 +21,7 @@ Contact [Response Ops](https://github.com/orgs/elastic/teams/response-ops) for q

| Public API count | Any count | Items lacking comments | Missing exports |
|-------------------|-----------|------------------------|-----------------|
| 368 | 0 | 359 | 21 |
| 369 | 0 | 360 | 22 |

## Client

Expand Down
Loading

0 comments on commit 0b55c19

Please sign in to comment.