PROD-8165 add extension development/deployment documentation - #538
Open
ivbond wants to merge 5 commits into
Open
PROD-8165 add extension development/deployment documentation#538ivbond wants to merge 5 commits into
ivbond wants to merge 5 commits into
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Adds a new “Extensions” documentation section to the ThingsBoard docs site, including end-to-end guidance for building, deploying, and operating ThingsBoard extensions, and exposes that section in the Reference navigation.
Changes:
- Introduces new Extensions reference pages (overview, quickstart, dev workflow, CLI deploy reference, REST deployment API) for CE/PE/Cloud variants via shared
_includes. - Adds Extensions links to the “APIs & SDKs” reference landing include and to the generated sidebar navigation.
- Adds new extension-related schema diagrams (light/dark variants) used by the docs.
Reviewed changes
Copilot reviewed 27 out of 41 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| src/content/docs/docs/reference/extensions/quickstart.mdx | CE wrapper page for Extensions quickstart include |
| src/content/docs/docs/reference/extensions/overview.mdx | CE wrapper page for Extensions overview include |
| src/content/docs/docs/reference/extensions/development-workflow.mdx | CE wrapper page for development workflow include |
| src/content/docs/docs/reference/extensions/deployment-api.mdx | CE wrapper page for deployment API include |
| src/content/docs/docs/reference/extensions/cli-deployment.mdx | CE wrapper page for CLI deployment include |
| src/content/docs/docs/pe/reference/extensions/quickstart.mdx | PE wrapper page for Extensions quickstart include |
| src/content/docs/docs/pe/reference/extensions/overview.mdx | PE wrapper page for Extensions overview include |
| src/content/docs/docs/pe/reference/extensions/development-workflow.mdx | PE wrapper page for development workflow include |
| src/content/docs/docs/pe/reference/extensions/deployment-api.mdx | PE wrapper page for deployment API include |
| src/content/docs/docs/pe/reference/extensions/cli-deployment.mdx | PE wrapper page for CLI deployment include |
| src/content/docs/docs/paas/reference/extensions/quickstart.mdx | PaaS wrapper page for Extensions quickstart include |
| src/content/docs/docs/paas/reference/extensions/overview.mdx | PaaS wrapper page for Extensions overview include |
| src/content/docs/docs/paas/reference/extensions/development-workflow.mdx | PaaS wrapper page for development workflow include |
| src/content/docs/docs/paas/reference/extensions/deployment-api.mdx | PaaS wrapper page for deployment API include |
| src/content/docs/docs/paas/reference/extensions/cli-deployment.mdx | PaaS wrapper page for CLI deployment include |
| src/content/docs/docs/paas/eu/reference/extensions/quickstart.mdx | PaaS EU wrapper page for Extensions quickstart include |
| src/content/docs/docs/paas/eu/reference/extensions/overview.mdx | PaaS EU wrapper page for Extensions overview include |
| src/content/docs/docs/paas/eu/reference/extensions/development-workflow.mdx | PaaS EU wrapper page for development workflow include |
| src/content/docs/docs/paas/eu/reference/extensions/deployment-api.mdx | PaaS EU wrapper page for deployment API include |
| src/content/docs/docs/paas/eu/reference/extensions/cli-deployment.mdx | PaaS EU wrapper page for CLI deployment include |
| src/content/_includes/docs/reference/extensions/quickstart.mdx | Shared quickstart content (Java/Python tabs + CLI workflow) |
| src/content/_includes/docs/reference/extensions/overview.mdx | Shared overview content (architecture, routing/auth, lifecycle, run modes) |
| src/content/_includes/docs/reference/extensions/development-workflow.mdx | Shared “full loop” workflow guide content |
| src/content/_includes/docs/reference/extensions/deployment-api.mdx | Shared REST deployment API reference content |
| src/content/_includes/docs/reference/extensions/cli-deployment.mdx | Shared CLI deploy/reference content |
| src/content/_includes/docs/reference/apis-and-sdks.mdx | Adds an “Extensions” card/links to the reference landing include |
| src/assets/schemas/extension-mode-self-hosted.svg | New diagram asset used in Extensions overview (light) |
| src/assets/schemas/extension-mode-self-hosted-dark.svg | New diagram asset used in Extensions overview (dark) |
| src/assets/schemas/extension-lifecycle.svg | New diagram asset used in Extensions overview (light) |
| src/assets/schemas/extension-lifecycle-dark.svg | New diagram asset used in Extensions overview (dark) |
| astro.sidebar.ts | Adds “Extensions” group under APIs & SDKs sidebar section |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
…-ext-deployment-doc # Conflicts: # src/assets/images/user-guide/cli/project-structure.svg # src/content/_includes/docs/user-guide/cli-solutions.mdx
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
ThingsBoard 4.4.0 adds extensions: a tenant can ship its own REST API as a Docker image, and ThingsBoard runs it next to the platform. The feature had no documentation. This PR writes it.
Five new pages, ~1 200 lines of content, published for four products (CE, PE, Cloud, Cloud EU):
tb extension deployandtb extension deploymentsNothing outside the extensions topic changes behaviour. Four existing pages get a link to the new section, and the CLI page is added under the ThingsBoard CLI group.
What it looks like
1. New section and how it is served
2. Architecture — how a request reaches the container
/api/extension/route/{slug}/…, on the same origin as the UI.GET /api/ext-authwhether this caller may use this slug. The check is fail-closed: no answer means no forwarding.The page carries seven diagrams, each drawn twice for the light and the dark theme.
3. Architecture — the two private managed modes
extensions.mode.private-cloud— Kubernetes, the cluster ThingsBoard already runs in, extensions in their own namespace. Replicas work as asked.docker-compose— one Docker host. It always runs one container whatever replica count you ask for, because a single host has no load balancer behind a container name. This is easy to hit and was worth stating plainly.4. Quickstart — a real run, not a sketch
tb init demotranscript, so a reader can compare it with their own terminal.$SLUGfor it, and the page says where the real value is printed.5. The CLI reference page
tb extension deployplus thedeploymentscontrol commands.build/run/logs/stop, on your machine) anddeploy(server-side, ThingsBoard keeps it running). Readers mixed these two up.How it is built
Nothing new was invented; the PR follows the patterns the repo already uses.
Content is written once and served four times. The text lives in a shared include under
src/content/_includes/. Each product gets a small stub page that imports the include and passes its product:That is 5 includes and 20 stubs. A product difference is expressed inside the include —
<Banner>for the edition note,<HostCode>so{BASE_URL}becomes the right host per product — never by copying the page.Diagrams are hand-written SVG, in pairs. 7 diagrams × 2 themes = 14 files under
src/assets/schemas/. 10 UI screenshots go undersrc/assets/images/reference/extensions/.One page moved. The CLI reference went from
reference/extensions/cli-deploymenttouser-guide/cli-extensions. Four entries were added tosrc/data/redirects.ts(one per product) andpnpm generate:redirectswas run, sopublic/_redirectsandpublic/redirects.jsonare regenerated and in sync.Facts were checked against the source, not from memory. The slug suffix rule, the two private modes, the replica behaviour of
docker-compose, and the arguments thattb extension deployments statusaccepts were each read out of the ThingsBoard PE and ThingsBoard CLI code before being written down.Affected products
CE, PE, Cloud, and Cloud EU. All four get the same five pages. No other product is touched.
Related issues
Type of change
src/content/docs/**)src/content/_includes/**)src/components/**,src/styles/**)src/pages/**,src/data/**)src/data/redirects.ts)releaseskill)Checklist
pnpm checkpasses (Astro / TypeScript) — 626 files, 0 errors, 0 warningspnpm lint:eslintpassespnpm lint:slugcheckpassespnpm lint:linkcheckpasses locally — 4 523 pages, no link issuessrc/data/redirects.ts, andpnpm generate:redirectswas run (regenerated output verified to have no drift)4.4.0floor ("available from"), which is a fixed fact and must not followsrc/data/versions.tsKnown follow-up
Two UI screenshots (
extensions-list.png,extension-details.png) were taken on a self-hosted PE running an older build of the demo extension image, so the image tag in them readsjava-4.3.1.3.post1while the text showsjava-4.4.0. The captions now say the shot is from a self-hosted install and that the tag is that instance's own. Worth re-taking on a 4.4.0 instance before release.