mirror of
https://github.com/TeaOSLab/EdgeAPI.git
synced 2026-02-07 08:55:37 +08:00
区分社区版和商业版
This commit is contained in:
@@ -393,11 +393,6 @@ func (this *APINode) registerServices(server *grpc.Server) {
|
||||
pb.RegisterMonitorNodeServiceServer(server, instance)
|
||||
this.rest(instance)
|
||||
}
|
||||
{
|
||||
instance := this.serviceInstance(&services.AuthorityKeyService{}).(*services.AuthorityKeyService)
|
||||
pb.RegisterAuthorityKeyServiceServer(server, instance)
|
||||
this.rest(instance)
|
||||
}
|
||||
{
|
||||
instance := this.serviceInstance(&services.AuthorityNodeService{}).(*services.AuthorityNodeService)
|
||||
pb.RegisterAuthorityNodeServiceServer(server, instance)
|
||||
@@ -501,6 +496,8 @@ func (this *APINode) registerServices(server *grpc.Server) {
|
||||
this.rest(instance)
|
||||
}
|
||||
|
||||
APINodeServicesRegister(this, server)
|
||||
|
||||
// TODO check service names
|
||||
for serviceName := range server.GetServiceInfo() {
|
||||
index := strings.LastIndex(serviceName, ".")
|
||||
|
||||
9
internal/nodes/api_node_services_hook.go
Normal file
9
internal/nodes/api_node_services_hook.go
Normal file
@@ -0,0 +1,9 @@
|
||||
// Copyright 2021 Liuxiangchao iwind.liu@gmail.com. All rights reserved.
|
||||
// +build community
|
||||
|
||||
package nodes
|
||||
|
||||
import "google.golang.org/grpc"
|
||||
|
||||
func APINodeServicesRegister(node *APINode, server *grpc.Server) {
|
||||
}
|
||||
@@ -1,4 +1,5 @@
|
||||
// Copyright 2021 Liuxiangchao iwind.liu@gmail.com. All rights reserved.
|
||||
// +build plus
|
||||
|
||||
package services
|
||||
|
||||
Reference in New Issue
Block a user