enuoCM opened a new issue, #2825: URL: https://github.com/apache/apisix-dashboard/issues/2825
### Issue description Q1: `func (s *GenericStore) listAndWatch() error ` the function will be called when init and re-init the store. Why not clean the cache when re-init? There will be some dirty data if not clean it. Q2: 'List' first and 'Watch' second. What would happen if any key be modified or new keys be added during the gap between the 'List' and the 'Watch'? Q3: initLock just for listAndWatch(). Why not lock for Get, List, Range etc.? ### Expected behavior Q1: clean the cache before 'List' and 'Watch' Q2: 'Watch' first and 'List' second should be a little better Q3: Need lock those methods too. ### How to Reproduce Just check the code. ### Screenshots _No response_ ### Environment - apisix version (cmd: `apisix version`): - OS (cmd: `uname -a`): - OpenResty / Nginx version (cmd: `nginx -V` or `openresty -V`): - etcd version, if have (cmd: run `etcd --version`): - apisix-dashboard version, if have: - Browser version, if have: ### Additional context _No response_ -- 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: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
