Skip to content

Commit

Permalink
Merge branch 'main' into issue_199361
Browse files Browse the repository at this point in the history
  • Loading branch information
elasticmachine authored Nov 15, 2024
2 parents 4759dd5 + 61b9e68 commit cce4934
Show file tree
Hide file tree
Showing 45 changed files with 296 additions and 155 deletions.
17 changes: 8 additions & 9 deletions docs/CHANGELOG.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -93,37 +93,36 @@ The 8.16.0 release includes the following known issues.

[discrete]
[[known-199902]]
.Stack Monitoring shows "Unable to load page error"
.Stack Monitoring shows "Unable to load page" error
[%collapsible]
====
*Details* +
The Stack Monitoring pages Overview, Nodes, Logs can stop working with the error "Unable to load page error". The Stack trace mentions `TypeError: Cannot read properties of undefined (reading 'logsLocator')`.
The Overview, Nodes, and Logs pages in Stack Monitoring show an "Unable to load page" error. The Stack trace mentions `TypeError: Cannot read properties of undefined (reading 'logsLocator')`.
*Workaround* +
Disabling the `Set feature visibility > Logs` feature at Kibana Space settings level will prevent the error to occur. Please note the `Logs` feature will not be available on such space.
Disabling the `Set feature visibility > Logs` feature at the Kibana Space settings level will prevent the error from occurring. Please note the `Logs` feature will not be available on those spaces.
It's also possible to `Observability > Logs` feature privilege to `None` on the role level - this will hide the `Logs` feature for individual users and prevent the error for these users as well.
It's also possible to set the `Observability > Logs` feature privilege to `None` at the role level. This will hide the `Logs` feature from individual users and prevent the error for these users as well.
For more information, refer to {kibana-issue}199902[#199902].
====

[discrete]
[[known-199891-199892]]
.Onboarding, tutorial of APM and OpenTelemetry and some "Beats Only" integrations will show the error "Unable to load page error"
.Onboarding, tutorial of APM and OpenTelemetry and some "Beats Only" integrations shows "Unable to load page" error
[%collapsible]
====
*Details* +
Tutorials linked from the {kib} home page show an error "Unable to load page error". The Stack trace mentions `The above error occurred in tutorial_TutorialUi`.
Tutorials linked from the {kib} home page show an "Unable to load page" error. The Stack trace mentions `The above error occurred in tutorial_TutorialUi`.
*Workaround* +
The APM / OpenTelemetry tutorials represented a shortcut to get important parameters to use in the configuration files quickly.
It is still possible to obtain the same parameters following the documentation tutorials of APM.
The APM / OpenTelemetry tutorials represented a shortcut to quickly add important parameters to the configuration files.
It is still possible to obtain the same parameters following the tutorials in the APM documentation.
More information can be found in the {observability-guide}/apm-collect-application-data.html[APM documentation] and the {observability-guide}/get-started-with-fleet-apm-server.html[Fleet documentation].
For information about how to create APM API keys, please check the {observability-guide}/apm-api-key.html#apm-create-an-api-key[API key documentation].
For more information, refer to {kibana-issue}199891[#199891] and {kibana-issue}199892[#199892].
====

Expand Down
2 changes: 1 addition & 1 deletion oas_docs/bundle.json
Original file line number Diff line number Diff line change
Expand Up @@ -21335,7 +21335,7 @@
]
}
},
"/api/fleet/epm/packages/{pkgName}/{pkgVersion}/{filePath*}": {
"/api/fleet/epm/packages/{pkgName}/{pkgVersion}/{filePath}": {
"get": {
"operationId": "get-fleet-epm-packages-pkgname-pkgversion-filepath",
"parameters": [
Expand Down
2 changes: 1 addition & 1 deletion oas_docs/bundle.serverless.json
Original file line number Diff line number Diff line change
Expand Up @@ -21335,7 +21335,7 @@
]
}
},
"/api/fleet/epm/packages/{pkgName}/{pkgVersion}/{filePath*}": {
"/api/fleet/epm/packages/{pkgName}/{pkgVersion}/{filePath}": {
"get": {
"operationId": "get-fleet-epm-packages-pkgname-pkgversion-filepath",
"parameters": [
Expand Down
2 changes: 1 addition & 1 deletion oas_docs/output/kibana.serverless.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19323,7 +19323,7 @@ paths:
tags:
- Elastic Package Manager (EPM)
x-beta: true
/api/fleet/epm/packages/{pkgName}/{pkgVersion}/{filePath*}:
/api/fleet/epm/packages/{pkgName}/{pkgVersion}/{filePath}:
get:
operationId: get-fleet-epm-packages-pkgname-pkgversion-filepath
parameters:
Expand Down
2 changes: 1 addition & 1 deletion oas_docs/output/kibana.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22127,7 +22127,7 @@ paths:
summary: Update package settings
tags:
- Elastic Package Manager (EPM)
/api/fleet/epm/packages/{pkgName}/{pkgVersion}/{filePath*}:
/api/fleet/epm/packages/{pkgName}/{pkgVersion}/{filePath}:
get:
operationId: get-fleet-epm-packages-pkgname-pkgversion-filepath
parameters:
Expand Down
3 changes: 2 additions & 1 deletion oas_docs/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion oas_docs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
},
"dependencies": {
"bump-cli": "^2.8.4",
"@redocly/cli": "^1.25.7"
"@redocly/cli": "^1.25.11"
},
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1"
Expand Down
10 changes: 5 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -1023,7 +1023,7 @@
"@langchain/langgraph": "0.2.19",
"@langchain/openai": "^0.3.11",
"@langtrase/trace-attributes": "^3.0.8",
"@launchdarkly/node-server-sdk": "^9.7.0",
"@launchdarkly/node-server-sdk": "^9.7.1",
"@launchdarkly/openfeature-node-server": "^1.0.0",
"@loaders.gl/core": "^3.4.7",
"@loaders.gl/json": "^3.4.7",
Expand Down Expand Up @@ -1634,7 +1634,7 @@
"@types/resolve": "^1.20.1",
"@types/scheduler": "^0.23.0",
"@types/seedrandom": ">=2.0.0 <4.0.0",
"@types/selenium-webdriver": "^4.1.26",
"@types/selenium-webdriver": "^4.1.27",
"@types/semver": "^7.5.8",
"@types/set-value": "^2.0.0",
"@types/sinon": "^7.0.13",
Expand Down Expand Up @@ -1681,7 +1681,7 @@
"buildkite-test-collector": "^1.7.0",
"callsites": "^3.1.0",
"chance": "1.0.18",
"chromedriver": "^130.0.1",
"chromedriver": "^130.0.4",
"clarify": "^2.2.0",
"clean-webpack-plugin": "^3.0.0",
"cli-progress": "^3.12.0",
Expand Down Expand Up @@ -1732,7 +1732,7 @@
"file-loader": "^4.2.0",
"find-cypress-specs": "^1.41.4",
"form-data": "^4.0.0",
"geckodriver": "^4.5.1",
"geckodriver": "^5.0.0",
"gulp-brotli": "^3.0.0",
"gulp-postcss": "^9.0.1",
"gulp-terser": "^2.1.0",
Expand Down Expand Up @@ -1807,7 +1807,7 @@
"rxjs-marbles": "^7.0.1",
"sass-embedded": "^1.78.0",
"sass-loader": "^10.5.1",
"selenium-webdriver": "^4.25.0",
"selenium-webdriver": "^4.26.0",
"sharp": "0.32.6",
"simple-git": "^3.16.0",
"sinon": "^7.4.2",
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ export const sharedOas = {
tags: ['versioned'],
},
},
'/foo/{id}/{path*}': {
'/foo/{id}/{path}': {
get: {
description: 'route description',
operationId: 'get-foo-id-path',
Expand Down
14 changes: 7 additions & 7 deletions packages/kbn-router-to-openapispec/src/generate_oas.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -314,9 +314,9 @@ describe('generateOpenApiDocument', () => {
}
);
// router paths
expect(result.paths['/1-1/{id}/{path*}']!.get!.tags).toEqual(['1', '2']);
expect(result.paths['/1-2/{id}/{path*}']!.get!.tags).toEqual(['1']);
expect(result.paths['/2-1/{id}/{path*}']!.get!.tags).toEqual([]);
expect(result.paths['/1-1/{id}/{path}']!.get!.tags).toEqual(['1', '2']);
expect(result.paths['/1-2/{id}/{path}']!.get!.tags).toEqual(['1']);
expect(result.paths['/2-1/{id}/{path}']!.get!.tags).toEqual([]);
// versioned router paths
expect(result.paths['/v1-1']!.get!.tags).toEqual(['v1']);
expect(result.paths['/v1-2']!.get!.tags).toEqual(['v2', 'v3']);
Expand Down Expand Up @@ -392,17 +392,17 @@ describe('generateOpenApiDocument', () => {
);

// router paths
expect(result.paths['/1-1/{id}/{path*}']!.get).toMatchObject({
expect(result.paths['/1-1/{id}/{path}']!.get).toMatchObject({
'x-state': 'Technical Preview',
});
expect(result.paths['/1-2/{id}/{path*}']!.get).toMatchObject({
expect(result.paths['/1-2/{id}/{path}']!.get).toMatchObject({
'x-state': 'Beta',
});

expect(result.paths['/1-3/{id}/{path*}']!.get).not.toMatchObject({
expect(result.paths['/1-3/{id}/{path}']!.get).not.toMatchObject({
'x-state': expect.any(String),
});
expect(result.paths['/2-1/{id}/{path*}']!.get).not.toMatchObject({
expect(result.paths['/2-1/{id}/{path}']!.get).not.toMatchObject({
'x-state': expect.any(String),
});

Expand Down
7 changes: 5 additions & 2 deletions packages/kbn-router-to-openapispec/src/util.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,9 @@ import {
getPathParameters,
createOpIdGenerator,
GetOpId,
assignToPaths,
extractTags,
} from './util';
import { assignToPaths, extractTags } from './util';

describe('extractTags', () => {
test.each([
Expand Down Expand Up @@ -115,9 +116,11 @@ describe('assignToPaths', () => {
const paths = {};
assignToPaths(paths, '/foo', {});
assignToPaths(paths, '/bar/{id?}', {});
assignToPaths(paths, '/bar/file/{path*}', {});
expect(paths).toEqual({
'/foo': {},
'/bar/{id}': {},
'/bar/file/{path}': {},
});
});
});
Expand Down Expand Up @@ -320,7 +323,7 @@ describe('createOpIdGenerator', () => {
{
input: {
method: 'get',
path: '/api/my/resource/{path*}',
path: '/api/my/resource/{path}',
},
output: 'get-my-resource-path',
},
Expand Down
2 changes: 1 addition & 1 deletion packages/kbn-router-to-openapispec/src/util.ts
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ export const assignToPaths = (
path: string,
pathObject: OpenAPIV3.PathItemObject
): void => {
const pathName = path.replace('?', '');
const pathName = path.replace(/[\?\*]/, '');
paths[pathName] = { ...paths[pathName], ...pathObject };
};

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,8 @@ export const ChartGridEmbeddableWrapper: FC<ChangePointDetectionProps> = ({
mergedQuery.bool.filter.push({
range: {
[dataView.timeFieldName!]: {
from: searchBounds.min?.valueOf(),
to: searchBounds.max?.valueOf(),
gte: searchBounds.min?.valueOf(),
lte: searchBounds.max?.valueOf(),
format: 'epoch_millis',
},
},
Expand Down
4 changes: 2 additions & 2 deletions x-pack/plugins/embeddable_enhanced/public/plugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -148,8 +148,8 @@ export class EmbeddableEnhancedPlugin
);
const api: DynamicActionStorageApi = {
dynamicActionsState$,
setDynamicActions: (newState) => {
dynamicActionsState$.next(newState);
setDynamicActions: (enhancements) => {
dynamicActionsState$.next(getDynamicActionsState(enhancements));
},
};
const storage = new DynamicActionStorage(uuid, getTitle, api);
Expand Down
6 changes: 6 additions & 0 deletions x-pack/plugins/inference/server/routes/chat_complete.ts
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,12 @@ export function registerChatCompleteRoute({
router.post(
{
path: '/internal/inference/chat_complete',
security: {
authz: {
enabled: false,
reason: 'This route is opted out from authorization',
},
},
validate: {
body: chatCompleteBodySchema,
},
Expand Down
6 changes: 6 additions & 0 deletions x-pack/plugins/inference/server/routes/connectors.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,12 @@ export function registerConnectorsRoute({
router.get(
{
path: '/internal/inference/connectors',
security: {
authz: {
enabled: false,
reason: 'This route is opted out from authorization',
},
},
validate: {},
},
async (_context, request, response) => {
Expand Down
5 changes: 5 additions & 0 deletions x-pack/plugins/kubernetes_security/server/routes/aggregate.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,11 @@ export const registerAggregateRoute = (router: IRouter, logger: Logger) => {
.addVersion(
{
version: '1',
security: {
authz: {
requiredPrivileges: ['securitySolution'],
},
},
validate: {
request: {
query: schema.object({
Expand Down
5 changes: 5 additions & 0 deletions x-pack/plugins/kubernetes_security/server/routes/count.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,11 @@ export const registerCountRoute = (router: IRouter, logger: Logger) => {
.addVersion(
{
version: '1',
security: {
authz: {
requiredPrivileges: ['securitySolution'],
},
},
validate: {
request: {
query: schema.object({
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,11 @@ export const registerMultiTermsAggregateRoute = (router: IRouter, logger: Logger
.addVersion(
{
version: '1',
security: {
authz: {
requiredPrivileges: ['securitySolution'],
},
},
validate: {
request: {
query: schema.object({
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ import { schema, type TypeOf } from '@kbn/config-schema';

export const config = schema.object({
enabled: schema.boolean({ defaultValue: true }),
modelId: schema.maybe(schema.string()), // TODO: Remove
scope: schema.maybe(schema.oneOf([schema.literal('observability'), schema.literal('search')])),
enableKnowledgeBase: schema.boolean({ defaultValue: true }),
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -116,11 +116,6 @@ export class ObservabilityAIAssistantPlugin

// Using once to make sure the same model ID is used during service init and Knowledge base setup
const getSearchConnectorModelId = once(async () => {
// TODO: Remove this once the modelId is removed from the config
const configModelId = this.config.modelId;
if (configModelId) {
return configModelId;
}
const defaultModelId = '.elser_model_2';
const [_, pluginsStart] = await core.getStartServices();
// Wait for the license to be available so the ML plugin's guards pass once we ask for ELSER stats
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import { ElasticsearchClient } from '@kbn/core-elasticsearch-server';
import { Logger } from '@kbn/logging';
import moment from 'moment';

export const AI_ASSISTANT_KB_INFERENCE_ID = 'ai_assistant_kb_inference';
export const AI_ASSISTANT_KB_INFERENCE_ID = 'obs_ai_assistant_kb_inference';

export async function createInferenceEndpoint({
esClient,
Expand Down
Loading

0 comments on commit cce4934

Please sign in to comment.