Skip to content

Commit

Permalink
Merge branch 'main' into #81870
Browse files Browse the repository at this point in the history
  • Loading branch information
SoniaSanzV authored Oct 16, 2024
2 parents b8e054d + 983a3e5 commit a0ec972
Show file tree
Hide file tree
Showing 388 changed files with 12,730 additions and 2,450 deletions.
5 changes: 0 additions & 5 deletions .github/workflows/launchdarkly-code-references.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,6 @@ on:
branches:
- 'main'

# cancel in-flight workflow run if another push was triggered
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true

jobs:
launchDarklyCodeReferences:
name: LaunchDarkly Code References
Expand Down
3 changes: 3 additions & 0 deletions config/serverless.yml
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,9 @@ xpack.index_management.enableTogglingDataRetention: false
# Disable project level rentention checks in DSL form from Index Management UI
xpack.index_management.enableProjectLevelRetentionChecks: false

# Disable Manage Processors UI in Ingest Pipelines
xpack.ingest_pipelines.enableManageProcessors: false

# Keep deeplinks visible so that they are shown in the sidenav
dev_tools.deeplinks.navLinkStatus: visible
management.deeplinks.navLinkStatus: visible
Expand Down
2 changes: 1 addition & 1 deletion docs/user/dashboard/view-dashboard-usage.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@ image:images/view-details-dashboards-8.16.0.png[View details icon in the list of

These details include a graph showing the total number of views during the last 90 days.

image:images/dashboard-usage-count.png[Graph showing the number of views during the last 90 days]
image:images/dashboard-usage-count.png[Graph showing the number of views during the last 90 days, width="50%"]
5 changes: 5 additions & 0 deletions oas_docs/output/kibana.serverless.staging.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35261,6 +35261,11 @@ paths:
schema:
nullable: true
type: string
- in: query
name: userFilter
schema:
nullable: true
type: string
responses:
'200':
content:
Expand Down
5 changes: 5 additions & 0 deletions oas_docs/output/kibana.serverless.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35261,6 +35261,11 @@ paths:
schema:
nullable: true
type: string
- in: query
name: userFilter
schema:
nullable: true
type: string
responses:
'200':
content:
Expand Down
5 changes: 5 additions & 0 deletions oas_docs/output/kibana.staging.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38692,6 +38692,11 @@ paths:
schema:
nullable: true
type: string
- in: query
name: userFilter
schema:
nullable: true
type: string
responses:
'200':
content:
Expand Down
5 changes: 5 additions & 0 deletions oas_docs/output/kibana.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38692,6 +38692,11 @@ paths:
schema:
nullable: true
type: string
- in: query
name: userFilter
schema:
nullable: true
type: string
responses:
'200':
content:
Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -1292,6 +1292,7 @@
"xstate": "^4.38.2",
"xstate5": "npm:xstate@^5.18.1",
"xterm": "^5.1.0",
"yaml": "^2.5.1",
"yauzl": "^2.10.0",
"yazl": "^2.5.1",
"zod": "^3.22.3"
Expand Down
1 change: 0 additions & 1 deletion packages/serverless/settings/security_project/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,5 +23,4 @@ export const SECURITY_PROJECT_SETTINGS = [
settings.SECURITY_SOLUTION_NEWS_FEED_URL_ID,
settings.SECURITY_SOLUTION_ENABLE_NEWS_FEED_ID,
settings.SECURITY_SOLUTION_DEFAULT_ALERT_TAGS_KEY,
settings.SECURITY_SOLUTION_ENABLE_ASSET_CRITICALITY_SETTING,
];
3 changes: 1 addition & 2 deletions src/cli/cli.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,7 @@ const program = new Command('bin/kibana');
program
.version(pkg.version)
.description(
'Kibana is an open and free, browser ' +
'based analytics and search dashboard for Elasticsearch.'
'Kibana is an open source, browser based analytics and search dashboard for Elasticsearch.'
);

// attach commands
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ describe('checking migration metadata changes on all registered SO types', () =>
"action_task_params": "b50cb5c8a493881474918e8d4985e61374ca4c30",
"ad_hoc_run_params": "d4e3c5c794151d0a4f5c71e886b2aa638da73ad2",
"alert": "05b07040b12ff45ab642f47464e8a6c903cf7b86",
"api_key_pending_invalidation": "1399e87ca37b3d3a65d269c924eda70726cfe886",
"api_key_pending_invalidation": "8f5554d1984854011b8392d9a6f7ef985bcac03c",
"apm-custom-dashboards": "b67128f78160c288bd7efe25b2da6e2afd5e82fc",
"apm-indices": "8a2d68d415a4b542b26b0d292034a28ffac6fed4",
"apm-server-schema": "58a8c6468edae3d1dc520f0134f59cf3f4fd7eff",
Expand All @@ -83,7 +83,7 @@ describe('checking migration metadata changes on all registered SO types', () =>
"cloud-security-posture-settings": "e0f61c68bbb5e4cfa46ce8994fa001e417df51ca",
"config": "179b3e2bc672626aafce3cf92093a113f456af38",
"config-global": "8e8a134a2952df700d7d4ec51abb794bbd4cf6da",
"connector_token": "5a9ac29fe9c740eb114e9c40517245c71706b005",
"connector_token": "79977ea2cb1530ba7e315b95c1b5a524b622a6b3",
"core-usage-stats": "b3c04da317c957741ebcdedfea4524049fdc79ff",
"csp-rule-template": "c151324d5f85178169395eecb12bac6b96064654",
"dashboard": "211e9ca30f5a95d5f3c27b1bf2b58e6cfa0c9ae9",
Expand Down Expand Up @@ -131,7 +131,7 @@ describe('checking migration metadata changes on all registered SO types', () =>
"lens": "5cfa2c52b979b4f8df56dd13c477e152183468b9",
"lens-ui-telemetry": "8c47a9e393861f76e268345ecbadfc8a5fb1e0bd",
"links": "1dd432cc94619a513b75cec43660a50be7aadc90",
"maintenance-window": "d893544460abad56ff7a0e25b78f78776dfe10d1",
"maintenance-window": "bf36863f5577c2d22625258bdad906eeb4cccccc",
"map": "76c71023bd198fb6b1163b31bafd926fe2ceb9da",
"metrics-data-source": "81b69dc9830699d9ead5ac8dcb9264612e2a3c89",
"metrics-explorer-view": "98cf395d0e87b89ab63f173eae16735584a8ff42",
Expand All @@ -147,7 +147,7 @@ describe('checking migration metadata changes on all registered SO types', () =>
"policy-settings-protection-updates-note": "33924bb246f9e5bcb876109cc83e3c7a28308352",
"query": "501bece68f26fe561286a488eabb1a8ab12f1137",
"risk-engine-configuration": "bab237d09c2e7189dddddcb1b28f19af69755efb",
"rules-settings": "892a2918ebaeba809a612b8d97cec0b07c800b5f",
"rules-settings": "ba57ef1881b3dcbf48fbfb28902d8f74442190b2",
"sample-data-telemetry": "37441b12f5b0159c2d6d5138a494c9f440e950b5",
"search": "0aa6eefb37edd3145be340a8b67779c2ca578b22",
"search-session": "b2fcd840e12a45039ada50b1355faeafa39876d1",
Expand Down
1 change: 1 addition & 0 deletions src/dev/build/tasks/clean_tasks.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ export const CleanExtraFilesFromModules: Task = {

// docs
'**/doc',
'!**/yaml/dist/**/doc', // yaml package store code under doc https://github.com/eemeli/yaml/issues/384
'**/docs',
'**/README',
'**/CONTRIBUTING.md',
Expand Down
2 changes: 1 addition & 1 deletion src/dev/yarn_deduplicate/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ const yarnLock = readFileSync(yarnLockFile, 'utf-8');
const output = fixDuplicates(yarnLock, {
useMostCommon: false,
excludeScopes: ['@types'],
excludePackages: ['axe-core', '@babel/types', 'csstype'],
excludePackages: ['axe-core', '@babel/types', 'csstype', 'yaml'],
});

writeFileSync(yarnLockFile, output);
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ describe('IndexPatternsApiClient', () => {
let indexPatternsApiClient: DataViewsApiClient;

beforeEach(() => {
jest.clearAllMocks();
fetchSpy = jest.spyOn(http, 'fetch').mockImplementation(() => Promise.resolve({}));
indexPatternsApiClient = new DataViewsApiClient(http as HttpSetup, () =>
Promise.resolve(undefined)
Expand Down Expand Up @@ -46,4 +47,15 @@ describe('IndexPatternsApiClient', () => {
version: '1', // version header
});
});

test('Correctly formats fieldTypes argument', async function () {
const fieldTypes = ['text', 'keyword'];
await indexPatternsApiClient.getFieldsForWildcard({
pattern: 'blah',
fieldTypes,
allowHidden: false,
});

expect(fetchSpy.mock.calls[0][1].query.field_types).toEqual(fieldTypes);
});
});
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ export class DataViewsApiClient implements IDataViewsApiClient {
allow_no_index: allowNoIndex,
include_unmapped: includeUnmapped,
fields,
fieldTypes,
field_types: fieldTypes,
// default to undefined to keep value out of URL params and improve caching
allow_hidden: allowHidden || undefined,
include_empty_fields: includeEmptyFields,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -439,7 +439,7 @@ function maybeQuote(value: any) {
if (value.match(/^\{.*\}$/)) {
return value;
}
return `"${value.replace(/"/g, '\\"')}"`;
return `"${value.replace(/[\\"]/g, '\\$&')}"`;
}
return value;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -270,13 +270,12 @@ const DatasetQualityLink = React.memo(
urlService: BrowserUrlService;
dataStream: string | undefined;
}) => {
if (!dataStream) {
return null;
}
const locator = urlService.locators.get<DataQualityDetailsLocatorParams>(
DATA_QUALITY_DETAILS_LOCATOR_ID
);

if (!locator || !dataStream) return null;

const datasetQualityUrl = locator?.getRedirectUrl({ dataStream });

const navigateToDatasetQuality = () => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -314,6 +314,7 @@ export default function ({ getService }: PluginFunctionalProviderContext) {
'xpack.ml.nlp.modelDeployment.vCPURange.medium.static (number?)',
'xpack.osquery.actionEnabled (boolean?)',
'xpack.remote_clusters.ui.enabled (boolean?)',
'xpack.ingest_pipelines.enableManageProcessors (boolean?|never)',
/**
* NOTE: The Reporting plugin is currently disabled in functional tests (see test/functional/config.base.js).
* It will be re-enabled once #102552 is completed.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,7 @@ import useEvent from 'react-use/lib/useEvent';
import { css } from '@emotion/react';
// eslint-disable-next-line @kbn/eslint/module_migration
import { createGlobalStyle } from 'styled-components';
import {
ShowAssistantOverlayProps,
useAssistantContext,
UserAvatar,
} from '../../assistant_context';
import { ShowAssistantOverlayProps, useAssistantContext } from '../../assistant_context';
import { Assistant, CONVERSATION_SIDE_PANEL_WIDTH } from '..';

const isMac = navigator.platform.toLowerCase().indexOf('mac') >= 0;
Expand All @@ -25,17 +21,14 @@ const isMac = navigator.platform.toLowerCase().indexOf('mac') >= 0;
* Modal container for Elastic AI Assistant conversations, receiving the page contents as context, plus whatever
* component currently has focus and any specific context it may provide through the SAssInterface.
*/
export interface Props {
currentUserAvatar?: UserAvatar;
}

export const UnifiedTimelineGlobalStyles = createGlobalStyle`
body:has(.timeline-portal-overlay-mask) .euiOverlayMask {
z-index: 1003 !important;
}
`;

export const AssistantOverlay = React.memo<Props>(({ currentUserAvatar }) => {
export const AssistantOverlay = React.memo(() => {
const [isModalVisible, setIsModalVisible] = useState(false);
// Why is this named Title and not Id?
const [conversationTitle, setConversationTitle] = useState<string | undefined>(undefined);
Expand Down Expand Up @@ -144,7 +137,6 @@ export const AssistantOverlay = React.memo<Props>(({ currentUserAvatar }) => {
onCloseFlyout={handleCloseModal}
chatHistoryVisible={chatHistoryVisible}
setChatHistoryVisible={toggleChatHistory}
currentUserAvatar={currentUserAvatar}
/>
</EuiFlyoutResizable>
<UnifiedTimelineGlobalStyles />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ interface Props {
onSaveCancelled: () => void;
onSaveConfirmed: () => void;
saveButtonDisabled?: boolean;
saveButtonLoading?: boolean;
}

const FlyoutComponent: React.FC<Props> = ({
Expand All @@ -38,9 +39,11 @@ const FlyoutComponent: React.FC<Props> = ({
onSaveCancelled,
onSaveConfirmed,
saveButtonDisabled = false,
saveButtonLoading = false,
}) => {
return flyoutVisible ? (
<EuiFlyout
data-test-subj={'flyout'}
ownFocus
onClose={onClose}
css={css`
Expand Down Expand Up @@ -74,6 +77,7 @@ const FlyoutComponent: React.FC<Props> = ({
onClick={onSaveConfirmed}
iconType="check"
disabled={saveButtonDisabled}
isLoading={saveButtonLoading}
fill
>
{i18n.FLYOUT_SAVE_BUTTON_TITLE}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ export const useInlineActions = <T extends { isDefault?: boolean | undefined }>(
},
{
name: i18n.DELETE_BUTTON,
'data-test-subj': 'delete-button',
description: i18n.DELETE_BUTTON,
icon: 'trash',
type: 'icon',
Expand Down
Loading

0 comments on commit a0ec972

Please sign in to comment.