@eventcatalog/core 4.10.13 → 4.10.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/analytics/analytics.cjs +1 -1
- package/dist/analytics/analytics.js +2 -2
- package/dist/analytics/log-build.cjs +1 -1
- package/dist/analytics/log-build.js +3 -3
- package/dist/{chunk-SSSN5FXC.js → chunk-7LWOCX4R.js} +1 -1
- package/dist/{chunk-IIECZFXN.js → chunk-A4JRWRCV.js} +1 -1
- package/dist/{chunk-JHUICVBT.js → chunk-HBVTU6ZP.js} +1 -1
- package/dist/{chunk-PADMH2RJ.js → chunk-I6HUOX4R.js} +1 -1
- package/dist/{chunk-34RMFKFB.js → chunk-Q2ATWE7N.js} +1 -1
- package/dist/constants.cjs +1 -1
- package/dist/constants.js +1 -1
- package/dist/docs/api/02-config.md +60 -6
- package/dist/docs/development/ask-your-architecture/02-eventcatalog-assistant/02-configuration.md +18 -11
- package/dist/docs/development/authentication/providers/03-setting-up-github.md +29 -0
- package/dist/docs/development/bring-your-own-documentation/custom-pages/02-adding-custom-docs.md +2 -2
- package/dist/docs/development/bring-your-own-documentation/custom-pages/03-components.md +17 -0
- package/dist/docs/development/components/07-resource-references.md +7 -1
- package/dist/docs/development/components/components/05-architecture-graph.md +65 -0
- package/dist/docs/development/components/components/{05-attachments.md → 06-attachments.md} +1 -1
- package/dist/docs/development/components/components/{06-channel-information.md → 07-channel-information.md} +1 -1
- package/dist/docs/development/components/components/{07-custom-properties.md → 08-custom-properties.md} +1 -1
- package/dist/docs/development/components/components/{08-design.md → 09-design.md} +1 -1
- package/dist/docs/development/components/components/{09-entitymap.md → 10-entitymap.md} +1 -1
- package/dist/docs/development/components/components/{10-flow.md → 11-flow.md} +1 -1
- package/dist/docs/development/components/components/{11-link.md → 12-link.md} +1 -1
- package/dist/docs/development/components/components/{12-mermaid-file-loader.md → 13-mermaid-file-loader.md} +13 -1
- package/dist/docs/development/components/components/{13-message-table.md → 14-message-table.md} +1 -1
- package/dist/docs/development/components/components/{14-nodegraph.md → 15-nodegraph.md} +1 -1
- package/dist/docs/development/components/components/{15-openapi.md → 16-openapi.md} +1 -1
- package/dist/docs/development/components/components/{16-prompt.md → 17-prompt.md} +1 -1
- package/dist/docs/development/components/components/{17-remote-schema.md → 18-remote-schema.md} +1 -1
- package/dist/docs/development/components/components/{18-resource-group-table.md → 19-resource-group-table.md} +1 -1
- package/dist/docs/development/components/components/{19-resource-link.md → 20-resource-link.md} +1 -1
- package/dist/docs/development/components/components/{20-schema.md → 21-schema.md} +1 -1
- package/dist/docs/development/components/components/{21-schema-viewer.md → 22-schema-viewer.md} +1 -1
- package/dist/docs/development/components/components/{22-steps.md → 23-steps.md} +1 -1
- package/dist/docs/development/components/components/{23-tabs.md → 24-tabs.md} +1 -1
- package/dist/docs/development/components/components/{24-tiles.md → 25-tiles.md} +1 -1
- package/dist/docs/development/components/components/{25-visibility.md → 26-visibility.md} +1 -1
- package/dist/docs/development/components/diagram-syntax/06-mermaid.md +45 -6
- package/dist/docs/development/customization/04-documentation-sidebar.md +3 -3
- package/dist/docs/development/customization/05-resource-sidebar.md +235 -0
- package/dist/docs/development/customization/09-embed-eventcatalog.md +179 -0
- package/dist/docs/development/customization/_category_.json +1 -1
- package/dist/docs/development/deployment/build-and-deploy.md +4 -0
- package/dist/docs/development/deployment/hosting-options.md +1 -1
- package/dist/docs/development/deployment/link-validation.md +105 -0
- package/dist/docs/development/developer-tools/eventcatalog-linter/00-overview.md +76 -0
- package/dist/docs/development/developer-tools/eventcatalog-linter/01-setup.md +144 -0
- package/dist/docs/development/developer-tools/eventcatalog-linter/_category_.json +10 -0
- package/dist/docs/development/developer-tools/eventcatalog-linter/how-to/01-configure-rules.md +130 -0
- package/dist/docs/development/developer-tools/eventcatalog-linter/how-to/02-run-in-ci.md +93 -0
- package/dist/docs/development/developer-tools/eventcatalog-linter/how-to/03-use-custom-frontmatter.md +81 -0
- package/dist/docs/development/developer-tools/eventcatalog-linter/how-to/04-reference-external-catalogs.md +51 -0
- package/dist/docs/development/developer-tools/eventcatalog-linter/how-to/05-fix-common-problems.md +120 -0
- package/dist/docs/development/developer-tools/eventcatalog-linter/how-to/_category_.json +12 -0
- package/dist/docs/development/developer-tools/eventcatalog-linter/reference/01-cli.md +109 -0
- package/dist/docs/development/developer-tools/eventcatalog-linter/reference/02-configuration.md +120 -0
- package/dist/docs/development/developer-tools/eventcatalog-linter/reference/03-rules.md +287 -0
- package/dist/docs/development/developer-tools/eventcatalog-linter/reference/04-versions.md +77 -0
- package/dist/docs/development/developer-tools/eventcatalog-linter/reference/05-supported-resources.md +75 -0
- package/dist/docs/development/developer-tools/eventcatalog-linter/reference/_category_.json +12 -0
- package/dist/docs/development/guides/97-architecture-graph.md +78 -0
- package/dist/docs/development/guides/domains/02-create-domain.md +1 -1
- package/dist/docs/development/guides/domains/03-ownership-and-language/02-adding-ubiquitous-language.md +29 -0
- package/dist/docs/development/guides/domains/09-reference.md +10 -0
- package/dist/docs/development/guides/resources/messages/04-message-channels/02-adding-channels.md +2 -2
- package/dist/docs/development/guides/resources/messages/04-message-channels/04-adding-messages-to-services.md +8 -0
- package/dist/docs/development/guides/resources/schemas/03-add-specifications-to-services/01-add-openapi-specifications.md +2 -2
- package/dist/docs/development/guides/resources/schemas/03-add-specifications-to-services/02-add-asyncapi-specifications.md +3 -3
- package/dist/docs/development/guides/systems/05-system-context-maps.md +2 -0
- package/dist/docs/development/license-keys/license-validation.md +7 -3
- package/dist/docs/development/license-keys/overview.md +7 -3
- package/dist/docs/development/upgrading/upgrading.md +3 -3
- package/dist/docs/development/upgrading/v2.md +3 -3
- package/dist/docs/federation/00-overview.md +158 -0
- package/dist/docs/federation/01-first-federation.md +199 -0
- package/dist/docs/federation/_category_.json +12 -0
- package/dist/docs/federation/explanation/_category_.json +12 -0
- package/dist/docs/federation/explanation/how-it-works.md +129 -0
- package/dist/docs/federation/explanation/lockfile-and-cache.md +134 -0
- package/dist/docs/federation/explanation/mvp-status-and-feedback.md +86 -0
- package/dist/docs/federation/explanation/ownership-and-references.md +134 -0
- package/dist/docs/federation/how-to/_category_.json +12 -0
- package/dist/docs/federation/how-to/configure-github-sources.md +156 -0
- package/dist/docs/federation/how-to/configure-validation-rules.md +127 -0
- package/dist/docs/federation/how-to/run-in-ci.md +138 -0
- package/dist/docs/federation/how-to/share-assets-and-components.md +125 -0
- package/dist/docs/federation/how-to/use-local-sources.md +138 -0
- package/dist/docs/{plugins/eventcatalog-federation → federation/legacy-federation}/00-introduction.md +11 -2
- package/dist/docs/{plugins/eventcatalog-federation → federation/legacy-federation}/01-installation.md +11 -3
- package/dist/docs/{plugins/eventcatalog-federation → federation/legacy-federation}/02-plugin-configuration.md +11 -2
- package/dist/docs/{plugins/eventcatalog-federation → federation/legacy-federation}/03-examples.md +11 -1
- package/dist/docs/{plugins/eventcatalog-federation → federation/legacy-federation}/04-configuration.md +11 -1
- package/dist/docs/{plugins/eventcatalog-federation → federation/legacy-federation}/05-setup-team-catalog.md +11 -2
- package/dist/docs/federation/legacy-federation/_category_.json +12 -0
- package/dist/docs/federation/reference/_category_.json +12 -0
- package/dist/docs/federation/reference/cli.md +122 -0
- package/dist/docs/federation/reference/configuration.md +192 -0
- package/dist/docs/federation/reference/diagnostic-rules.md +173 -0
- package/dist/docs/federation/reference/generated-output.md +118 -0
- package/dist/docs/federation/reference/supported-content.md +86 -0
- package/dist/docs/federation/reference/troubleshooting.md +208 -0
- package/dist/docs/plugins/01-intro.md +3 -3
- package/dist/docs/plugins/03-all-plugins.md +2 -2
- package/dist/docs/plugins/asyncapi/00-intro.md +4 -4
- package/dist/docs/plugins/asyncapi/02-plugin-configuration.md +4 -4
- package/dist/docs/plugins/backstage/00-overview.md +53 -0
- package/dist/docs/plugins/backstage/01-get-started.md +95 -0
- package/dist/docs/plugins/backstage/02-embed-entity-tabs.md +109 -0
- package/dist/docs/plugins/backstage/03-add-overview-cards.md +79 -0
- package/dist/docs/plugins/backstage/04-control-theme-and-size.md +54 -0
- package/dist/docs/plugins/backstage/05-migrate-to-annotations.md +49 -0
- package/dist/docs/plugins/backstage/06-configuration.md +85 -0
- package/dist/docs/plugins/backstage/07-components.md +129 -0
- package/dist/docs/plugins/backstage/08-how-embeds-work.md +52 -0
- package/dist/docs/plugins/backstage/_category_.json +4 -3
- package/dist/docs/plugins/eventbridge/00-intro.md +5 -5
- package/dist/docs/plugins/eventbridge/03-api.md +3 -3
- package/dist/docs/plugins/graphql/00-intro.md +2 -2
- package/dist/docs/plugins/graphql/02-plugin-configuration.md +2 -2
- package/dist/docs/plugins/hookdeck/01-intro.md +1 -1
- package/dist/docs/plugins/openapi/00-intro.md +1 -1
- package/dist/eventcatalog.cjs +1 -1
- package/dist/eventcatalog.js +5 -5
- package/dist/generate.cjs +1 -1
- package/dist/generate.js +3 -3
- package/dist/utils/cli-logger.cjs +1 -1
- package/dist/utils/cli-logger.js +2 -2
- package/eventcatalog/src/components/SchemaExplorer/AvroSchemaViewer.tsx +21 -19
- package/eventcatalog/src/components/SchemaExplorer/JSONSchemaViewer.test.tsx +114 -0
- package/eventcatalog/src/components/SchemaExplorer/JSONSchemaViewer.tsx +107 -86
- package/eventcatalog/src/components/SchemaExplorer/ProtobufSchemaViewer.test.tsx +91 -0
- package/eventcatalog/src/components/SchemaExplorer/ProtobufSchemaViewer.tsx +115 -33
- package/eventcatalog/src/components/SchemaExplorer/SchemaViewerHover.test.tsx +33 -0
- package/eventcatalog/src/components/SchemaExplorer/protobuf-validation.test.ts +84 -0
- package/eventcatalog/src/components/SchemaExplorer/protobuf-validation.ts +149 -0
- package/eventcatalog/src/utils/collections/glob-loader.ts +2 -2
- package/eventcatalog/src/utils/protobuf-schema.ts +211 -16
- package/package.json +8 -8
- package/dist/docs/cli/channels.md +0 -180
- package/dist/docs/cli/commands.md +0 -183
- package/dist/docs/cli/custom-docs.md +0 -78
- package/dist/docs/cli/data-products.md +0 -177
- package/dist/docs/cli/data-stores.md +0 -166
- package/dist/docs/cli/diagrams.md +0 -147
- package/dist/docs/cli/domains.md +0 -280
- package/dist/docs/cli/entities.md +0 -138
- package/dist/docs/cli/events.md +0 -186
- package/dist/docs/cli/export.md +0 -27
- package/dist/docs/cli/governance.md +0 -24
- package/dist/docs/cli/messages.md +0 -69
- package/dist/docs/cli/queries.md +0 -183
- package/dist/docs/cli/services.md +0 -266
- package/dist/docs/cli/snapshots.md +0 -44
- package/dist/docs/cli/teams.md +0 -75
- package/dist/docs/cli/users.md +0 -75
- package/dist/docs/cli/utilities.md +0 -43
- package/dist/docs/development/developer-tools/eventcatalog-linter.md +0 -732
- package/dist/docs/plugins/backstage/00-intro.md +0 -67
- package/dist/docs/plugins/backstage/01-installation.md +0 -242
- package/dist/docs/plugins/backstage/02-api.md +0 -51
- package/dist/docs/plugins/backstage/03-examples.md +0 -12
- package/dist/docs/plugins/eventcatalog-federation/_category_.json +0 -11
|
@@ -0,0 +1,208 @@
|
|
|
1
|
+
---
|
|
2
|
+
sidebar_position: 6
|
|
3
|
+
sidebar_label: Troubleshooting
|
|
4
|
+
title: Troubleshooting EventCatalog Federation
|
|
5
|
+
description: Fix common source, ownership, relationship, asset, cache, and generated-output problems.
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
import EventCatalogEnterprise from '@site/src/components/MDX/EventCatalogEnterprise';
|
|
9
|
+
|
|
10
|
+
<EventCatalogEnterprise />
|
|
11
|
+
|
|
12
|
+
Run with verbose diagnostics before investigating a warning:
|
|
13
|
+
|
|
14
|
+
```bash
|
|
15
|
+
npx eventcatalog federate --verbose
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
Errors always include details. Verbose mode adds the attributes for warnings.
|
|
19
|
+
|
|
20
|
+
## Federation is not enabled
|
|
21
|
+
|
|
22
|
+
If the command reports that Federation is an Enterprise feature:
|
|
23
|
+
|
|
24
|
+
- Confirm the Enterprise `license.jwt` file is in the central catalog root
|
|
25
|
+
- If the file is stored elsewhere, confirm `EC_LICENSE` points to it
|
|
26
|
+
- Confirm the license has not expired
|
|
27
|
+
- Email [hello@eventcatalog.dev](mailto:hello@eventcatalog.dev?subject=EventCatalog%20Federation%20Trial) to request or replace an offline trial key
|
|
28
|
+
- Review [offline license validation](/docs/development/license-keys/license-validation#offline-validation)
|
|
29
|
+
|
|
30
|
+
## No sources are configured
|
|
31
|
+
|
|
32
|
+
Add at least one entry to `federation.sources`:
|
|
33
|
+
|
|
34
|
+
```js title="eventcatalog.config.js"
|
|
35
|
+
export default {
|
|
36
|
+
federation: {
|
|
37
|
+
sources: [
|
|
38
|
+
{
|
|
39
|
+
id: 'acme/payments',
|
|
40
|
+
source: 'github:acme/payments-catalog',
|
|
41
|
+
},
|
|
42
|
+
],
|
|
43
|
+
},
|
|
44
|
+
};
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
If previous Federation output exists, an empty source list intentionally removes it and its managed public files.
|
|
48
|
+
|
|
49
|
+
## A source ID is configured more than once
|
|
50
|
+
|
|
51
|
+
Every source entry needs a unique stable `id`. Change or remove the duplicate configuration entry.
|
|
52
|
+
|
|
53
|
+
This configuration error is different from `federation/duplicate-source`, which means several catalogs own the same resource ID.
|
|
54
|
+
|
|
55
|
+
## GitHub source errors
|
|
56
|
+
|
|
57
|
+
### Unsupported GitHub locator
|
|
58
|
+
|
|
59
|
+
Use:
|
|
60
|
+
|
|
61
|
+
```text
|
|
62
|
+
github:owner/repository
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
Do not use a full `https://github.com/...` URL.
|
|
66
|
+
|
|
67
|
+
### Repository cannot be fetched
|
|
68
|
+
|
|
69
|
+
Check:
|
|
70
|
+
|
|
71
|
+
- The owner and repository name
|
|
72
|
+
- The configured `ref`
|
|
73
|
+
- Network access to GitHub
|
|
74
|
+
- Git is installed when the source does not publish an index
|
|
75
|
+
- `EVENTCATALOG_GITHUB_TOKEN` or `GITHUB_TOKEN` has repository contents read access
|
|
76
|
+
|
|
77
|
+
### Published index source does not match
|
|
78
|
+
|
|
79
|
+
The `source` value inside `catalog.index.json` must equal the configured source `id`.
|
|
80
|
+
|
|
81
|
+
Either correct the published index or configure the matching stable ID.
|
|
82
|
+
|
|
83
|
+
### Catalog path escapes the source
|
|
84
|
+
|
|
85
|
+
`path` must be a safe relative path inside the selected repository. Remove absolute paths, `..` segments, or backslashes.
|
|
86
|
+
|
|
87
|
+
## Filesystem source errors
|
|
88
|
+
|
|
89
|
+
### Source does not exist
|
|
90
|
+
|
|
91
|
+
`file:` paths are resolved from the central catalog directory, not from the terminal's parent directory.
|
|
92
|
+
|
|
93
|
+
For sibling catalogs:
|
|
94
|
+
|
|
95
|
+
```js
|
|
96
|
+
{
|
|
97
|
+
id: 'acme/payments',
|
|
98
|
+
source: 'file:../payments-catalog',
|
|
99
|
+
}
|
|
100
|
+
```
|
|
101
|
+
|
|
102
|
+
Confirm that the resolved directory exists and contains an EventCatalog project.
|
|
103
|
+
|
|
104
|
+
### Filesystem source does not support `ref`
|
|
105
|
+
|
|
106
|
+
Remove `ref` from the source. Filesystem sources always read the current local files.
|
|
107
|
+
|
|
108
|
+
### Source or artifact escapes its allowed directory
|
|
109
|
+
|
|
110
|
+
Federation rejects paths and symbolic links that resolve outside the selected filesystem source. Keep the catalog and its referenced files within the source root.
|
|
111
|
+
|
|
112
|
+
## Ownership and type errors
|
|
113
|
+
|
|
114
|
+
### `federation/duplicate-source`
|
|
115
|
+
|
|
116
|
+
Several catalogs own the same resource ID. Choose one owner and remove copied or placeholder definitions from the other catalogs.
|
|
117
|
+
|
|
118
|
+
### `federation/type-collision`
|
|
119
|
+
|
|
120
|
+
The same ID is documented with different resource types. Correct the type or assign distinct IDs.
|
|
121
|
+
|
|
122
|
+
### `federation/pointer-type-mismatch`
|
|
123
|
+
|
|
124
|
+
A relationship expects one type but resolves to another. Correct the relationship pointer or its target ID.
|
|
125
|
+
|
|
126
|
+
Use the [diagnostic rule reference](/docs/federation/reference/diagnostic-rules) to interpret the printed attributes.
|
|
127
|
+
|
|
128
|
+
## Relationship warnings
|
|
129
|
+
|
|
130
|
+
### Referenced resource does not exist
|
|
131
|
+
|
|
132
|
+
For `federation/missing-resource`:
|
|
133
|
+
|
|
134
|
+
- Check the referenced ID for a typo
|
|
135
|
+
- Add the owning catalog to `federation.sources`
|
|
136
|
+
- Confirm the owner documents the resource
|
|
137
|
+
- Keep the warning if the external reference is deliberate
|
|
138
|
+
|
|
139
|
+
### Referenced resource version does not exist
|
|
140
|
+
|
|
141
|
+
For `federation/unresolved-version`:
|
|
142
|
+
|
|
143
|
+
- Compare `requested version` with `available versions`
|
|
144
|
+
- Correct the exact version or semantic range
|
|
145
|
+
- Publish the required version in the owning catalog
|
|
146
|
+
|
|
147
|
+
## Public assets or components are not correct
|
|
148
|
+
|
|
149
|
+
For `federation/asset-collision`, run with `--verbose` to see the source order and winner.
|
|
150
|
+
|
|
151
|
+
Then:
|
|
152
|
+
|
|
153
|
+
- Namespace remote asset paths by team or domain
|
|
154
|
+
- Make intentionally shared files identical
|
|
155
|
+
- Reorder sources only when last-source-wins is deliberate
|
|
156
|
+
- Check whether the central catalog owns the public path
|
|
157
|
+
- Check whether a local component overrides the federated component
|
|
158
|
+
|
|
159
|
+
If a custom component imports an npm package, install that dependency in the central catalog.
|
|
160
|
+
|
|
161
|
+
Top-level source `snippets/` are not currently federated. Move required content into the page, provide it centrally, or avoid the remote snippet import.
|
|
162
|
+
|
|
163
|
+
## Content hash mismatch
|
|
164
|
+
|
|
165
|
+
Federation fetched bytes that did not match the hash recorded by the source index.
|
|
166
|
+
|
|
167
|
+
Rerun the command first. If the error remains:
|
|
168
|
+
|
|
169
|
+
- Regenerate or remove a stale published `catalog.index.json`
|
|
170
|
+
- Confirm the source content still exists at the indexed commit
|
|
171
|
+
- Check whether content was changed without updating the index
|
|
172
|
+
|
|
173
|
+
Federation does not install content that fails integrity validation.
|
|
174
|
+
|
|
175
|
+
## The lockfile cannot be read
|
|
176
|
+
|
|
177
|
+
Check that `eventcatalog.lock` contains valid JSON and was not partially edited.
|
|
178
|
+
|
|
179
|
+
If you do not need its audit or managed public-file state, move the malformed file aside and rerun Federation. Review public assets carefully because the new run will not know which existing files were managed by the unreadable lockfile.
|
|
180
|
+
|
|
181
|
+
## Federated content looks stale
|
|
182
|
+
|
|
183
|
+
Run Federation again before starting or building EventCatalog:
|
|
184
|
+
|
|
185
|
+
```bash
|
|
186
|
+
npx eventcatalog federate
|
|
187
|
+
npm run dev
|
|
188
|
+
```
|
|
189
|
+
|
|
190
|
+
For a local source, remember there is no watcher integration yet.
|
|
191
|
+
|
|
192
|
+
Use `--no-cache` when investigating cache behavior:
|
|
193
|
+
|
|
194
|
+
```bash
|
|
195
|
+
npx eventcatalog federate --no-cache
|
|
196
|
+
```
|
|
197
|
+
|
|
198
|
+
The cache is content-addressed and verified, so changing source content normally produces a different cache key without this option.
|
|
199
|
+
|
|
200
|
+
## A failed run left the previous content visible
|
|
201
|
+
|
|
202
|
+
This is expected. Federation preserves or restores the previous successful output when validation or a normal output update fails.
|
|
203
|
+
|
|
204
|
+
Fix the reported problem and rerun the command. New output and a new lockfile are installed only after Federation succeeds.
|
|
205
|
+
|
|
206
|
+
## Get help
|
|
207
|
+
|
|
208
|
+
Share the command output, relevant source configuration with secrets removed, and the expected ownership model in the [EventCatalog Discord](https://eventcatalog.dev/discord) or [open an issue](https://github.com/event-catalog/eventcatalog/issues).
|
|
@@ -29,11 +29,11 @@ These plugins are maintained by the EventCatalog team and are updated regularly,
|
|
|
29
29
|
- [OpenAPI Plugin](/docs/plugins/openapi/intro) - Generate documentation from your OpenAPI files
|
|
30
30
|
- [GraphQL Plugin](/docs/plugins/graphql/intro) - Generate documentation from your GraphQL files
|
|
31
31
|
- [Github Plugin](/docs/plugins/github/intro) - Sync your schemas from GitHub to EventCatalog
|
|
32
|
-
- [Backstage Plugin](/docs/plugins/backstage/
|
|
32
|
+
- [Backstage Plugin](/docs/plugins/backstage/overview) - Embed EventCatalog documentation and visualizations in Backstage
|
|
33
33
|
- [Amazon EventBridge](/docs/plugins/eventbridge/intro) - Sync Amazon EventBridge schemas to EventCatalog
|
|
34
34
|
- [Amazon API Gateway](/docs/plugins/amazon-apigateway/intro) - Generate documentation from your Amazon API Gateway
|
|
35
35
|
- [Confluent Schema Registry](/docs/plugins/confluent-schema-registry/intro) - Sync your schemas from Confluent Schema Registry to EventCatalog
|
|
36
|
-
- [EventCatalog Federation](/docs/
|
|
36
|
+
- [EventCatalog Federation](/docs/federation/overview) - Merge multiple EventCatalog instances into a single catalog.
|
|
37
37
|
|
|
38
38
|
#### Community plugins
|
|
39
39
|
|
|
@@ -46,4 +46,4 @@ EventCatalog can integrate with anything that has an API.
|
|
|
46
46
|
|
|
47
47
|
We offer support and services to build custom integrations for your EventCatalog.
|
|
48
48
|
|
|
49
|
-
If you would like to explore custom integrations and have us build your integrate for you please contact us at `hello@eventcatalog.dev`.
|
|
49
|
+
If you would like to explore custom integrations and have us build your integrate for you please contact us at `hello@eventcatalog.dev`.
|
|
@@ -19,8 +19,8 @@ Automate and sync your data from a wide range of systems to EventCatalog.
|
|
|
19
19
|
| [Apicurio Registry](/docs/plugins/apicurio/intro) | Import schemas and specifications from Apicurio Registry into EventCatalog |
|
|
20
20
|
| [Azure Schema Registry](/docs/plugins/azure-schema-registry/intro) | Import schemas from Azure Schema Registry into EventCatalog |
|
|
21
21
|
| [Github Plugin](/docs/plugins/github/intro) | Sync your schemas from GitHub to EventCatalog |
|
|
22
|
-
| [Backstage Plugin](/docs/plugins/backstage/
|
|
22
|
+
| [Backstage Plugin](/docs/plugins/backstage/overview) | Embed EventCatalog documentation and visualizations in Backstage |
|
|
23
23
|
| [Amazon EventBridge](/docs/plugins/eventbridge/intro) | Sync Amazon EventBridge schemas to EventCatalog |
|
|
24
24
|
| [Amazon API Gateway](/docs/plugins/amazon-apigateway/intro) | Generate documentation from your Amazon API Gateway |
|
|
25
25
|
| [Confluent Schema Registry](/docs/plugins/confluent-schema-registry/intro) | Sync your schemas from Confluent Schema Registry to EventCatalog |
|
|
26
|
-
| [EventCatalog Federation](/docs/
|
|
26
|
+
| [EventCatalog Federation](/docs/federation/overview) | Merge multiple EventCatalog instances into a single catalog. |
|
|
@@ -38,10 +38,10 @@ The EventCatalog AsyncAPI plugin can provide you with many features:
|
|
|
38
38
|
- ⭐️ Generate domains, services and messages into your catalog from your AsyncAPI specification files
|
|
39
39
|
- ⭐️ [Automate your EventCatalog and fetch AsyncAPI files by URL](/docs/plugins/asyncapi/features#fetch-asyncapi-files-by-url)
|
|
40
40
|
- ⭐️ [Map commands, queries and events from your OpenAPI file using custom extensions](/docs/plugins/asyncapi/features#mapping-messages-events-commands-or-queries)
|
|
41
|
-
- ⭐️ [Automatically version your changes in EventCatalog in sync with your AsyncAPI versions](#automatic-versioning)
|
|
42
|
-
- ⭐️ [Allow you to write and persist custom markdown between changes](#persist-markdown)
|
|
43
|
-
- ⭐️ [Display your message schemas in the catalog](#downloading-schemas)
|
|
44
|
-
- ⭐️ [Fetch AsyncAPI files from any URL](#fetch-asyncapi-files-by-url)
|
|
41
|
+
- ⭐️ [Automatically version your changes in EventCatalog in sync with your AsyncAPI versions](/docs/plugins/asyncapi/features#automatic-versioning)
|
|
42
|
+
- ⭐️ [Allow you to write and persist custom markdown between changes](/docs/plugins/asyncapi/features#persist-markdown)
|
|
43
|
+
- ⭐️ [Display your message schemas in the catalog](/docs/plugins/asyncapi/features#downloading-schemas)
|
|
44
|
+
- ⭐️ [Fetch AsyncAPI files from any URL](/docs/plugins/asyncapi/features#fetch-asyncapi-files-by-url)
|
|
45
45
|
- ⭐️ Ability to download your message schemas and AsyncAPI files (also versioned)
|
|
46
46
|
- ⭐️ Ability to draft services and endpoints in EventCatalog from your AsyncAPI files
|
|
47
47
|
- ⭐️ and more....
|
|
@@ -53,13 +53,13 @@ Each service in the `services` array requires the following properties:
|
|
|
53
53
|
| `domain.generateMarkdown` | function | - | Function to override the default markdown generation for the domain. See [Markdown templates](#markdown-templates) for more information. |
|
|
54
54
|
| `messages.generateMarkdown` | function | - | Function to override the default markdown generation for the message. See [Markdown templates](#markdown-templates) for more information. |
|
|
55
55
|
| `messages.id` | object | - | Configure the id of the messages that are generated (for example, set a prefix to all messages that are generated) _(Added in v4.5.1)_ [(Read more)](/docs/plugins/asyncapi/features#adding-prefix-to-all-messages) |
|
|
56
|
-
| `messages.id.prefix` | string | - | A prefix value for the message that is generated. For example a message with the id `orderPlaced` with a configured prefix of `hello-` will be `hello-orderPlaced`. _(Added in v4.5.1)_ [(Read more)](/docs/plugins/asyncapi/
|
|
57
|
-
| `messages.id.separator` | string | `-` | The separator to use between the prefix and the message id. _(Added in v4.5.1)_ [(Read more)](/docs/plugins/asyncapi/
|
|
58
|
-
| `messages.id.prefixWithServiceId` | boolean | | If true, the service id will be added to the id of the messages that are generated. For example a message with the id `orderPlaced` and the service id `orders-service` will be `orders-service-orderPlaced`. _(Added in v4.5.1)_ [(Read more)](/docs/plugins/asyncapi/
|
|
56
|
+
| `messages.id.prefix` | string | - | A prefix value for the message that is generated. For example a message with the id `orderPlaced` with a configured prefix of `hello-` will be `hello-orderPlaced`. _(Added in v4.5.1)_ [(Read more)](/docs/plugins/asyncapi/features#adding-prefix-to-all-messages) |
|
|
57
|
+
| `messages.id.separator` | string | `-` | The separator to use between the prefix and the message id. _(Added in v4.5.1)_ [(Read more)](/docs/plugins/asyncapi/features#adding-prefix-to-all-messages) |
|
|
58
|
+
| `messages.id.prefixWithServiceId` | boolean | | If true, the service id will be added to the id of the messages that are generated. For example a message with the id `orderPlaced` and the service id `orders-service` will be `orders-service-orderPlaced`. _(Added in v4.5.1)_ [(Read more)](/docs/plugins/asyncapi/features#adding-prefix-to-all-messages) |
|
|
59
59
|
| `messages.id.lowerCase` | boolean | false | If true, the message id will be stored in lowercase and the folder will also be lowercased. (e.g `/events/orderplaced/index.mdx) _(Added in v5.0.0)_ |
|
|
60
60
|
| `preserveExistingMessages` | boolean | `true` | Preserve existing message Markdown when the generator runs again. Set to `false` to replace existing Markdown with content generated from the AsyncAPI specification and `messages.generateMarkdown` template. Referenced and external messages are never overwritten. |
|
|
61
61
|
| `saveParsedSpecFile` | boolean | `false` | Parse and save expanded AsyncAPI spec (helpful for files with $refs) |
|
|
62
|
-
| `parseSchemas` | boolean | `true` | If you choose to parse your specification file using the [saveParsedSpecFile](#
|
|
62
|
+
| `parseSchemas` | boolean | `true` | If you choose to parse your specification file using the [saveParsedSpecFile](#optional-configuration-options) field, you can also opt in or out to have your ,message schemas parsed using the `parseSchemas` field. By default message schemas are parsed, if you want to keep your original schemas you have to set `parseSchemas` to false. | | `parseChannels` | boolean | `false` | Parse and save channels. If you set to true the AsyncAPI channels will also be documented in the catalog. |
|
|
63
63
|
| `parseChannels` | boolean | `false` | When setting the value to true the generator will parse and write channels to your EventCatalog. |
|
|
64
64
|
| `writeFilesToRoot` | boolean | `false` | Write AsyncAPI messages to root instead of service folder. By default all domains, services and messages will be grouped in the folder directory structure. |
|
|
65
65
|
| `saveParsedSpecFile` | boolean | `true` | By default your AsyncAPI file will render in your catalog as you define it. If you are using $refs, or having issues seeing your AsyncAPI file in your catalog, then you can set this value to true. `saveParsedSpecFile` is false by default. |
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
---
|
|
2
|
+
sidebar_position: 1
|
|
3
|
+
sidebar_label: Overview
|
|
4
|
+
title: EventCatalog for Backstage
|
|
5
|
+
description: Add EventCatalog documentation, diagrams, schemas, messages, and flows to Backstage entity pages.
|
|
6
|
+
keywords:
|
|
7
|
+
- backstage
|
|
8
|
+
- developer portal
|
|
9
|
+
- integration
|
|
10
|
+
---
|
|
11
|
+
|
|
12
|
+
import PluginLicense from '@site/src/components/MDX/PluginLicense';
|
|
13
|
+
|
|
14
|
+
<PluginLicense url="#licensing" />
|
|
15
|
+
|
|
16
|
+
The EventCatalog Backstage plugin embeds EventCatalog views in Backstage entity pages. Developers can explore architecture documentation without leaving the software catalog they use for ownership, APIs, dependencies, and operations.
|
|
17
|
+
|
|
18
|
+

|
|
19
|
+
|
|
20
|
+
## Choose where to start
|
|
21
|
+
|
|
22
|
+
- New to the plugin? Follow [Embed EventCatalog in your first Backstage entity](/docs/plugins/backstage/get-started).
|
|
23
|
+
- Adding a dedicated entity tab? Use [Embed EventCatalog as entity tabs](/docs/plugins/backstage/embed-entity-tabs).
|
|
24
|
+
- Adding content to an existing overview? Use [Add EventCatalog cards to an overview page](/docs/plugins/backstage/add-overview-cards).
|
|
25
|
+
- Need exact props or supported components? See the [component reference](/docs/plugins/backstage/components).
|
|
26
|
+
- Upgrading from the legacy resource mapping? Follow [Migrate to entity annotations](/docs/plugins/backstage/migrate-to-annotations).
|
|
27
|
+
|
|
28
|
+
## Supported views
|
|
29
|
+
|
|
30
|
+
You can embed:
|
|
31
|
+
|
|
32
|
+
- resource documentation
|
|
33
|
+
- resource visualizers
|
|
34
|
+
- message discovery tables
|
|
35
|
+
- entity maps
|
|
36
|
+
- the schema explorer
|
|
37
|
+
- the Architecture Graph, focused on a resource at depth 1, 2, or 3
|
|
38
|
+
- the System Context Map overview or a specific system and version
|
|
39
|
+
- a flow visualizer for a specific flow and version
|
|
40
|
+
|
|
41
|
+
Every page and card accepts `theme="light"` or `theme="dark"`. If you omit `theme`, EventCatalog uses the visitor's saved EventCatalog theme.
|
|
42
|
+
|
|
43
|
+
## How the integration fits together
|
|
44
|
+
|
|
45
|
+
The plugin reads the EventCatalog base URL from Backstage configuration and normally reads the EventCatalog resource identity from annotations on the current Backstage entity. It then renders the selected EventCatalog view in an iframe with embed mode enabled.
|
|
46
|
+
|
|
47
|
+
Read [How EventCatalog embeds work](/docs/plugins/backstage/how-embeds-work) for the mapping, rendering, and sizing model.
|
|
48
|
+
|
|
49
|
+
## Licensing
|
|
50
|
+
|
|
51
|
+
The plugin requires an EventCatalog Scale license for commercial use. You can start a 30-day trial in [EventCatalog Cloud](https://eventcatalog.cloud) and follow [Getting a license key for integrations](/docs/development/license-keys/integrations).
|
|
52
|
+
|
|
53
|
+
For license terms, see the [plugin repository](https://github.com/event-catalog/backstage-plugin-eventcatalog).
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
---
|
|
2
|
+
sidebar_position: 2
|
|
3
|
+
sidebar_label: Get started
|
|
4
|
+
title: Embed EventCatalog in your first Backstage entity
|
|
5
|
+
description: Install the EventCatalog Backstage plugin and add resource documentation to an entity page.
|
|
6
|
+
keywords:
|
|
7
|
+
- backstage
|
|
8
|
+
- tutorial
|
|
9
|
+
- installation
|
|
10
|
+
---
|
|
11
|
+
|
|
12
|
+
In this tutorial, you will connect a Backstage app to an EventCatalog instance and add an EventCatalog documentation tab to a service entity.
|
|
13
|
+
|
|
14
|
+
You will need:
|
|
15
|
+
|
|
16
|
+
- a Backstage app with a software catalog entity page
|
|
17
|
+
- an EventCatalog instance that the user's browser can reach
|
|
18
|
+
- an EventCatalog Scale license for commercial use
|
|
19
|
+
|
|
20
|
+
## 1. Enable the integration in EventCatalog
|
|
21
|
+
|
|
22
|
+
Add your Scale license key to the `.env` file in the EventCatalog project:
|
|
23
|
+
|
|
24
|
+
```bash title=".env"
|
|
25
|
+
EVENTCATALOG_SCALE_LICENSE_KEY=your-scale-license-key
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
Build and deploy EventCatalog with this environment variable. For license setup and legacy keys, see [Getting a license key for integrations](/docs/development/license-keys/integrations).
|
|
29
|
+
|
|
30
|
+
## 2. Install the Backstage plugin
|
|
31
|
+
|
|
32
|
+
From the root of your Backstage app, install the frontend plugin:
|
|
33
|
+
|
|
34
|
+
```bash
|
|
35
|
+
yarn add @eventcatalog/backstage-plugin-eventcatalog
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
## 3. Configure the EventCatalog URL
|
|
39
|
+
|
|
40
|
+
Add the public base URL of your EventCatalog instance to `app-config.yaml`:
|
|
41
|
+
|
|
42
|
+
```yaml title="app-config.yaml"
|
|
43
|
+
eventcatalog:
|
|
44
|
+
URL: https://demo.eventcatalog.dev
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
Do not add a trailing view path such as `/docs` or `/visualiser`. The plugin builds each embed URL from this base URL.
|
|
48
|
+
|
|
49
|
+
## 4. Map a Backstage entity
|
|
50
|
+
|
|
51
|
+
Add EventCatalog annotations to a Backstage catalog entity. This example maps a Backstage component to version `1.0.0` of the `order-service` service in EventCatalog:
|
|
52
|
+
|
|
53
|
+
```yaml title="catalog-info.yaml"
|
|
54
|
+
apiVersion: backstage.io/v1alpha1
|
|
55
|
+
kind: Component
|
|
56
|
+
metadata:
|
|
57
|
+
name: order-service
|
|
58
|
+
description: Handles customer orders
|
|
59
|
+
annotations:
|
|
60
|
+
eventcatalog.dev/id: order-service
|
|
61
|
+
eventcatalog.dev/version: 1.0.0
|
|
62
|
+
eventcatalog.dev/collection: services
|
|
63
|
+
spec:
|
|
64
|
+
type: service
|
|
65
|
+
lifecycle: production
|
|
66
|
+
owner: team-orders
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
The annotation values must match the resource ID, version, and collection in EventCatalog.
|
|
70
|
+
|
|
71
|
+
## 5. Add an EventCatalog tab
|
|
72
|
+
|
|
73
|
+
Open the file that defines your catalog entity page, commonly `packages/app/src/components/catalog/EntityPage.tsx`.
|
|
74
|
+
|
|
75
|
+
Import the page component:
|
|
76
|
+
|
|
77
|
+
```tsx
|
|
78
|
+
import { EventCatalogDocumentationEntityPage } from '@eventcatalog/backstage-plugin-eventcatalog';
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
Add a route inside the `EntityLayout` used for your service entities:
|
|
82
|
+
|
|
83
|
+
```tsx
|
|
84
|
+
<EntityLayout.Route path="/eventcatalog-docs" title="EventCatalog: Docs">
|
|
85
|
+
<EventCatalogDocumentationEntityPage page="docs" />
|
|
86
|
+
</EntityLayout.Route>
|
|
87
|
+
```
|
|
88
|
+
|
|
89
|
+
## 6. Check the result
|
|
90
|
+
|
|
91
|
+
Start Backstage and open the mapped service. Select **EventCatalog: Docs**.
|
|
92
|
+
|
|
93
|
+
You should see the `order-service` documentation from EventCatalog fill the tab. If you see a mapping message instead, check that `eventcatalog.dev/id` is present and that the entity has been re-ingested by Backstage.
|
|
94
|
+
|
|
95
|
+
You now have a working EventCatalog embed. Next, [add more entity tabs](/docs/plugins/backstage/embed-entity-tabs) or [place visualizations on the overview page](/docs/plugins/backstage/add-overview-cards).
|
|
@@ -0,0 +1,109 @@
|
|
|
1
|
+
---
|
|
2
|
+
sidebar_position: 3
|
|
3
|
+
sidebar_label: Embed entity tabs
|
|
4
|
+
title: Embed EventCatalog as entity tabs
|
|
5
|
+
description: Add documentation, message, schema, map, graph, and flow tabs to Backstage entity pages.
|
|
6
|
+
keywords:
|
|
7
|
+
- backstage
|
|
8
|
+
- entity tabs
|
|
9
|
+
- entity layout
|
|
10
|
+
---
|
|
11
|
+
|
|
12
|
+
Use full-page components inside `EntityLayout.Route` when you want an EventCatalog view to have its own Backstage entity tab.
|
|
13
|
+
|
|
14
|
+
## Import the components
|
|
15
|
+
|
|
16
|
+
Import the general-purpose page component and any dedicated visualization components you need:
|
|
17
|
+
|
|
18
|
+
```tsx
|
|
19
|
+
import {
|
|
20
|
+
EventCatalogArchitectureGraphEntityPage,
|
|
21
|
+
EventCatalogDocumentationEntityPage,
|
|
22
|
+
EventCatalogFlowEntityPage,
|
|
23
|
+
EventCatalogSystemContextMapEntityPage,
|
|
24
|
+
} from '@eventcatalog/backstage-plugin-eventcatalog';
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
## Add resource views
|
|
28
|
+
|
|
29
|
+
The documentation, visualizer, discovery table, entity map, and schema explorer use `EventCatalogDocumentationEntityPage`:
|
|
30
|
+
|
|
31
|
+
```tsx
|
|
32
|
+
<EntityLayout.Route path="/eventcatalog-docs" title="EventCatalog: Docs">
|
|
33
|
+
<EventCatalogDocumentationEntityPage page="docs" />
|
|
34
|
+
</EntityLayout.Route>
|
|
35
|
+
|
|
36
|
+
<EntityLayout.Route path="/eventcatalog-visualiser" title="EventCatalog: Visualiser">
|
|
37
|
+
<EventCatalogDocumentationEntityPage page="visualiser" />
|
|
38
|
+
</EntityLayout.Route>
|
|
39
|
+
|
|
40
|
+
<EntityLayout.Route path="/eventcatalog-messages" title="EventCatalog: Messages">
|
|
41
|
+
<EventCatalogDocumentationEntityPage page="discover" />
|
|
42
|
+
</EntityLayout.Route>
|
|
43
|
+
|
|
44
|
+
<EntityLayout.Route path="/eventcatalog-entity-map" title="EventCatalog: Entity Map">
|
|
45
|
+
<EventCatalogDocumentationEntityPage page="entity-map" />
|
|
46
|
+
</EntityLayout.Route>
|
|
47
|
+
|
|
48
|
+
<EntityLayout.Route path="/eventcatalog-schema-explorer" title="EventCatalog: Schema Explorer">
|
|
49
|
+
<EventCatalogDocumentationEntityPage page="schema-explorer" />
|
|
50
|
+
</EntityLayout.Route>
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
These components use the annotations on the current entity. To show a different resource, pass `id`, `version`, and `collection` explicitly:
|
|
54
|
+
|
|
55
|
+
```tsx
|
|
56
|
+
<EventCatalogDocumentationEntityPage
|
|
57
|
+
page="entity-map"
|
|
58
|
+
id="ordering"
|
|
59
|
+
version="1.0.0"
|
|
60
|
+
collection="domains"
|
|
61
|
+
/>
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
## Add an Architecture Graph
|
|
65
|
+
|
|
66
|
+
Use `EventCatalogArchitectureGraphEntityPage` to focus the catalog-wide graph on a resource. `depth` accepts `1`, `2`, or `3` and defaults to `2`.
|
|
67
|
+
|
|
68
|
+
```tsx
|
|
69
|
+
<EntityLayout.Route path="/eventcatalog-architecture" title="EventCatalog: Architecture">
|
|
70
|
+
<EventCatalogArchitectureGraphEntityPage type="service" depth={2} />
|
|
71
|
+
</EntityLayout.Route>
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
The resource ID comes from the current entity unless you pass `id`. `type` is the singular alias for `collection`; for example, `type="service"` maps to `services`.
|
|
75
|
+
|
|
76
|
+
## Add a System Context Map
|
|
77
|
+
|
|
78
|
+
Omit the props to show the catalog-wide overview:
|
|
79
|
+
|
|
80
|
+
```tsx
|
|
81
|
+
<EntityLayout.Route path="/eventcatalog-system-context" title="EventCatalog: System Context">
|
|
82
|
+
<EventCatalogSystemContextMapEntityPage />
|
|
83
|
+
</EntityLayout.Route>
|
|
84
|
+
```
|
|
85
|
+
|
|
86
|
+
To show one system, provide its ID and version:
|
|
87
|
+
|
|
88
|
+
```tsx
|
|
89
|
+
<EventCatalogSystemContextMapEntityPage
|
|
90
|
+
system="order-management-system"
|
|
91
|
+
version="1.0.0"
|
|
92
|
+
/>
|
|
93
|
+
```
|
|
94
|
+
|
|
95
|
+
On a mapped Backstage `System` entity, the component can read the system ID and version from annotations instead.
|
|
96
|
+
|
|
97
|
+
## Add a flow
|
|
98
|
+
|
|
99
|
+
A flow embed requires a flow ID and version:
|
|
100
|
+
|
|
101
|
+
```tsx
|
|
102
|
+
<EntityLayout.Route path="/eventcatalog-flow" title="EventCatalog: Flow">
|
|
103
|
+
<EventCatalogFlowEntityPage flow="checkout-saga" version="1.0.0" />
|
|
104
|
+
</EntityLayout.Route>
|
|
105
|
+
```
|
|
106
|
+
|
|
107
|
+
You can instead annotate a Backstage entity with the flow ID, version, and `flows` collection, then omit the `flow` and `version` props.
|
|
108
|
+
|
|
109
|
+
For every supported prop and page value, see the [component reference](/docs/plugins/backstage/components).
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
---
|
|
2
|
+
sidebar_position: 4
|
|
3
|
+
sidebar_label: Add overview cards
|
|
4
|
+
title: Add EventCatalog cards to an overview page
|
|
5
|
+
description: Place EventCatalog diagrams, tables, schemas, and flows in a Backstage overview grid.
|
|
6
|
+
keywords:
|
|
7
|
+
- backstage
|
|
8
|
+
- cards
|
|
9
|
+
- overview
|
|
10
|
+
---
|
|
11
|
+
|
|
12
|
+
Use the card components to place EventCatalog views alongside existing Backstage cards. The components fill their parent, so give each grid item an explicit height.
|
|
13
|
+
|
|
14
|
+
## Import the cards
|
|
15
|
+
|
|
16
|
+
```tsx
|
|
17
|
+
import {
|
|
18
|
+
EventCatalogEntityArchitectureGraphCard,
|
|
19
|
+
EventCatalogEntityEntityMapCard,
|
|
20
|
+
EventCatalogEntityFlowCard,
|
|
21
|
+
EventCatalogEntityMessageCard,
|
|
22
|
+
EventCatalogEntitySchemaExplorerCard,
|
|
23
|
+
EventCatalogEntitySystemContextMapCard,
|
|
24
|
+
EventCatalogEntityVisualiserCard,
|
|
25
|
+
} from '@eventcatalog/backstage-plugin-eventcatalog';
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
## Add cards to the overview grid
|
|
29
|
+
|
|
30
|
+
Add the cards to the `Grid` used by your entity overview. Choose heights that suit each visualization:
|
|
31
|
+
|
|
32
|
+
```tsx
|
|
33
|
+
const overviewContent = (
|
|
34
|
+
<Grid container spacing={3} alignItems="stretch">
|
|
35
|
+
<Grid item xs={12} style={{ height: 700 }}>
|
|
36
|
+
<EventCatalogEntityFlowCard
|
|
37
|
+
flow="checkout-saga"
|
|
38
|
+
version="1.0.0"
|
|
39
|
+
/>
|
|
40
|
+
</Grid>
|
|
41
|
+
|
|
42
|
+
<Grid item xs={12} style={{ height: 800 }}>
|
|
43
|
+
<EventCatalogEntityArchitectureGraphCard
|
|
44
|
+
type="service"
|
|
45
|
+
depth={2}
|
|
46
|
+
/>
|
|
47
|
+
</Grid>
|
|
48
|
+
|
|
49
|
+
<Grid item xs={12} md={6} style={{ height: 600 }}>
|
|
50
|
+
<EventCatalogEntityVisualiserCard />
|
|
51
|
+
</Grid>
|
|
52
|
+
|
|
53
|
+
<Grid item xs={12} md={6} style={{ height: 600 }}>
|
|
54
|
+
<EventCatalogEntityMessageCard />
|
|
55
|
+
</Grid>
|
|
56
|
+
</Grid>
|
|
57
|
+
);
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
The resource-oriented cards read the current entity's EventCatalog annotations. Components that select a global or specific view also accept explicit props:
|
|
61
|
+
|
|
62
|
+
```tsx
|
|
63
|
+
<EventCatalogEntityEntityMapCard
|
|
64
|
+
id="ordering"
|
|
65
|
+
version="1.0.0"
|
|
66
|
+
collection="domains"
|
|
67
|
+
/>
|
|
68
|
+
|
|
69
|
+
<EventCatalogEntitySystemContextMapCard
|
|
70
|
+
system="order-management-system"
|
|
71
|
+
version="1.0.0"
|
|
72
|
+
/>
|
|
73
|
+
|
|
74
|
+
<EventCatalogEntitySchemaExplorerCard />
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
To make a card span the whole overview width, use `xs={12}`. To arrange two cards side by side on medium screens, give each item `xs={12} md={6}`.
|
|
78
|
+
|
|
79
|
+
See [Control embed theme and size](/docs/plugins/backstage/control-theme-and-size) if an iframe does not fill its card.
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
---
|
|
2
|
+
sidebar_position: 5
|
|
3
|
+
sidebar_label: Theme and sizing
|
|
4
|
+
title: Control an embed's theme and size
|
|
5
|
+
description: Select a light or dark EventCatalog theme and make embeds fill their Backstage containers.
|
|
6
|
+
keywords:
|
|
7
|
+
- backstage
|
|
8
|
+
- theme
|
|
9
|
+
- iframe height
|
|
10
|
+
---
|
|
11
|
+
|
|
12
|
+
Every EventCatalog page and card component accepts a `theme` prop.
|
|
13
|
+
|
|
14
|
+
## Select a theme
|
|
15
|
+
|
|
16
|
+
Set `theme` to `light` or `dark`:
|
|
17
|
+
|
|
18
|
+
```tsx
|
|
19
|
+
<EventCatalogDocumentationEntityPage page="docs" theme="dark" />
|
|
20
|
+
|
|
21
|
+
<EventCatalogEntityArchitectureGraphCard
|
|
22
|
+
type="service"
|
|
23
|
+
depth={2}
|
|
24
|
+
theme="light"
|
|
25
|
+
/>
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
When `theme` is omitted, the embedded page uses the visitor's saved EventCatalog theme. The explicit prop affects that embed; it does not overwrite the visitor's saved preference.
|
|
29
|
+
|
|
30
|
+
To make every EventCatalog view in a Backstage app consistent, pass the same theme to each page and card component.
|
|
31
|
+
|
|
32
|
+
## Give cards an explicit height
|
|
33
|
+
|
|
34
|
+
The plugin iframe uses `height: 100%`, which means its height is inherited from its parent. Set the height on the Backstage grid item or another wrapping element:
|
|
35
|
+
|
|
36
|
+
```tsx
|
|
37
|
+
<Grid item xs={12} style={{ height: 800 }}>
|
|
38
|
+
<EventCatalogEntityArchitectureGraphCard
|
|
39
|
+
type="service"
|
|
40
|
+
depth={2}
|
|
41
|
+
theme="dark"
|
|
42
|
+
/>
|
|
43
|
+
</Grid>
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
Avoid percentage heights unless every ancestor has a defined height. A fixed height, viewport-relative height, or layout-controlled height gives the iframe a concrete area to fill:
|
|
47
|
+
|
|
48
|
+
```tsx
|
|
49
|
+
<Grid item xs={12} style={{ height: 'calc(100vh - 240px)', minHeight: 600 }}>
|
|
50
|
+
<EventCatalogEntitySchemaExplorerCard theme="dark" />
|
|
51
|
+
</Grid>
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
Full-page components automatically fill the height made available by the `EntityLayout.Route`. If a custom route wrapper collapses, give that wrapper an explicit height too.
|