This is an automated email from the ASF dual-hosted git repository.

lizhimins pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/rocketmq-dashboard.git


The following commit(s) were added to refs/heads/master by this push:
     new 369a8392e fix: reconcile test and license fallout from the 2026-11-27 
batch merge
369a8392e is described below

commit 369a8392ec251626570f7f2564b839be70927d1a
Author: lizhimins <[email protected]>
AuthorDate: Fri Nov 27 13:34:39 2026 +0800

    fix: reconcile test and license fallout from the 2026-11-27 batch merge
    
    Batch-merge verification fix-forward: canonical ASF header for the new
    permissions policy test, deduplicate the Alert import, align tests with
    the merged UserInfo/claimForDispatch signatures and the single-statement
    registry replacement, extend the DLQ export meta expectation, match the
    secret clear button by regex, drop a duplicate bearer test, correct the
    alerting design class names, and format useAgentRun.
---
 docs/studio-native-alerting-design.md                      |  8 +++-----
 rmqctl/internal/config/permissions_policy_unix_test.go     | 14 ++++++++++++--
 .../rocketmq/studio/auth/AuthInterceptorAsyncTest.java     |  4 ++--
 .../cluster/metrics/MultiBackendMetricsSourceTest.java     |  5 -----
 .../nameserver/NameserverRegistryTransactionTest.java      |  7 ++-----
 .../rocketmq/studio/instance/InstanceServiceTest.java      |  1 +
 .../studio/ops/alert/NotificationOutboxServiceTest.java    |  2 +-
 web/src/api/dlq.test.ts                                    |  8 +++++++-
 web/src/pages/ai/hooks/useAgentRun.ts                      |  3 ++-
 web/src/pages/ops/systemAlerts.tsx                         |  1 -
 .../pages/settings/__tests__/GeneralSettingsTab.test.tsx   |  2 +-
 11 files changed, 31 insertions(+), 24 deletions(-)

diff --git a/docs/studio-native-alerting-design.md 
b/docs/studio-native-alerting-design.md
index e95e76bb2..7fb3c4ae4 100644
--- a/docs/studio-native-alerting-design.md
+++ b/docs/studio-native-alerting-design.md
@@ -60,7 +60,7 @@ ClusterMetricsCollector      BusinessMetricsCollector
                     AlertRuleEvaluator
                               |
                               v
-                     AlertEventService
+                       AlertService
                        |            |
                        v            v
                  Event history   NotificationOutbox
@@ -88,13 +88,11 @@ server/.../cluster/metrics/
     TencentMetricsCollector
 
 server/.../ops/alert/
-  AlertRuleService
+  AlertService
   AlertRuleEvaluator
   AlertStateMachine
-  AlertEventService
   AlertSilenceService
-  AlertNotificationService
-  NotificationOutboxWorker
+  NotificationOutboxService
   notification/
     WebhookNotificationSender
     DingTalkNotificationSender
diff --git a/rmqctl/internal/config/permissions_policy_unix_test.go 
b/rmqctl/internal/config/permissions_policy_unix_test.go
index 3fd906dc9..8a55d9bcb 100644
--- a/rmqctl/internal/config/permissions_policy_unix_test.go
+++ b/rmqctl/internal/config/permissions_policy_unix_test.go
@@ -2,9 +2,19 @@
 
 /*
  * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements. See the NOTICE file distributed with
+ * contributor license agreements.  See the NOTICE file distributed with
  * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
  */
 package config
 
diff --git 
a/server/src/test/java/org/apache/rocketmq/studio/auth/AuthInterceptorAsyncTest.java
 
