Skip to content

Commit d5240e3

Browse files
committed
add badge docs
Signed-off-by: Zihan Kuang <zihan_kuang@outlook.com>
1 parent 23dda0c commit d5240e3

7 files changed

Lines changed: 95 additions & 127 deletions

File tree

content/en/kanvas/designer/understand-component-badges/images/design-badge.svg

Lines changed: 22 additions & 22 deletions
Loading
189 KB
Loading

content/en/kanvas/designer/understand-component-badges/images/operate-design.svg

Lines changed: 22 additions & 23 deletions
Loading

content/en/kanvas/designer/understand-component-badges/images/policies-notification.svg

Lines changed: 0 additions & 9 deletions
This file was deleted.
Lines changed: 50 additions & 62 deletions
Original file line numberDiff line numberDiff line change
@@ -1,110 +1,98 @@
1-
<!-- ---
2-
title: xxx Component Badges
3-
description: >
4-
Learn to interpret component badges, the small visual indicators that provide at-a-glance information about a component's status in both Designer and Operator modes.
1+
---
2+
title: Interpreting Component Badges
3+
description: Learn to interpret component badges, the small visual indicators that provide at-a-glance information about a component's status in both Designer and Operator modes.
54
weight: 3
65
categories: [Designer]
76
tags: [designs]
87
---
98

10-
(understand 感觉用的太多了,有别的吗)
11-
129
Ever wondered what those little icons in the corners of your components are? Think of them as your component's real-time status display. These indicators, called **badges**, give you at-a-glance information about everything from configuration errors to live performance.
1310

14-
What a badge tells you depends on your current mode: **Designer** or **Operator**. This guide will walk you through how to read and use them effectively in both contexts.
11+
![Example](images/example.png)
12+
13+
{{< alert type="info" title="A Tale of Two Modes" >}}
14+
A badge's meaning changes completely depending on your current mode. In **Designer**, badges help you build a valid blueprint. In **Operator**, they switch to providing real-time operational data from your live instances.
15+
{{< /alert >}}
16+
17+
### What Each Corner Means
1518

16-
### The xx Behind the Layout
19+
While the specific badges change depending on your mode, they all follow a consistent placement philosophy. Badges are organized into four quadrants around a component, with each corner reserved for a specific type of information.
1720

18-
Before diving into the details, it helps to understand the consistent layout of the badges. They are always placed in four distinct quadrants around a component, with each corner having a specific purpose. This creates a consistent visual language, so you always know where to look for certain types of information.
21+
- **Identity and Origin (Top-Left)**
22+
This corner answers the question, "Where did this come from?". It is used for primary metadata that identifies a component and traces its origin or management.
1923

20-
{{< figure src="/path/to/your/master-design-plan.png" title="Component Badge Layout Philosophy" alt="Diagram showing the four quadrants and their general purpose." >}}
24+
- **Contextual Actions (Top-Right)**
25+
This corner provides helpful, non-critical actions or shortcuts, such as a link to relevant documentation.
2126

22-
- **The "Problem Corner" (Bottom-Left):** This is your go-to spot for status checks. It consistently reports on issues, whether they are potential errors during the design phase or real-time failures in operation.
23-
- **Composition and Contents (Bottom-Right):** This quadrant answers the question, "What is this component made of?" It lists the contents or "inventory" of the component.
24-
- **Identity and Origin (Top-Left):** As the natural starting point for reading, this corner is reserved for primary metadata, telling you what a component is and where it came from.
25-
- **Contextual Actions (Top-Right):** This area is used for helpful, but non-critical, secondary actions like linking to external documentation.
27+
- **Composition and Contents (Bottom-Right)**
28+
This quadrant details what a component is made of or what it is currently managing, answering the question, "What's inside?".
29+
30+
- **The "Problem Corner" (Bottom-Left)**
31+
This is your go-to spot for all status checks and issue reporting. If something needs attention, you'll find it here.
2632

2733
### Badges in Designer Mode
2834

2935
When you're in Designer Mode, your main goal is to build a valid and deployable blueprint. The badges here act as your assistants, helping you catch issues early.
3036

31-
{{< figure src="/path/to/designer-mode-diagram.png" title="Badges in Designer Mode" alt="Diagram of component badges in Designer Mode." >}}
37+
![Diagram of component badges in Designer Mode](images/design-badge.svg)
3238

3339
#### Validation and Deployment Errors
3440

35-
This is arguably the most helpful badge when designing. It flags any invalid configurations in your components, so you can fix them *before* deploying.
41+
Displays the total count of configuration errors found through schema validation and dry-run checks. Clicking the badge reveals the specific errors.
3642

37-
> This badge provides instant feedback on syntax errors, missing fields, or other validation issues found through static analysis or a dry-run attempt.
43+
- For example, a badge showing "2" errors, which can be clicked to see details like "invalid image tag" or "missing required field".
3844

39-
If you see an error badge, you can often click on it or the component to navigate directly to the configuration field that needs your attention, helping you resolve issues quickly.
45+
If you see an error badge, you can often click on it to navigate directly to the configuration field that needs your attention.
4046

