Skip to content

Database governance built for humans and agents — controlling changes and access across every major database.

Data Source username emptieness comment.

Tianzhou Chenc49839860119
diff --git a/frontend/src/types/bytebase.ts b/frontend/src/types/bytebase.ts
index 1ee14b6bea..c63140324f 100644
--- a/frontend/src/types/bytebase.ts
+++ b/frontend/src/types/bytebase.ts
@@ -93,7 +93,7 @@ export type DataSource = ResourceObject & {
attributes: {
name: string;
type: "ADMIN" | "NORMAL";
- // In mysql, username can be empty which means annonymous user
+ // In mysql, username can be empty which means anonymous user
username?: string;
password?: string;
database?: string;
diff --git a/frontend/src/views/InstanceDetail.vue b/frontend/src/views/InstanceDetail.vue
index 8c82aebb28..250824b68c 100644
--- a/frontend/src/views/InstanceDetail.vue
+++ b/frontend/src/views/InstanceDetail.vue
@@ -148,6 +148,9 @@ input[type="number"] {
Username <span style="color: red">*</span>
</label>
<div class="mt-1">
+ <!-- For mysql, username can be empty indicating anonymous user.
+ But it's a very bad practice to use anonymous user for admin operation,
+ thus we make it REQUIRED here. -->
<input
required
id="username"