xiaobaicai66695 commented on code in PR #1084:
URL: https://github.com/apache/dubbo-go-pixiu/pull/1084#discussion_r4537321681


##########
pkg/config/schema/builtin.go:
##########
@@ -33,16 +33,21 @@ var supportedDubboParamTypes = []string{
        "java.lang.Float", "java.lang.Double", "java.lang.Boolean", 
"java.lang.Byte", "java.lang.Object", "java.util.Date",
 }
 
-// RegisterBuiltinSchemas installs only the Admin-facing route binding. Legacy
-// Resource and Method are compiler outputs rather than form objects.
+// RegisterBuiltinSchemas installs the Admin-facing configuration objects.
 func RegisterBuiltinSchemas(registry *Registry) error {
        if registry == nil {
                return fmt.Errorf("admin object schema registry is nil")
        }
        if err := registry.Register(adminRouteBindingSchema()); err != nil {
                return err
        }
-       return registry.RegisterValidator(KindAdminRouteBinding, 
validateAdminRouteBinding)
+       if err := registry.RegisterValidator(KindAdminRouteBinding, 
validateAdminRouteBinding); err != nil {
+               return err
+       }
+       if err := registry.Register(adminClusterSchema()); err != nil {

Review Comment:
   已在 232cabe9 修复:RouteBindingStore.Normalize 在写入前拒绝非 AdminRouteBinding;独立 
/config/api/route/validate 也检查 kind。新增错误 kind 的创建、同名更新和校验测试,并断言原草稿内容与 revision 
未改变。相关包的 go test -race、go vet 均通过。



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to