You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@servicecomb.apache.org by GitBox <gi...@apache.org> on 2021/08/10 13:02:30 UTC

[GitHub] [servicecomb-kie] tianxiaoliang commented on a change in pull request #194: Add ETCD datasource implement

tianxiaoliang commented on a change in pull request #194:
URL: https://github.com/apache/servicecomb-kie/pull/194#discussion_r685970975



##########
File path: server/plugin/qms/quota.go
##########
@@ -37,10 +37,14 @@ const (
 type BuildInManager struct {
 }
 
+func (m *BuildInManager) GetQuota(service, domain, resource string) (*quota.Quota, error) {
+	panic("implement me")
+}
+
 //GetQuotas get usage and quota
 func (m *BuildInManager) GetQuotas(serviceName, domain string) ([]*quota.Quota, error) {
 	max := archaius.GetInt64(QuotaConfigKey, DefaultQuota)
-	total, err := datasource.GetBroker().GetKVDao().Total(context.TODO(), domain)
+	total, err := datasource.GetBroker().GetKVDao().Total(context.TODO(), domain, domain)

Review comment:
       增加对应的参数

##########
File path: test/init.go
##########
@@ -43,6 +45,7 @@ func init() {
 	archaius.Set("servicecomb.cipher.plugin", "default")
 	cipher.Init()
 	validator.Init()
+	config.Configurations.DB.Kind = "etcd"

Review comment:
       你这个门禁还是mongo或者就是etcd,看下readme,用env控制

##########
File path: server/resource/v1/admin_resource.go
##########
@@ -67,7 +67,7 @@ func (r *AdminResource) HealthCheck(context *restful.Context) {
 	resp.Revision = strconv.FormatInt(latest, 10)
 	resp.Version = runtime.Version
 	resp.Timestamp = time.Now().Unix()
-	total, err := datasource.GetBroker().GetKVDao().Total(context.Ctx, domain)
+	total, err := datasource.GetBroker().GetKVDao().Total(context.Ctx, domain, domain)

Review comment:
       增加对应的参数




-- 
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: commits-unsubscribe@servicecomb.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org