You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@servicecomb.apache.org by li...@apache.org on 2017/12/26 12:52:18 UTC

[incubator-servicecomb-service-center] branch master updated: SCB-131 Do not check the micro-service description field in registration. (#228)

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

littlecui pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-servicecomb-service-center.git


The following commit(s) were added to refs/heads/master by this push:
     new 49d2b34  SCB-131 Do not check the micro-service description field in registration. (#228)
49d2b34 is described below

commit 49d2b344030c9cc8d8906aff5636e4f620596e46
Author: little-cui <su...@qq.com>
AuthorDate: Tue Dec 26 20:52:16 2017 +0800

    SCB-131 Do not check the micro-service description field in registration. (#228)
---
 server/core/common.go | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/server/core/common.go b/server/core/common.go
index d422834..6efbae3 100644
--- a/server/core/common.go
+++ b/server/core/common.go
@@ -65,7 +65,7 @@ func init() {
 	// version模糊规则: 1.0, 1.0+, 1.0-2.0, latest
 	versionFuzzyRegex, _ := regexp.Compile(`^[0-9]*$|^[0-9]+(\.[0-9]+)*\+{0,1}$|^[0-9]+(\.[0-9]+)*-[0-9]+(\.[0-9]+)*$|^latest$`)
 	pathRegex, _ := regexp.Compile(`^[A-Za-z0-9.,?'\\/+&amp;%$#=~_\-@{}]*$`)
-	descriptionRegex, _ := regexp.Compile(`^[\p{Han}\w\s。.:*,\-:”“"]*$`)
+	// descriptionRegex, _ := regexp.Compile(`^[\p{Han}\w\s。.:*,\-:”“"]*$`)
 	levelRegex, _ := regexp.Compile(`^(FRONT|MIDDLE|BACK)$`)
 	statusRegex, _ := regexp.Compile("^(" + pb.MS_UP + "|" + pb.MS_DOWN + ")*$")
 	serviceIdRegex, _ := regexp.Compile(`^.*$`)
@@ -111,7 +111,7 @@ func init() {
 	FrameWKValidator.AddRule("Version", &validate.ValidateRule{Length: 64, Regexp: frameversionRegex})
 
 	MicroServiceValidator.AddRules(MicroServiceKeyValidator.GetRules())
-	MicroServiceValidator.AddRule("Description", &validate.ValidateRule{Length: 256, Regexp: descriptionRegex})
+	MicroServiceValidator.AddRule("Description", &validate.ValidateRule{Length: 256})
 	MicroServiceValidator.AddRule("Level", &validate.ValidateRule{Min: 1, Regexp: levelRegex})
 	MicroServiceValidator.AddRule("Status", &validate.ValidateRule{Min: 1, Regexp: statusRegex})
 	MicroServiceValidator.AddRule("Schemas", SchemaIdRule)

-- 
To stop receiving notification emails like this one, please contact
['"commits@servicecomb.apache.org" <co...@servicecomb.apache.org>'].