membphis commented on a change in pull request #871: bugfix: reloaded the etcd 
configuation data if the index
URL: https://github.com/apache/incubator-apisix/pull/871#discussion_r351607829
 
 

 ##########
 File path: lua/apisix/core/config_etcd.lua
 ##########
 @@ -194,9 +210,13 @@ local function sync_data(self)
     log.debug("res: ", json.delay_encode(res, true))
     log.debug("headers: ", json.delay_encode(headers, true))
     if not res then
-        if headers then
-          self:upgrade_version(headers["X-Etcd-Index"])
+        if err == "The event in requested index is outdated and cleared" then
 
 Review comment:
   
https://github.com/etcd-io/etcd/blob/a621d807f061e1dd635033a8d6bc261461429e27/Documentation/v2/errorcode.md
   
   it shoud be a static string.

----------------------------------------------------------------
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:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to