Skip to content

v0.8.0

Choose a tag to compare

@github-actions github-actions released this 10 Nov 23:28
· 189 commits to main since this release
87e5fe5

Lightspeed v0.8.0 lets MCP servers authenticate with custom request headers, lets credentials change their value without editing anything that uses them, and makes large workspaces faster to browse and their upload limits configurable.

Compatibility and upgrade

  • This is a breaking release that requires a new Temporal namespace. scripts/release/workflow-compat.sh v0.7.2 reports breaking because the public API crate, which the workflow crate depends on, changed. It's probably a false alarm for running work, but the verdict stands: drain open work and start on a new namespace, as described in Upgrades and recovery.
  • Keep your runtime database. Runtime schema revision is 15. Migration 15 adds the mcp_server_headers table and relabels existing token credentials (see the rename below); it converts data in place and needs no reset.
  • Unchanged: Platform schema revision stays 4. The public API protocol identifier stays lightspeed.agent.api.v1, the envd protocol stays 5, and the controller protocol stays 4.
  • Wire rename: the credential kind staticBearer is now staticToken in the API (and static_token in storage). Update clients, scripts and dashboards that read or send providerKind: "staticBearer", and pin @lightspeed-ai/sdk to 0.8.0 if you rely on its types. The MCP auth policies optionalBearer and requiredBearer keep their names.
  • Platform UI label: the Credentials page calls this kind Token, not "Bearer token".

Moving from v0.7.2

  1. Stop new work and drain or cancel open runs. Keep a backup of the runtime and Platform databases and object storage.

  2. Create a new Temporal namespace. Set TEMPORAL_NAMESPACE to it on every runtime process, on the connector host, and on any custom worker running your workflow tools, in the same step as the release change.

  3. With the v0.8.0 executable, against your existing runtime database:

    lightspeed-runtime migrate
    lightspeed-runtime schema-version

    Require runtime schema revision 15 before starting services.

  4. Start matching runtime, Platform, Configurator, connector and client components from one manifest.

  5. Sessions that were open report a stopped workflow until restarted; restart them as needed. Bots continue in new sessions at their next event. The upgrade guide lists what happens to each kind of open work.

MCP servers: custom request headers

  • An MCP server can send extra request headers. Each is either plain text, stored and shown as written, or a credential that names a token from Credentials, whose value is sent exactly as stored, with no Bearer prefix. This covers self-hosted gateways that expect, for example, X-Upstream-Url and X-Upstream-Token (#138).
  • Which requests: every request to the server carries the headers, from discovery to tool calls and session traffic. Credential values are resolved on each request and are never stored on the server or logged.
  • Authentication setting: with the token in a header, choose No authentication, which only controls Authorization. The server list then shows Request headers as its authentication. Headers also work alongside a bearer token or OAuth.
  • Limits:
    • headers require Lightspeed connects; provider-direct execution is refused while headers are set;
    • Authorization, transport headers such as Content-Type and Mcp-Session-Id, and X-Lightspeed-* are reserved; names are case-insensitive;
    • a credential header needs an active token, and if the token has an audience, it must cover the server URL;
    • a credential used by a header cannot be deleted.
  • Where: Customize → Request headers on the MCP server form; --header NAME=VALUE and --header-credential NAME=GRANT_ID on lightspeed mcp server put; headers on mcp/servers/put.

Replace a credential's value

  • Tokens and environment secrets can take a new value under the same credential ID: Replace value on the Credentials page, lightspeed auth grants replace ID --token-stdin, or auth/grants/replace. Everything referencing the ID, including MCP servers, request headers, bot polls and environment variables, uses the new value from its next request or process. Processes already running and leases already issued keep the old value. OAuth and GitHub App credentials renew themselves and can't be replaced this way.

  • Model API keys now replace in place through auth/providers/replace. Platform's Replace key used to delete the provider and create it again, which had three problems:

    • a rejected new setting lost the key;
    • sessions briefly lost the provider;
    • a key bound to an environment variable couldn't be replaced at all.

    The new settings are now validated first, and a rejected replacement keeps the old key.

Workspaces

  • Faster browsing: folders start collapsed, so opening a large workspace renders only its top level. Folders containing the file you're viewing open automatically, including when you follow a link to it (#140).
  • Configurable upload limits (#141):
    • LIGHTSPEED_PLATFORM_WORKSPACE_UPLOAD_MAX_BYTES (default 32 MiB, up to 256 MiB) and LIGHTSPEED_PLATFORM_WORKSPACE_UPLOAD_MAX_ENTRIES (default 10,000) set them;
    • the request body limit follows at 1.5× the content limit;
    • the web UI checks against the deployment's values;
    • the Platform holds an upload in memory, so higher limits raise its peak memory per upload;
    • each file reaches the runtime in its own request, so a single file above about 47 MiB also needs a larger LIGHTSPEED_GATEWAY_MAX_REQUEST_BODY_BYTES.

Fixes

  • Two writers storing identical bytes at the same moment, for example sibling tool calls returning the same result, could fail with a duplicate-key error on cas_blobs_blob_ref_idx and fail the tool call. Content-addressed inserts now treat that race as a successful write.

Validation

Passed:

  • Rust: Clippy with warnings as errors, cargo fmt, and the unit tests of the changed crates.
  • Live suites:
    • store_pg_live (48), migrations_live, and mcp_live (8).
    • The live tests cover delivering headers on discovery and tool calls, the next request after a replacement carrying the new token, a revoked credential failing before anything is sent, and a rejected model-key replacement keeping the old key.
  • TypeScript: typecheck, web (1,083), Platform backend (366), consumer tests, the docs site check, and the build.
  • The upgrade itself: migration 15 was applied to a schema holding a v0.7.2 token credential, and a token sealed under the old kind still resolves.

Not run:

  • the remaining live suites;
  • runs_live_slow;
  • any provider-credentialed suite;
  • a move of a real installation with open work to a new namespace.

Full changelog: v0.7.2...v0.8.0