Code Review
/
src
/
xds
/
xds-agent.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
Fixed XDS Server connection lost and reconnection.
[src/xds/xds-agent.git]
/
lib
/
agent
/
projects.go
diff --git
a/lib/agent/projects.go
b/lib/agent/projects.go
index
a0b641a
..
a2d8fe1
100644
(file)
--- a/
lib/agent/projects.go
+++ b/
lib/agent/projects.go
@@
-248,10
+248,12
@@
func (p *Projects) createUpdate(newF xaapiv1.ProjectConfig, create bool, initial
// Force sync after creation
// (need to defer to be sure that WS events will arrive after HTTP creation reply)
// Force sync after creation
// (need to defer to be sure that WS events will arrive after HTTP creation reply)
- go func() {
- time.Sleep(time.Millisecond * 500)
- fld.Sync()
- }()
+ if create {
+ go func() {
+ time.Sleep(time.Millisecond * 500)
+ fld.Sync()
+ }()
+ }
return newPrj, nil
}
return newPrj, nil
}