tianxiaoliang commented on a change in pull request #86: #84 event support 
exact match
URL: https://github.com/apache/servicecomb-kie/pull/86#discussion_r375591068
 
 

 ##########
 File path: server/resource/v1/kv_resource_test.go
 ##########
 @@ -254,6 +254,41 @@ func TestKVResource_List(t *testing.T) {
                assert.NoError(t, err)
                assert.Equal(t, 1, len(result.Data))
        })
+       t.Run("list kv by service label, with wait and match param,not exact 
match and return 304", func(t *testing.T) {
+               r, _ := http.NewRequest("GET", 
"/v1/test/kie/kv?label=match:test&wait=10s&match=exact", nil)
+               noopH := &handler2.NoopAuthHandler{}
+               chain, _ := handler.CreateChain(common.Provider, "testchain1", 
noopH.Name())
+               r.Header.Set("Content-Type", "application/json")
+               kvr := &v1.KVResource{}
+               c, err := restfultest.New(kvr, chain)
+               assert.NoError(t, err)
+               resp := httptest.NewRecorder()
+               start := time.Now()
+               c.ServeHTTP(resp, r)
+               go func() {
+                       kv := &model.KVDoc{
+                               Value:  "1s",
+                               Labels: map[string]string{"match": "test"},
 
 Review comment:
   这里看着给的是完全匹配的更新事件和 use case名字不符吧

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to