From 7a08b6e59435dcb31923a8989df6e50cca76e02c Mon Sep 17 00:00:00 2001 From: Gareth Sylvester-Bradley Date: Tue, 18 Aug 2026 20:36:01 +0100 Subject: [PATCH] Rename ConnectionBridge to nmos-bridge Envoy already proxies Channel Mapping (and Query/DNS-SD/Logging) as well as Connection, so the Connection-only directory and settings names were misleading. Keep the public /x-nmos-bridge path. Signed-off-by: Gareth Sylvester-Bradley --- .github/workflows/build-test.yml | 4 +- Development/package.json | 4 +- Development/src/config.json | 4 +- Development/src/dataProvider.js | 37 +++++++------------ Development/src/pages/settings.js | 36 +++++++----------- Development/src/settings.js | 26 ++++++------- README.md | 6 +-- {ConnectionBridge => nmos-bridge}/README.md | 29 +++++++-------- .../adapter/Dockerfile | 0 .../adapter/index.js | 4 +- .../adapter/package.json | 4 +- .../docker-compose.yml | 2 +- .../docs/channelmapping-proxy-plan.md | 11 +++--- .../envoy/envoy.yaml | 6 +-- .../envoy/location_rewrite.lua | 2 +- .../envoy/location_rewrite_test.lua | 0 16 files changed, 76 insertions(+), 99 deletions(-) rename {ConnectionBridge => nmos-bridge}/README.md (86%) rename {ConnectionBridge => nmos-bridge}/adapter/Dockerfile (100%) rename {ConnectionBridge => nmos-bridge}/adapter/index.js (99%) rename {ConnectionBridge => nmos-bridge}/adapter/package.json (52%) rename {ConnectionBridge => nmos-bridge}/docker-compose.yml (95%) rename {ConnectionBridge => nmos-bridge}/docs/channelmapping-proxy-plan.md (92%) rename {ConnectionBridge => nmos-bridge}/envoy/envoy.yaml (96%) rename {ConnectionBridge => nmos-bridge}/envoy/location_rewrite.lua (99%) rename {ConnectionBridge => nmos-bridge}/envoy/location_rewrite_test.lua (100%) diff --git a/.github/workflows/build-test.yml b/.github/workflows/build-test.yml index fff7b464..2dd31dde 100644 --- a/.github/workflows/build-test.yml +++ b/.github/workflows/build-test.yml @@ -10,11 +10,11 @@ env: SECRET_GOOGLE_CREDENTIALS: ${{ secrets.GOOGLE_CREDENTIALS }} SECRET_RESULTS_SHEET_ID: ${{ secrets.RESULTS_SHEET_ID }} jobs: - connection_bridge_lua: + nmos_bridge_lua: runs-on: ubuntu-22.04 defaults: run: - working-directory: ConnectionBridge/envoy + working-directory: nmos-bridge/envoy steps: - uses: actions/checkout@v7 diff --git a/Development/package.json b/Development/package.json index 119f85b3..1dfc1d5b 100644 --- a/Development/package.json +++ b/Development/package.json @@ -35,8 +35,8 @@ "build": "react-scripts build", "test": "react-scripts test --env=jsdom", "eject": "react-scripts eject", - "lint": "eslint --fix ./ && prettier --config .prettierrc.js --write src/**/*.js ../ConnectionBridge/**/*.js", - "lint-check": "eslint --fix-dry-run ./ && prettier --config .prettierrc.js --check src/**/*.js ../ConnectionBridge/**/*.js" + "lint": "eslint --fix ./ && prettier --config .prettierrc.js --write src/**/*.js ../nmos-bridge/**/*.js", + "lint-check": "eslint ./ && prettier --config .prettierrc.js --check src/**/*.js ../nmos-bridge/**/*.js" }, "devDependencies": { "@babel/core": "^7.29.6", diff --git a/Development/src/config.json b/Development/src/config.json index bb47e17b..39114d8e 100644 --- a/Development/src/config.json +++ b/Development/src/config.json @@ -45,9 +45,9 @@ "Auth Enabled": { "value": false }, - "Connection Bridge Mode": { + "NMOS Bridge Mode": { "value": "disabled" }, - "Connection Bridge API": { + "NMOS Bridge API": { } } diff --git a/Development/src/dataProvider.js b/Development/src/dataProvider.js index ce879975..9196519a 100644 --- a/Development/src/dataProvider.js +++ b/Development/src/dataProvider.js @@ -13,9 +13,9 @@ import { JsonPointer } from 'json-ptr'; import diff from 'deep-diff'; import { makeBearerAuthHeader } from './authProvider'; import { + BRIDGE_API, BRIDGE_AUTO, BRIDGE_FORCED, - CONNECTION_BRIDGE_API, DNSSD_API, LOGGING_API, QUERY_API, @@ -23,19 +23,16 @@ import { apiUrl, apiUsingRql, apiVersion, + bridgeMode, concatUrl, - connectionBridgeMode, usingAuth, } from './settings'; -// the Connection API Bridge (see ../../ConnectionBridge) makes Device -// Connection and Channel Mapping APIs available at a configured base URL for -// deployments where the browser cannot reach the Device directly +// the NMOS Bridge (see ../../nmos-bridge) makes Device Control APIs +// available at a configured base URL for deployments where the browser +// cannot reach the Device directly const bridgeAddress = (deviceId, api, version) => - concatUrl( - apiUrl(CONNECTION_BRIDGE_API), - `/devices/${deviceId}/${api}/${version}` - ); + concatUrl(apiUrl(BRIDGE_API), `/devices/${deviceId}/${api}/${version}`); // which access path, direct or bridge, most recently worked for each Device const deviceAccessPaths = new Map(); @@ -895,7 +892,7 @@ const convertHTTPResponseToDataProvider = async ( .reverse(); const deviceId = resourceJSONData.device_id; - const bridgeMode = connectionBridgeMode(); + const mode = bridgeMode(); let endpointData; let accessPath; @@ -910,13 +907,10 @@ const convertHTTPResponseToDataProvider = async ( // inaccessible; start with whichever worked last time, // unless the bridge is forced const attempts = []; - if (bridgeMode !== BRIDGE_FORCED) { + if (mode !== BRIDGE_FORCED) { attempts.push(['direct', connectionAddresses[version]]); } - if ( - bridgeMode === BRIDGE_AUTO || - bridgeMode === BRIDGE_FORCED - ) { + if (mode === BRIDGE_AUTO || mode === BRIDGE_FORCED) { attempts.push([ 'bridge', [ @@ -929,7 +923,7 @@ const convertHTTPResponseToDataProvider = async ( ]); } if ( - bridgeMode === BRIDGE_AUTO && + mode === BRIDGE_AUTO && deviceAccessPaths.get(deviceId) === 'bridge' ) { attempts.reverse(); @@ -1001,7 +995,7 @@ const convertHTTPResponseToDataProvider = async ( .reverse(); const deviceId = deviceJSONData.id; - const bridgeMode = connectionBridgeMode(); + const mode = bridgeMode(); let endpointData; let accessPath; @@ -1015,16 +1009,13 @@ const convertHTTPResponseToDataProvider = async ( // bridge; start with whichever path last worked for this // Device unless Forced const attempts = []; - if (bridgeMode !== BRIDGE_FORCED) { + if (mode !== BRIDGE_FORCED) { attempts.push([ 'direct', channelmappingAddresses[version], ]); } - if ( - bridgeMode === BRIDGE_AUTO || - bridgeMode === BRIDGE_FORCED - ) { + if (mode === BRIDGE_AUTO || mode === BRIDGE_FORCED) { attempts.push([ 'bridge', [ @@ -1037,7 +1028,7 @@ const convertHTTPResponseToDataProvider = async ( ]); } if ( - bridgeMode === BRIDGE_AUTO && + mode === BRIDGE_AUTO && deviceAccessPaths.get(deviceId) === 'bridge' ) { attempts.reverse(); diff --git a/Development/src/pages/settings.js b/Development/src/pages/settings.js index 5bc9715f..675530e3 100644 --- a/Development/src/pages/settings.js +++ b/Development/src/pages/settings.js @@ -20,12 +20,12 @@ import { useTheme } from '@material-ui/styles'; import { Title } from 'react-admin'; import { AUTH_API, + BRIDGE_API, BRIDGE_AUTO, BRIDGE_DISABLED, BRIDGE_FORCED, + BRIDGE_MODE, CLIENT_ID, - CONNECTION_BRIDGE_API, - CONNECTION_BRIDGE_MODE, DNSSD_API, FRIENDLY_PARAMETERS, IS12_BROWSER, @@ -348,20 +348,16 @@ const Settings = () => { )} - {!hiddenSetting(CONNECTION_BRIDGE_MODE) && ( + {!hiddenSetting(BRIDGE_MODE) && ( {bridgeModes.map(option => ( { )} - {!hiddenSetting(CONNECTION_BRIDGE_API) && ( + {!hiddenSetting(BRIDGE_API) && ( )} diff --git a/Development/src/settings.js b/Development/src/settings.js index 2489c1f5..06d2065a 100644 --- a/Development/src/settings.js +++ b/Development/src/settings.js @@ -17,9 +17,9 @@ export const CLIENT_ID = 'Client ID'; export const IS12_BROWSER = 'IS-12 Browser'; -export const CONNECTION_BRIDGE_API = 'Connection Bridge API'; -export const CONNECTION_BRIDGE_MODE = 'Connection Bridge Mode'; -// Connection Bridge modes +export const BRIDGE_API = 'NMOS Bridge API'; +export const BRIDGE_MODE = 'NMOS Bridge Mode'; +// NMOS Bridge modes export const BRIDGE_DISABLED = 'disabled'; export const BRIDGE_AUTO = 'auto'; export const BRIDGE_FORCED = 'forced'; @@ -44,7 +44,7 @@ const defaultUrl = api => { return baseUrl + '/log/v1.0'; case QUERY_API: return baseUrl + '/x-nmos/query/v1.3'; - case CONNECTION_BRIDGE_API: + case BRIDGE_API: return baseUrl + '/x-nmos-bridge/v1.0'; case DNSSD_API: return baseUrl + '/x-dns-sd/v1.1'; @@ -128,8 +128,8 @@ export const setUsingAuth = auth => { }; // an unrecognized stored value falls back to the default mode -export const connectionBridgeMode = () => { - const mode = getJSONSetting(CONNECTION_BRIDGE_MODE, BRIDGE_DISABLED); +export const bridgeMode = () => { + const mode = getJSONSetting(BRIDGE_MODE, BRIDGE_DISABLED); return [BRIDGE_DISABLED, BRIDGE_AUTO, BRIDGE_FORCED].includes(mode) ? mode : BRIDGE_DISABLED; @@ -194,8 +194,8 @@ const useSettings = () => { [PAGING_LIMIT]: apiPagingLimit(QUERY_API), [USE_RQL]: apiUsingRql(QUERY_API), [FRIENDLY_PARAMETERS]: getJSONSetting(FRIENDLY_PARAMETERS, false), - [CONNECTION_BRIDGE_MODE]: connectionBridgeMode(), - [CONNECTION_BRIDGE_API]: apiUrl(CONNECTION_BRIDGE_API), + [BRIDGE_MODE]: bridgeMode(), + [BRIDGE_API]: apiUrl(BRIDGE_API), [CLIENT_ID]: authClientId(), [AUTH_API]: apiUrl(AUTH_API), [IS12_BROWSER]: apiUrl(IS12_BROWSER), @@ -212,13 +212,9 @@ const useSettings = () => { if (isEffective(USE_RQL)) setApiUsingRql(QUERY_API, values[USE_RQL]); if (isEffective(FRIENDLY_PARAMETERS)) setJSONSetting(FRIENDLY_PARAMETERS, values[FRIENDLY_PARAMETERS]); - if (isEffective(CONNECTION_BRIDGE_MODE)) - setJSONSetting( - CONNECTION_BRIDGE_MODE, - values[CONNECTION_BRIDGE_MODE] - ); - if (isEffective(CONNECTION_BRIDGE_API)) - setApiUrl(CONNECTION_BRIDGE_API, values[CONNECTION_BRIDGE_API]); + if (isEffective(BRIDGE_MODE)) + setJSONSetting(BRIDGE_MODE, values[BRIDGE_MODE]); + if (isEffective(BRIDGE_API)) setApiUrl(BRIDGE_API, values[BRIDGE_API]); if (isEffective(CLIENT_ID)) setAuthClientId(values[CLIENT_ID]); if (isEffective(AUTH_API)) setApiUrl(AUTH_API, values[AUTH_API]); if (isEffective(IS12_BROWSER)) diff --git a/README.md b/README.md index 27c81c94..a176ac59 100644 --- a/README.md +++ b/README.md @@ -31,8 +31,8 @@ After setting up the dependencies, follow these [instructions](Documents/Getting The web application can also be packaged and deployed with the [nmos-cpp-registry application](https://github.com/sony/nmos-cpp). Copy the contents of the nmos-js build directory into the admin directory next to the nmos-cpp-registry executable. -For deployments where the browser cannot reach Device Connection APIs directly, -the optional [NMOS Connection API Bridge](ConnectionBridge/README.md) provides +For deployments where the browser cannot reach Device Control APIs directly, +the optional [NMOS Bridge](nmos-bridge/README.md) provides controlled access through Envoy. ## Agile Development @@ -73,7 +73,7 @@ The implementation is designed to be extended. Development is ongoing, following Recent activity on the project (newest first): -- Added the optional NMOS Connection API Bridge. +- Added the optional NMOS Bridge (formerly Connection API Bridge). - Launch IS-12 Device Model browser client from within nmos-js Device summary tab. - Added BCP-007-03 NMOS Support for MXL - Added prototype [IS-12 Device Model browser client](is12-client/README.md). diff --git a/ConnectionBridge/README.md b/nmos-bridge/README.md similarity index 86% rename from ConnectionBridge/README.md rename to nmos-bridge/README.md index e9c9a5c3..d7af5b34 100644 --- a/ConnectionBridge/README.md +++ b/nmos-bridge/README.md @@ -1,4 +1,4 @@ -# NMOS Connection API Bridge +# NMOS Bridge Provides browser-accessible proxy access to [AMWA IS-05](https://specs.amwa.tv/is-05/) Connection APIs and [AMWA IS-08](https://specs.amwa.tv/is-08/) Channel Mapping APIs exposed by Devices registered in an NMOS Registry, where the browser may not have network access to the Device APIs directly. @@ -52,7 +52,7 @@ Browser | +--(HTTP)------------------> Envoy | - +--> /x-nmos-bridge/... --> Device Connection APIs + +--> /x-nmos-bridge/... --> Device Control APIs | +--> /x-nmos -> ["query/"] (fixed listing) | @@ -72,10 +72,10 @@ Adapter (server-side; not on the browser path) +--(HTTP / WebSocket)------> Registry Query API (Device discovery) ``` -The Connection API Bridge consists of Envoy and the adapter service: +The NMOS Bridge consists of Envoy and the adapter service: -- **Envoy** proxies browser HTTP to Device Connection and Channel Mapping APIs on `/x-nmos-bridge/...` (required for the bridge). It may also proxy the Query API on `/x-nmos/query/...`, DNS-SD on `/x-dns-sd/...`, and the nmos-js app on `/` as optional convenience. `GET /x-nmos/` returns a fixed listing of `["query/"]` so discovery matches what is actually proxied. Other `/x-nmos/` APIs (Registration, Node, …) are not proxied — they may use different ports. It applies routing, request size limits, timeouts, retry policy, health checking and failover, and access logging of mutating requests. It does not proxy Query API WebSocket subscriptions. -- **The adapter** (`adapter/`) converts Registry state into Envoy configuration. It tracks Devices through a [Query API WebSocket subscription](https://specs.amwa.tv/is-04/branches/v1.3.x/docs/4.2._Behaviour_-_Querying.html) (non-persistent, `resource_path` `/devices`), extracts Connection and Channel Mapping API controls, and generates Envoy routes and clusters, atomically replacing the dynamic configuration files (`rds.json`, `cds.json`) which Envoy reloads via filesystem watch. The adapter does not proxy traffic and does not determine runtime health. +- **Envoy** proxies browser HTTP to Device Control APIs on `/x-nmos-bridge/...` (required for the bridge). It may also proxy the Query API on `/x-nmos/query/...`, DNS-SD on `/x-dns-sd/...`, and the nmos-js app on `/` as optional convenience. `GET /x-nmos/` returns a fixed listing of `["query/"]` so discovery matches what is actually proxied. Other `/x-nmos/` APIs (Registration, Node, …) are not proxied — they may use different ports. It applies routing, request size limits, timeouts, retry policy, health checking and failover, and access logging of mutating requests. It does not proxy Query API WebSocket subscriptions. +- **The adapter** (`adapter/`) converts Registry state into Envoy configuration. It tracks Devices through a [Query API WebSocket subscription](https://specs.amwa.tv/is-04/branches/v1.3.x/docs/4.2._Behaviour_-_Querying.html) (non-persistent, `resource_path` `/devices`), extracts Device Control API controls, and generates Envoy routes and clusters, atomically replacing the dynamic configuration files (`rds.json`, `cds.json`) which Envoy reloads via filesystem watch. The adapter does not proxy traffic and does not determine runtime health. On connecting, the Registry sends a sync of all current Devices, then pushes added, modified and removed events; the adapter rebuilds configuration on each change. If the connection is interrupted, the adapter resubscribes with exponential backoff and the fresh sync re-establishes all mappings, including Devices that were removed while disconnected. The last good configuration keeps being served until the new sync arrives. @@ -133,7 +133,7 @@ Edit `docker-compose.yml` first to point the adapter at the deployment: Envoy listens on port 8080 and routes: -- `/x-nmos` and `/x-nmos/` return a fixed IS-04-style listing of `["query/"]` (only what this front door proxies) +- `/x-nmos` and `/x-nmos/` return a fixed IS-04-style listing of `["query/"]` (only what this Envoy instance proxies) - `/x-nmos/query/...` to the Registry Query API (convenience; see Deployment) - `/x-dns-sd/...` to the Registry DNS-SD / MDNS API (convenience; same upstream as Query unless `REGISTRY_DNS_SD_URL` is set) - `/log/...` to the Registry Logging API (convenience; same upstream as Query unless `REGISTRY_LOGGING_URL` is set) @@ -157,7 +157,7 @@ those APIs listen elsewhere (for example a different `mdns_port` or serves the UI under `/admin` (nmos-cpp-registry). In both cases Envoy's `/log/` route supports the SPA Logging API default (`{origin}/log/v1.0`). -Configure nmos-js **Connection Bridge API** to the bridge base, for example: +Configure nmos-js **NMOS Bridge API** to the bridge base, for example: ```text http://controller.example.com:8080/x-nmos-bridge/v1.0 @@ -171,7 +171,7 @@ A layout that also proxies Query and Logging through Envoy might use: ```text Query API: http://controller.example.com:8080/x-nmos/query/v1.3 Logging API: http://controller.example.com:8080/log/v1.0 -Connection Bridge API: http://controller.example.com:8080/x-nmos-bridge/v1.0 +NMOS Bridge API: http://controller.example.com:8080/x-nmos-bridge/v1.0 ``` Query API WebSocket subscriptions are not proxied by Envoy. Subscription @@ -185,7 +185,7 @@ the Query API and the WebSocket URL from the subscription response. Set name or port which is not reachable from the adapter, for example `ws://192.168.6.101:81`. -Envoy must be able to reach every Device Connection API `href` which is to be +Envoy must be able to reach every Device Control API `href` which is to be used through the bridge. This is independent of browser reachability: the purpose of the bridge is to place Envoy on the Device networks when the browser cannot access those networks directly. Configure the container or @@ -208,22 +208,21 @@ the bridge. The same adapter and Envoy arrangement can be deployed as containers sharing a writable configuration volume. In Kubernetes, they can run as containers in one Pod with an `emptyDir` volume. The Pod needs network interfaces and -routes which can reach the Device Connection API addresses; this may require +routes which can reach the Device Control API addresses; this may require secondary networking in deployments where media devices are outside the cluster network. Kubernetes and OpenShift manifests are deployment-specific and are not included here. ## Browser Application Behavior -The nmos-js client offers a **Connection Bridge Mode** and a separate -**Connection Bridge API**. The same mode applies to Device Connection (IS-05) -and Channel Mapping (IS-08) fetches: +The nmos-js client offers a **NMOS Bridge Mode** and a separate +**NMOS Bridge API**. The same mode applies to Device Control API fetches (Connection, Channel Mapping, …): - **No Bridge** (default): use the Device control hrefs directly, never the bridge. -- **Auto Bridge**: the preferred access sequence. Use the Device control href directly; if inaccessible, use the bridge URL; cache the successful access path per Device (shared across Connection and Channel Mapping). Note that on first access to a Device that is not directly reachable, the browser must wait for the direct attempt to fail (up to 5 seconds) before falling back; the cached path avoids this on subsequent accesses. +- **Auto Bridge**: the preferred access sequence. Use the Device control href directly; if inaccessible, use the bridge URL; cache the successful access path per Device (shared across Device Control APIs). Note that on first access to a Device that is not directly reachable, the browser must wait for the direct attempt to fail (up to 5 seconds) before falling back; the cached path avoids this on subsequent accesses. - **Forced Bridge**: always use the bridge, skipping direct attempts entirely. Useful when it is known that no Device is reachable from the browser. -`POST`, `PATCH` and `DELETE` requests are not automatically retried via alternate paths; they follow whichever path was resolved for the Device (`$connectionAPI` / `$channelmappingAPI`). Bridge requests use the configured Connection Bridge API (default: SPA origin + `/x-nmos-bridge/v1.0`). +`POST`, `PATCH` and `DELETE` requests are not automatically retried via alternate paths; they follow whichever path was resolved for the Device (`$connectionAPI` / `$channelmappingAPI`). Bridge requests use the configured NMOS Bridge API (default: SPA origin + `/x-nmos-bridge/v1.0`). ## Status diff --git a/ConnectionBridge/adapter/Dockerfile b/nmos-bridge/adapter/Dockerfile similarity index 100% rename from ConnectionBridge/adapter/Dockerfile rename to nmos-bridge/adapter/Dockerfile diff --git a/ConnectionBridge/adapter/index.js b/nmos-bridge/adapter/index.js similarity index 99% rename from ConnectionBridge/adapter/index.js rename to nmos-bridge/adapter/index.js index 93f427bb..56d7835f 100644 --- a/ConnectionBridge/adapter/index.js +++ b/nmos-bridge/adapter/index.js @@ -1,6 +1,6 @@ 'use strict'; -// NMOS Connection API Bridge - Envoy Adapter +// NMOS Bridge - Envoy Adapter // // Converts Registry state into Envoy configuration. Tracks Devices through a // Query API WebSocket subscription, extracts their Connection and Channel @@ -503,7 +503,7 @@ const routeConfiguration = targets => ({ timeout: `${ROUTE_TIMEOUT_SECONDS}s`, }, }, - // IS-04 /x-nmos base: list only APIs this Envoy front door + // IS-04 /x-nmos base: list only APIs this Envoy instance // actually proxies (not Registration/Node/etc.) { match: { path: '/x-nmos' }, diff --git a/ConnectionBridge/adapter/package.json b/nmos-bridge/adapter/package.json similarity index 52% rename from ConnectionBridge/adapter/package.json rename to nmos-bridge/adapter/package.json index 7605f0ad..8ba82a3b 100644 --- a/ConnectionBridge/adapter/package.json +++ b/nmos-bridge/adapter/package.json @@ -1,8 +1,8 @@ { - "name": "nmos-connection-bridge-adapter", + "name": "nmos-bridge-adapter", "version": "0.1.0", "private": true, - "description": "Generates Envoy configuration for the NMOS Connection API Bridge from Query API WebSocket events", + "description": "Generates Envoy configuration for the NMOS Bridge from Query API WebSocket events", "main": "index.js", "scripts": { "start": "node index.js" diff --git a/ConnectionBridge/docker-compose.yml b/nmos-bridge/docker-compose.yml similarity index 95% rename from ConnectionBridge/docker-compose.yml rename to nmos-bridge/docker-compose.yml index 1b97b257..5d41de47 100644 --- a/ConnectionBridge/docker-compose.yml +++ b/nmos-bridge/docker-compose.yml @@ -1,4 +1,4 @@ -# Example deployment of the NMOS Connection API Bridge. +# Example deployment of the NMOS Bridge. # # The Registry and the nmos-js app are expected to be reachable from these # containers; adjust REGISTRY_QUERY_URL and APP_URL (and the network diff --git a/ConnectionBridge/docs/channelmapping-proxy-plan.md b/nmos-bridge/docs/channelmapping-proxy-plan.md similarity index 92% rename from ConnectionBridge/docs/channelmapping-proxy-plan.md rename to nmos-bridge/docs/channelmapping-proxy-plan.md index 1e342da4..359d4b94 100644 --- a/ConnectionBridge/docs/channelmapping-proxy-plan.md +++ b/nmos-bridge/docs/channelmapping-proxy-plan.md @@ -1,7 +1,7 @@ # Design plan: Envoy proxying for IS-08 Channel Mapping API -Status: proposal (not implemented). Extends the Connection API Bridge in -`ConnectionBridge/README.md`, which today proxies browser HTTP only for Device +Status: proposal (not implemented). Extends the NMOS Bridge in +`nmos-bridge/README.md`, which today proxies browser HTTP only for Device Connection controls (`urn:x-nmos:control:sr-ctrl/{version}`). ## Motivation @@ -10,7 +10,7 @@ IS-08 Channel Mapping is advertised on Devices as `urn:x-nmos:control:cm-ctrl/{version}` with an HTTP `href` (nmos-cpp: `http://host:port/x-nmos/channelmapping/{version}`). nmos-js already loads Channel Mapping data from those hrefs for the Device UI, but it does **not** -use the Connection Bridge. In deployments where the browser cannot reach Device +use the NMOS Bridge. In deployments where the browser cannot reach Device networks, IS-05 works via `/x-nmos-bridge/...` while IS-08 still fails. Channel Mapping is the same reachability class as Connection: HTTP Device @@ -98,8 +98,7 @@ bridge via existing `Location` handling. nmos-cpp may differ from the Connection API port). - No change to Query HTTP convenience routes or adapter Device discovery. - README: document Channel Mapping under the bridge public API and method - list; keep "Connection API Bridge" naming until a broader rename is decided - (optional later: "Device control bridge"). + list. ## Non-goals @@ -130,6 +129,6 @@ bridge via existing `Location` handling. ## References -- `ConnectionBridge/README.md` — Connection bridge mapping and deployment +- `nmos-bridge/README.md` — Connection bridge mapping and deployment - IS-08 Channel Mapping / `urn:x-nmos:control:cm-ctrl` - nmos-js `dataProvider` Channel Mapping paths (direct hrefs today) diff --git a/ConnectionBridge/envoy/envoy.yaml b/nmos-bridge/envoy/envoy.yaml similarity index 96% rename from ConnectionBridge/envoy/envoy.yaml rename to nmos-bridge/envoy/envoy.yaml index 62a32ab5..47a017bb 100644 --- a/ConnectionBridge/envoy/envoy.yaml +++ b/nmos-bridge/envoy/envoy.yaml @@ -1,11 +1,11 @@ -# NMOS Connection API Bridge - Envoy bootstrap configuration +# NMOS Bridge - Envoy bootstrap configuration # # Routes and clusters are dynamic, generated by the adapter from Registry # state and reloaded from /etc/envoy/dynamic via filesystem watch. node: - id: nmos-connection-bridge - cluster: nmos-connection-bridge + id: nmos-bridge + cluster: nmos-bridge dynamic_resources: cds_config: diff --git a/ConnectionBridge/envoy/location_rewrite.lua b/nmos-bridge/envoy/location_rewrite.lua similarity index 99% rename from ConnectionBridge/envoy/location_rewrite.lua rename to nmos-bridge/envoy/location_rewrite.lua index fd727893..940da482 100644 --- a/ConnectionBridge/envoy/location_rewrite.lua +++ b/nmos-bridge/envoy/location_rewrite.lua @@ -1,4 +1,4 @@ --- Handle Connection API Bridge upstream 3xx Location headers. +-- Handle NMOS Bridge upstream 3xx Location headers. -- -- Relative Location values are resolved against the reconstructed upstream -- request path (base_path + suffix of the downstream bridge path). That path diff --git a/ConnectionBridge/envoy/location_rewrite_test.lua b/nmos-bridge/envoy/location_rewrite_test.lua similarity index 100% rename from ConnectionBridge/envoy/location_rewrite_test.lua rename to nmos-bridge/envoy/location_rewrite_test.lua