41-
{{< figure src="/images/resolve-error.gif" title="Resolving a validation error" alt="Animation showing a user clicking an error badge and fixing the configuration." >}}
47+
![Animation showing a user clicking an error badge and fixing the configuration](images/reslove-error.gif)
4248

4349
#### Design Inventory
4450

45-
The inventory in Designer Mode shows you other components that are logically bundled as part of your main component's blueprint. Think of it as the "included accessories" or "side dishes" that go with your "main dish."
51+
<img src="./images/inventory-notification.svg" alt="An icon representing the design inventory" style="width:10%; height:auto;" />
52+
53+
Shows the number of other components that are included or associated with this component in the design blueprint.
54+
55+
- For example, a badge on a Deployment showing "2", indicating it includes a ConfigMap and a Secret as part of its design.
4656

47-
- For example, a `Deployment` design might have a `ConfigMap` and a `Secret` in its inventory, as they are essential for its configuration.
57+
#### External Link
4858

49-
#### External Hyperlink
59+
A clickable link to external documentation relevant to the component.
5060

51-
This provides a convenient shortcut to external resources. You might find a link here to the official Kubernetes documentation for that component, saving you a trip to your browser.
61+
- For example, a link to the official Kubernetes documentation for Deployments.
5262

5363
### Badges in Operator Mode
5464

5565
Once your design is deployed, you enter Operator Mode to monitor its live status. Here, the badges switch context to provide real-time operational data.
5666

57-
{{< figure src="/path/to/operator-mode-diagram.png" title="Badges in Operator Mode" alt="Diagram of component badges in Operator Mode." >}}
67+
![Diagram of component badges in Operator Mode](images/operate-design.svg)
5868

5969
#### Design Link
6070

61-
Ever looked at a running service and wondered, "Which version of the design is this running?" The Design Link badge answers that. It provides a direct link back to the exact Meshery design that was used to deploy this instance, which is invaluable for troubleshooting and traceability.
62-
63-
#### Health, Performance, and Policy
64-
65-
This is your live monitoring feed. It gives you an immediate visual cue about the health and status of your running instance. You'll see indicators here for:
66-
- **Health:** Whether the instance is passing its liveness and readiness probes (e.g., green for healthy, red for failed).
67-
- **Performance:** High-level metrics like CPU or memory pressure.
68-
- **Policy:** Whether the instance is compliant with any configured security or operational policies.
71+
Indicates the resource is managed by Meshery and provides a direct link back to the source design that was used for deployment.
6972

70-
#### Live Inventory
73+
- For example, a Meshery logo that, when clicked, opens the original design file in the Designer Mode.
7174

72-
{{< alert type="info" title="Key Distinction" >}}
73-
The Inventory in Operator Mode shows **real-time running resources** (e.g., the number of active Pods). This is different from the design-time inventory, which only shows what's in the blueprint.
74-
{{< /alert >}}
75-
76-
This is one of the most useful operational badges. For a Kubernetes `Deployment`, for instance, this badge will show you the ready-state of its Pods (e.g., `Pods: 3/3`), so you know instantly if your desired number of replicas are up and running.
77-
78-
### Best Practices
79-
80-
- **Zero-Error Deployments:** Make it a habit to resolve all `Validation and Deployment Errors` in Designer Mode before you deploy. A clean slate here significantly increases the chance of a successful deployment.
81-
- **Trace, Don't Guess:** When troubleshooting a problem in a running service, always use the `Design Link` in Operator Mode first. It ensures you are looking at the correct source configuration and avoids accidentally modifying the wrong design.
75+
#### Policy Violation / Health / Performance
8276

83-
badge的总设计理念
77+
<img src="./images/warning-notification.svg" alt="Warning notification icon" style="width:15%; height:auto;" />
8478

85-
图:总设计理念
79+
Reports the real-time health, performance, and policy compliance status of the running instance.
8680

87-
大致解释一下:
81+
- For example, a yellow icon indicating a performance warning, or a red icon for a critical policy violation.
8882

89-
design mode
83+
#### Live Inventory / Status
9084

91-
图:design mode图
85+
Shows the real-time count and ready-state of the resources managed by this component. Can also show other statuses like an active terminal session.
9286

93-
每个角的内容粘贴过来
87+
- For example, a badge on a Deployment showing Pods: 3/3, indicating all desired replicas are running and ready.
9488

95-
error
96-
点击之后会跳转到需要填写的位置,帮助你找到哪里不对
97-
/images/reslove-error.gif
98-
99-
opearte mode
100-
101-
图: operate mode图
102-
103-
每个角的内容粘贴过来:
104-
105-
best pracitse:
106-
先确保每个compoennt都没有warning或者error之后再depoly
89+
### Best Practices
10790

91+
- **Fix Errors First:**
92+
Always resolve all validation errors in Designer before you deploy. A clean design is the best way to ensure a successful launch.
10893

94+
- **Find the Right Source File:**
95+
When fixing a problem with a live service, use the Design Link in Operator Mode. It's the fastest way to open the correct configuration file, saving you time while being clear and reliable.
10996

110-
-->
97+
- **Know Your Mode:**
98+
Pay close attention to your current mode. A badge's meaning is completely different in Designer than it is in Operator.

0 commit comments

Comments
 (0)