Skip to content

Commit 5d9a659

Browse files
authored
Merge branch 'main' into changes-history/mvp-ui
2 parents dc53c21 + 3790a2e commit 5d9a659

731 files changed

Lines changed: 27779 additions & 10841 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.agents/skills/evals-write-spec/SKILL.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ evaluate.describe('Suite name', { tag: tags.serverless.observability.complete },
2424

2525
evaluate('test name', async ({ executorClient, connector }) => {
2626
await executorClient.runExperiment(
27-
{ dataset, task },
27+
{ datasets: [dataset], task },
2828
evaluators
2929
);
3030
});
@@ -202,7 +202,7 @@ export function createEvaluateDataset({
202202
return async ({ dataset }) => {
203203
await executorClient.runExperiment(
204204
{
205-
dataset,
205+
datasets: [dataset],
206206
task: async ({ input }) => {
207207
const response = await chatClient.converse({ messages: [{ message: input.question }] });
208208
return { messages: response.messages, steps: response.steps };

.agents/skills/evals-write-spec/references/evaluator-patterns.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ type MyTaskOutput = TaskOutput & {
2020
};
2121

2222
await executorClient.runExperiment(
23-
{ dataset, task },
23+
{ datasets: [dataset], task },
2424
selectEvaluators<MyExample, MyTaskOutput>([
2525
{
2626
name: 'NonEmptyDocuments',
@@ -246,7 +246,7 @@ A common pattern passes both CODE and LLM evaluators to `runExperiment`:
246246

247247
```ts
248248
await executorClient.runExperiment(
249-
{ dataset, task },
249+
{ datasets: [dataset], task },
250250
[
251251
createCriteriaEvaluator({ evaluators }),
252252
createToolCallsEvaluator({ evaluators }),

.buildkite/scripts/common/setup_job_env.sh

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ EOF
130130
# Set up Kibana Evals secrets
131131
{
132132
if [[ "${KBN_EVALS:-}" =~ ^(1|true)$ ]]; then
133-
echo "KBN_EVALS was set - exposing evals connectors and ES export credentials"
133+
echo "KBN_EVALS was set - exposing evals connectors and export credentials"
134134

135135
KBN_EVALS_CONFIG_JSON="$(vault_get kbn-evals config | base64 -d)"
136136
# Validate config shape (safe; does not print secrets)
@@ -145,10 +145,6 @@ EOF
145145
export KBN_EVALS_CONFIG_B64
146146
KBN_EVALS_CONFIG_B64="$(printf '%s' "$KBN_EVALS_CONFIG_JSON" | base64)"
147147

148-
# Elasticsearch cluster for evaluation results export
149-
export EVALUATIONS_ES_URL="$(jq -r '.evaluationsEs.url // empty' <<<"$KBN_EVALS_CONFIG_JSON")"
150-
export EVALUATIONS_ES_API_KEY="$(jq -r '.evaluationsEs.apiKey // empty' <<<"$KBN_EVALS_CONFIG_JSON")"
151-
152148
# Optional: separate cluster for trace-based evaluators
153149
export TRACING_ES_URL="$(jq -r '.tracingEs.url // empty' <<<"$KBN_EVALS_CONFIG_JSON")"
154150
export TRACING_ES_API_KEY="$(jq -r '.tracingEs.apiKey // empty' <<<"$KBN_EVALS_CONFIG_JSON")"

.buildkite/scripts/steps/evals/run_suite.sh

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,10 @@ fi
1818
# The value should be the platform-level `pluginId` use-case identifier.
1919
# `@kbn/evals` defaults this to `kbn_evals`, but you can override via KBN_EVALS_TELEMETRY_PLUGIN_ID.
2020

21-
# Set a base run id from the Buildkite build. The evaluator fixture appends the
22-
# connector id to produce a unique run_id per model (e.g. bk-<build>-<connector>).
23-
# Correlation across models in the same build uses ci.buildkite.build_id which
24-
# is populated automatically from BUILDKITE_BUILD_ID in score_repository.ts.
21+
# Set a base build run ID from the Buildkite build. This is used as a seed for
22+
# generating deterministic per-task experiment IDs (not as the experiment_id itself).
23+
# Suite-run grouping in the UI uses metadata.ci.build_id which is populated
24+
# automatically from BUILDKITE_BUILD_ID in the Buildkite metadata.
2525
if [[ -z "${TEST_RUN_ID:-}" ]] && [[ -n "${BUILDKITE_BUILD_ID:-}" ]]; then
2626
export TEST_RUN_ID="bk-${BUILDKITE_BUILD_ID}"
2727
fi

docs/extend/plugin-list.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@ mapped_pages:
153153
| [enterpriseSearch](https://github.com/elastic/kibana/blob/main/x-pack/solutions/search/plugins/enterprise_search/README.md) | This plugin provides Kibana user interfaces for managing the Enterprise Search solution and its products, App Search and Workplace Search. |
154154
| [entityManager](https://github.com/elastic/kibana/blob/main/x-pack/platform/plugins/shared/entity_manager/README.md) | This plugin provides access to observed entity data, such as information about hosts, pods, containers, services, and more. |
155155
| [entityStore](https://github.com/elastic/kibana/blob/main/x-pack/solutions/security/plugins/entity_store/README.md) | Central place for Entities management and logs extraction. |
156-
| [evals](https://github.com/elastic/kibana/blob/main/x-pack/platform/plugins/shared/evals/README.md) | The Evals plugin provides an in-Kibana UI for browsing LLM evaluation run results, per-evaluator statistics, and OpenTelemetry traces produced by the @kbn/evals evaluation framework. |
156+
| [evals](https://github.com/elastic/kibana/blob/main/x-pack/platform/plugins/shared/evals/README.md) | The Evals plugin provides an in-Kibana UI for browsing LLM evaluation experiment results, per-evaluator statistics, and OpenTelemetry traces produced by the @kbn/evals evaluation framework. |
157157
| [eventLog](https://github.com/elastic/kibana/blob/main/x-pack/platform/plugins/shared/event_log/README.md) | The event log plugin provides a persistent history of alerting and action activities. |
158158
| [exploratoryView](https://github.com/elastic/kibana/blob/main/x-pack/solutions/observability/plugins/exploratory_view/README.md) | A shared component for visualizing observability data types via lens embeddable. For further details. |
159159
| [features](https://github.com/elastic/kibana/blob/main/x-pack/platform/plugins/shared/features/README.md) | The features plugin enhance Kibana with a per-feature privilege system. |

docs/reference/configuration-reference/internationalization-settings.md

Lines changed: 38 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,40 @@ When a user sets a preferred language, it is stored in their user profile and ta
3030

3131
{{kib}} resolves the display language using the following priority chain:
3232

33-
1. **User profile setting** — The language selected by the user in their profile or the user menu (must be one of `i18n.locales`).
34-
2. **`i18n.defaultLocale` config** — The server-wide default set in `kibana.yml`.
33+
1. **User profile setting** — The language selected by the user in their
34+
profile or the user menu (must be one of `i18n.locales`).
35+
2. **`KBN_LOCALE` cookie** — The most recently rendered locale on this
36+
browser. {{kib}} writes this cookie on every rendered response, so it
37+
tracks profile changes automatically. The cookie is the fallback used
38+
on surfaces where the profile isn't available — login pages, error
39+
pages, and any browsing the user does after signing out. Only used
40+
when the cookie value matches a locale {{kib}} can serve.
41+
3. **`Accept-Language` header** {applies_to}`serverless: ga` — On
42+
serverless deployments, {{kib}} consults the browser's
43+
`Accept-Language` preferences when neither the profile setting nor
44+
the cookie produces a match. The first weighted preference that's an
45+
exact match (region included) for an entry in `i18n.locales` wins.
46+
This step is skipped on traditional/self-managed deployments to keep
47+
existing users' language stable across upgrades.
48+
4. **`i18n.defaultLocale` config** — The server-wide default set in `kibana.yml`.
49+
50+
#### About the `KBN_LOCALE` cookie
51+
52+
{{kib}} sets a `KBN_LOCALE` cookie on every rendered response containing
53+
the resolved locale id (for example, `KBN_LOCALE=ja-JP`). Attributes:
54+
55+
- Path scoped to the {{kib}} `serverBasePath`.
56+
- `SameSite=Lax`, `Max-Age` of one year, and `Secure` when the response is over HTTPS.
57+
- `HttpOnly`. The value is a preference, not a secret, but {{kib}} does not need browser-side JavaScript to read it.
58+
59+
Privacy posture: `KBN_LOCALE` is a strictly-necessary preference cookie.
60+
It does not track the user, store identity, or enable cross-site activity.
61+
62+
To disable the cookie entirely, set `i18n.allowLocaleCookie: false` in
63+
`kibana.yml`. When disabled, the per-user language selection still works via
64+
user profiles; however, anonymous pages and pages visited after signing out
65+
will always fall back to `i18n.defaultLocale` (or `Accept-Language` on
66+
serverless deployments) rather than remembering the previously resolved locale.
3567

3668
## Example configurations
3769

@@ -51,4 +83,7 @@ i18n.defaultLocale: "en"
5183

5284
# 4. Legacy form — still works, logs a deprecation warning at startup:
5385
i18n.locale: "ja-JP"
54-
```
86+
87+
# 5. Disable the KBN_LOCALE cookie:
88+
i18n.allowLocaleCookie: false
89+
```

docs/reference/configuration-reference/internationalization-settings.yml

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
# This file is used to generate "i18n settings" page in the product docs
3-
# For the schema and an example refer to the automated settings reference:
3+
# For the schema and an example refer to the automated settings reference:
44
# https://github.com/elastic/docs-builder/blob/main/docs/syntax/automated_settings.md
55

66
product: Kibana
@@ -39,6 +39,19 @@ groups:
3939
ech: ga
4040
self: ga
4141

42+
- setting: i18n.allowLocaleCookie
43+
description: |
44+
When `true` (the default), {{kib}} writes a `KBN_LOCALE` cookie on every
45+
rendered response so the browser remembers the resolved locale across
46+
page loads, anonymous pages, and post-logout browsing. Set to `false`
47+
to disable the cookie.
48+
datatype: boolean
49+
default: "true"
50+
applies_to:
51+
stack: ga 9.5+
52+
ech: ga
53+
self: ga
54+
4255
- setting: i18n.locale
4356
description: |
4457
Set the {{kib}} interface language.
@@ -59,4 +72,4 @@ groups:
5972
applies_to:
6073
stack: deprecated 9.5+
6174
ech: ga
62-
self: ga
75+
self: ga

packages/kbn-mock-idp-plugin/public/role_switcher.tsx

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -33,16 +33,16 @@ export const useAuthenticator = (reloadPage = false) => {
3333
body: JSON.stringify(params),
3434
});
3535

36-
if (reloadPage) {
37-
const form = createForm(
38-
services.http.basePath.prepend('/api/security/saml/callback'),
39-
response
40-
);
36+
const { acsUrl, ...samlFields } = response;
37+
const formAction = acsUrl ?? services.http.basePath.prepend('/api/security/saml/callback');
38+
39+
if (reloadPage || acsUrl) {
40+
const form = createForm(formAction, samlFields);
4141
form.submit();
4242
await new Promise(() => {});
4343
} else {
4444
await services.http.post('/api/security/saml/callback', {
45-
body: JSON.stringify(response),
45+
body: JSON.stringify(samlFields),
4646
asResponse: true,
4747
rawResponse: true,
4848
});

packages/kbn-mock-idp-plugin/server/plugin.ts

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -201,6 +201,13 @@ export const plugin: PluginInitializer<void, void, PluginSetupDependencies> = as
201201
const parsed = new URL(request.body.url, 'https://localhost');
202202
const relayState = parsed.searchParams.get('RelayState') ?? undefined;
203203

204+
// Kibana-bound ACS URLs are intentionally left to the `onPreResponse` rewrite above;
205+
// we only override here for external SPs (e.g. UIAM).
206+
const externalAcsUrl =
207+
samlRequestInfo?.acsUrl && !samlRequestInfo.acsUrl.startsWith(MOCK_IDP_SP_BASE_URL)
208+
? samlRequestInfo.acsUrl
209+
: undefined;
210+
204211
return response.ok({
205212
body: {
206213
SAMLResponse: await createSAMLResponse({
@@ -212,9 +219,13 @@ export const plugin: PluginInitializer<void, void, PluginSetupDependencies> = as
212219
? { authnRequestId: samlRequestInfo.requestId }
213220
: {}),
214221
...(samlRequestInfo?.issuer ? { spEntityId: samlRequestInfo.issuer } : {}),
222+
...(externalAcsUrl ? { acsUrl: externalAcsUrl } : {}),
215223
...serverlessOptions,
216224
}),
217225
...(relayState ? { RelayState: relayState } : {}),
226+
// Echoed alongside SAMLResponse so the browser's auto-submitted form posts to UIAM
227+
// instead of the default Kibana ACS endpoint (see mock_idp_page form action).
228+
...(externalAcsUrl ? { acsUrl: externalAcsUrl } : {}),
218229
},
219230
});
220231
} catch (err) {

packages/kbn-optimizer/limits.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,7 @@ pageLoadAssetSize:
169169
securitySolutionEss: 38689
170170
securitySolutionServerless: 52082
171171
serverless: 7412
172-
serverlessObservability: 19300
172+
serverlessObservability: 21437
173173
serverlessSearch: 26287
174174
serverlessVectordb: 7618
175175
serverlessWorkplaceAI: 4855

0 commit comments

Comments
 (0)