Issue #1935 - argocd app sync hangs when cluster is not configured #1935 (#1962)

This commit is contained in:
Alexander Matyushentsev 2019-07-19 13:04:01 -07:00 committed by GitHub
parent 3f4bacdbba
commit ce861fe366
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 3 deletions

View file

@ -1476,7 +1476,7 @@ func waitOnApplicationStatus(acdClient apiclient.Client, appName string, timeout
selectedResourcesAreReady = checkResourceStatus(watchSync, watchHealth, watchOperation, watchSuspended, app.Status.Health.Status, string(app.Status.Sync.Status), appEvent.Application.Operation)
}
if len(app.Status.GetErrorConditions()) == 0 && selectedResourcesAreReady {
if selectedResourcesAreReady {
printFinalStatus(app)
return app, nil
}

View file

@ -378,8 +378,11 @@ export class ApplicationDetails extends React.Component<RouteComponentProps<{ na
const treeSource = new Observable<{ application: appModels.Application, tree: appModels.ApplicationTree }>((observer) => {
services.applications.resourceTree(app.metadata.name)
.then((tree) => observer.next({ application: app, tree }))
.catch((e) => observer.error(e));
}).repeat().retryWhen((errors) => errors.delay(500));
.catch((e) => {
observer.next({ application: app, tree: fallbackTree });
observer.error(e);
});
}).repeat().retryWhen((errors) => errors.delay(1000));
if (appInfo.watchEvent) {
return treeSource;
} else {