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 folder events detection.
[src/xds/xds-agent.git]
/
lib
/
agent
/
projects.go
diff --git
a/lib/agent/projects.go
b/lib/agent/projects.go
index
a2d8fe1
..
d6268fa
100644
(file)
--- a/
lib/agent/projects.go
+++ b/
lib/agent/projects.go
@@
-246,14
+246,12
@@
func (p *Projects) createUpdate(newF xaapiv1.ProjectConfig, create bool, initial
// Add to folders list
p.projects[newPrj.ID] = &fld
// Add to folders list
p.projects[newPrj.ID] = &fld
- // Force sync
after creation
+ // Force sync
to get an initial sync status
// (need to defer to be sure that WS events will arrive after HTTP creation reply)
// (need to defer to be sure that WS events will arrive after HTTP creation reply)
- if create {
- go func() {
- time.Sleep(time.Millisecond * 500)
- fld.Sync()
- }()
- }
+ go func() {
+ time.Sleep(time.Millisecond * 500)
+ fld.Sync()
+ }()
return newPrj, nil
}
return newPrj, nil
}