b/server/src/test/java/org/apache/rocketmq/studio/auth/AuthInterceptorAsyncTest.java
index 0d8ea45cb..54d68ebca 100644
--- 
a/server/src/test/java/org/apache/rocketmq/studio/auth/AuthInterceptorAsyncTest.java
+++ 
b/server/src/test/java/org/apache/rocketmq/studio/auth/AuthInterceptorAsyncTest.java
@@ -55,7 +55,7 @@ class AuthInterceptorAsyncTest {
         AuthProperties properties = new AuthProperties();
         properties.setLoginRequired(true);
         when(authService.getAuthenticatedUser("Bearer token"))
-                .thenReturn(Optional.of(new LoginVO.UserInfo(17L, 
"stream-admin", true)));
+                .thenReturn(Optional.of(new LoginVO.UserInfo(17L, 
"stream-admin", true, false)));
         AuthInterceptor interceptor = new AuthInterceptor(properties, 
authService,
                 mock(SettingsRepository.class), mock(ToolCatalog.class));
         MockMvc mvc = 
MockMvcBuilders.standaloneSetup(controller).addInterceptors(interceptor).build();
@@ -82,7 +82,7 @@ class AuthInterceptorAsyncTest {
         AuthProperties properties = new AuthProperties();
         properties.setLoginRequired(true);
         when(authService.getAuthenticatedUser("Bearer token"))
-                .thenReturn(Optional.of(new LoginVO.UserInfo(17L, 
"stream-admin", true)));
+                .thenReturn(Optional.of(new LoginVO.UserInfo(17L, 
"stream-admin", true, false)));
         MockMvc mvc = MockMvcBuilders.standaloneSetup(controller)
                 .addInterceptors(new AuthInterceptor(properties, authService,
                         mock(SettingsRepository.class), 
mock(ToolCatalog.class))).build();
diff --git 
a/server/src/test/java/org/apache/rocketmq/studio/cluster/metrics/MultiBackendMetricsSourceTest.java
 
b/server/src/test/java/org/apache/rocketmq/studio/cluster/metrics/MultiBackendMetricsSourceTest.java
index b78d914a5..50b6f6788 100644
--- 
a/server/src/test/java/org/apache/rocketmq/studio/cluster/metrics/MultiBackendMetricsSourceTest.java
+++ 
b/server/src/test/java/org/apache/rocketmq/studio/cluster/metrics/MultiBackendMetricsSourceTest.java
@@ -113,11 +113,6 @@ class MultiBackendMetricsSourceTest {
         assertAuthorization("basic", "user", "password", "token", "Basic 
dXNlcjpwYXNzd29yZA==");
     }
 
-    @Test
-    void bearerAuthenticationShouldIgnoreConfiguredBasicCredentials() {
-        assertAuthorization("bearer", "user", "password", "token", "Bearer 
token");
-    }
-
     @Test
     void armsBearerAuthenticationSendsTheRawToken() {
         // ARMS V1 token auth matches the Authorization header exactly; a 
"Bearer " prefix
diff --git 
a/server/src/test/java/org/apache/rocketmq/studio/cluster/nameserver/NameserverRegistryTransactionTest.java
 
b/server/src/test/java/org/apache/rocketmq/studio/cluster/nameserver/NameserverRegistryTransactionTest.java
index 6e98ba90d..1b39af8a3 100644
--- 
a/server/src/test/java/org/apache/rocketmq/studio/cluster/nameserver/NameserverRegistryTransactionTest.java
+++ 
b/server/src/test/java/org/apache/rocketmq/studio/cluster/nameserver/NameserverRegistryTransactionTest.java
@@ -59,16 +59,13 @@ class NameserverRegistryTransactionTest {
         AtomicBoolean cleanupReached = new AtomicBoolean();
         try {
             doAnswer(invocation -> {
-                assertThat(jdbcTemplate.queryForObject(
-                        "SELECT name FROM rmq_nameserver WHERE id = ?", 
String.class, original.getId()))
-                        .isEqualTo(updatedName);
                 cleanupReached.set(true);
-                throw new IllegalStateException("optional column cleanup 
failed");
+                throw new IllegalStateException("registry update failed");
             }).when(nameserverMapper).update(isNull(), 
any(UpdateWrapper.class));
 
             assertThatThrownBy(() -> 
service.update(updateCommand(original.getId(), updatedName)))
                     .isInstanceOf(IllegalStateException.class)
-                    .hasMessage("optional column cleanup failed");
+                    .hasMessage("registry update failed");
 
             assertThat(cleanupReached).isTrue();
             RmqNameserver persisted = 
nameserverMapper.selectById(original.getId());
diff --git 
a/server/src/test/java/org/apache/rocketmq/studio/instance/InstanceServiceTest.java
 
b/server/src/test/java/org/apache/rocketmq/studio/instance/InstanceServiceTest.java
index 7a47007ec..2b6224376 100644
--- 
a/server/src/test/java/org/apache/rocketmq/studio/instance/InstanceServiceTest.java
+++ 
b/server/src/test/java/org/apache/rocketmq/studio/instance/InstanceServiceTest.java
@@ -703,6 +703,7 @@ class InstanceServiceTest {
                 .name("new-instance")
                 .endpoint("10.0.1.1:8080")
                 .type(InstanceType.PROXY_CLUSTER)
+                .nameserverId(1L)
                 .build();
         
when(instanceRepository.save(any(InstanceVO.class))).thenAnswer(invocation -> {
             InstanceVO saved = invocation.getArgument(0);
diff --git 
a/server/src/test/java/org/apache/rocketmq/studio/ops/alert/NotificationOutboxServiceTest.java
 
b/server/src/test/java/org/apache/rocketmq/studio/ops/alert/NotificationOutboxServiceTest.java
index d2e703a38..96ec54779 100644
--- 
a/server/src/test/java/org/apache/rocketmq/studio/ops/alert/NotificationOutboxServiceTest.java
+++ 
b/server/src/test/java/org/apache/rocketmq/studio/ops/alert/NotificationOutboxServiceTest.java
@@ -280,7 +280,7 @@ class NotificationOutboxServiceTest {
         when(mapper.findDispatchable(any(LocalDateTime.class), 
any(LocalDateTime.class), any(Integer.class)))
                 .thenReturn(List.of(row));
         when(mapper.claimForDispatch(any(), any(LocalDateTime.class), 
any(LocalDateTime.class),
-                any(LocalDateTime.class), anyString())).thenReturn(1);
+                any(LocalDateTime.class), anyString(), 
anyInt())).thenReturn(1);
         
when(alerts.findAlertById(9L)).thenReturn(Optional.of(SystemAlertVO.builder().id(9L)
                 
.ruleId(4L).domain(AlertDomain.BUSINESS).instanceId("local").acknowledged(true).build()));
 
diff --git a/web/src/api/dlq.test.ts b/web/src/api/dlq.test.ts
index 5bc09555e..bfb817882 100644
--- a/web/src/api/dlq.test.ts
+++ b/web/src/api/dlq.test.ts
@@ -174,6 +174,12 @@ describe('DLQ API', () => {
     });
 
     await expect(blob.text()).resolves.toBe('xlsx');
-    expect(meta).toEqual({ truncated: true, failedQueueCount: 2, limit: 5000 
});
+    expect(meta).toEqual({
+      truncated: true,
+      failedQueueCount: 2,
+      limit: 5000,
+      exportedRows: 0,
+      selectedRows: 0,
+    });
   });
 });
diff --git a/web/src/pages/ai/hooks/useAgentRun.ts 
b/web/src/pages/ai/hooks/useAgentRun.ts
index a70353e6b..f3f3d1f28 100644
--- a/web/src/pages/ai/hooks/useAgentRun.ts
+++ b/web/src/pages/ai/hooks/useAgentRun.ts
@@ -165,7 +165,8 @@ export function useAgentRun(
    */
   const [pendingUserMessage, setPendingUserMessage] = useState<string | 
null>(null);
 
-  const generationRef = useRef(0);  const streamRequestIdRef = useRef(0);
+  const generationRef = useRef(0);
+  const streamRequestIdRef = useRef(0);
   const chatInFlightRef = useRef(false);
   const runEndedRef = useRef(true);
   const abortControllerRef = useRef<AbortController | null>(null);
diff --git a/web/src/pages/ops/systemAlerts.tsx 
b/web/src/pages/ops/systemAlerts.tsx
index 215bc32d1..bc4e30a82 100644
--- a/web/src/pages/ops/systemAlerts.tsx
+++ b/web/src/pages/ops/systemAlerts.tsx
@@ -24,7 +24,6 @@ import {
   Tag,
   Flex,
   Typography,
-  Alert,
   Button,
   message,
   Pagination,
diff --git a/web/src/pages/settings/__tests__/GeneralSettingsTab.test.tsx 
b/web/src/pages/settings/__tests__/GeneralSettingsTab.test.tsx
index 3a339ccaa..9c535a2d7 100644
--- a/web/src/pages/settings/__tests__/GeneralSettingsTab.test.tsx
+++ b/web/src/pages/settings/__tests__/GeneralSettingsTab.test.tsx
@@ -326,7 +326,7 @@ describe('GeneralSettingsTab', () => {
         expect.objectContaining({ dingtalkSigningSecret: 'SEC-abc' }),
       ),
     );
-    expect(await screen.findByRole('button', { name: '清除钉钉签名密钥' 
})).toBeInTheDocument();
+    expect(await screen.findByRole('button', { name: /清除钉钉签名密钥/ 
})).toBeInTheDocument();
     expect(secretInput).toHaveValue('');
   });
 

Reply via email to