[helix-front] Deal with special case that some instance does not have HELIX_ENABLED config item
Project: http://git-wip-us.apache.org/repos/asf/helix/repo Commit: http://git-wip-us.apache.org/repos/asf/helix/commit/6aa42664 Tree: http://git-wip-us.apache.org/repos/asf/helix/tree/6aa42664 Diff: http://git-wip-us.apache.org/repos/asf/helix/diff/6aa42664 Branch: refs/heads/master Commit: 6aa42664a8bbafb2f7ba60c41238bee71c51c16e Parents: 1d844b3 Author: Vivo Xu <v...@linkedin.com> Authored: Thu Sep 7 16:50:34 2017 -0700 Committer: Junkai Xue <j...@linkedin.com> Committed: Mon Nov 6 17:07:30 2017 -0800 ---------------------------------------------------------------------- helix-front/client/app/instance/shared/instance.service.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/helix/blob/6aa42664/helix-front/client/app/instance/shared/instance.service.ts ---------------------------------------------------------------------- diff --git a/helix-front/client/app/instance/shared/instance.service.ts b/helix-front/client/app/instance/shared/instance.service.ts index 2f1cc07..551b0d8 100644 --- a/helix-front/client/app/instance/shared/instance.service.ts +++ b/helix-front/client/app/instance/shared/instance.service.ts @@ -32,7 +32,9 @@ export class InstanceService extends HelixService { .map(data => { const liveInstance = data.liveInstance; const config = data.config; - const enabled = config && config.simpleFields && config.simpleFields.HELIX_ENABLED == 'true'; + // there are two cases meaning enabled both: + // HELIX_ENABLED: true or no such configuration + const enabled = config && config.simpleFields && config.simpleFields.HELIX_ENABLED != 'false'; return liveInstance && liveInstance.simpleFields ? new Instance( data.id,