2020-10-09 20:57:08 +00:00
|
|
|
<a class="card"
|
2020-11-12 15:40:15 +00:00
|
|
|
href={{href-to "dc.services.show.index" @item.Name}}
|
|
|
|
data-permission={{service/intention-permissions @item}}
|
|
|
|
id="{{@item.Namespace}}{{@item.Name}}"
|
2020-10-09 20:31:15 +00:00
|
|
|
>
|
|
|
|
<p>
|
2020-11-12 15:40:15 +00:00
|
|
|
{{@item.Name}}
|
2020-10-09 20:31:15 +00:00
|
|
|
</p>
|
|
|
|
<div class="details">
|
2020-11-13 15:39:00 +00:00
|
|
|
{{#if (and (and @nspace (env 'CONSUL_NSPACES_ENABLED')) @type)}}
|
2020-10-09 20:31:15 +00:00
|
|
|
<dl class="nspace">
|
|
|
|
<dt>
|
|
|
|
<Tooltip>
|
|
|
|
Namespace
|
|
|
|
</Tooltip>
|
|
|
|
</dt>
|
|
|
|
<dd>
|
2020-11-12 15:40:15 +00:00
|
|
|
{{@item.Namespace}}
|
2020-10-09 20:31:15 +00:00
|
|
|
</dd>
|
|
|
|
</dl>
|
|
|
|
{{/if}}
|
2020-11-12 15:40:15 +00:00
|
|
|
{{#if (eq @item.Datacenter @dc)}}
|
|
|
|
{{#let (service/health-percentage @item) as |percentage|}}
|
2020-10-09 20:31:15 +00:00
|
|
|
{{#if (not-eq percentage.passing 0)}}
|
|
|
|
<span class="passing">{{percentage.passing}}%</span>
|
|
|
|
{{/if}}
|
|
|
|
{{#if (not-eq percentage.warning 0)}}
|
|
|
|
<span class="warning">{{percentage.warning}}%</span>
|
|
|
|
{{/if}}
|
|
|
|
{{#if (not-eq percentage.critical 0)}}
|
|
|
|
<span class="critical">{{percentage.critical}}%</span>
|
|
|
|
{{/if}}
|
|
|
|
{{/let}}
|
|
|
|
{{else}}
|
|
|
|
<dl class="health">
|
|
|
|
<dt>
|
|
|
|
<Tooltip>
|
|
|
|
We are unable to determine the health status of services in remote datacenters.
|
|
|
|
</Tooltip>
|
|
|
|
</dt>
|
|
|
|
<dd>
|
|
|
|
Health
|
|
|
|
</dd>
|
|
|
|
</dl>
|
|
|
|
{{/if}}
|
|
|
|
</div>
|
2020-11-02 18:38:43 +00:00
|
|
|
{{#if (and @hasMetricsProvider (not-eq @service.Kind 'ingress-gateway'))}}
|
2020-10-09 20:31:15 +00:00
|
|
|
{{#if (eq @type 'upstream')}}
|
2020-10-26 19:48:23 +00:00
|
|
|
<TopologyMetrics::Stats
|
2020-11-13 15:39:00 +00:00
|
|
|
@nspace={{@item.Namespace}}
|
|
|
|
@dc={{@item.Datacenter}}
|
2020-10-26 19:48:23 +00:00
|
|
|
@endpoint='upstream-summary-for-service'
|
2020-11-02 18:38:43 +00:00
|
|
|
@service={{@service.Service}}
|
2020-11-12 15:40:15 +00:00
|
|
|
@item={{@item.Name}}
|
2020-10-26 19:48:23 +00:00
|
|
|
@noMetricsReason={{@noMetricsReason}}
|
|
|
|
/>
|
2020-10-09 20:31:15 +00:00
|
|
|
{{else}}
|
2020-10-26 19:48:23 +00:00
|
|
|
<TopologyMetrics::Stats
|
2020-11-13 15:39:00 +00:00
|
|
|
@nspace={{@item.Namespace}}
|
|
|
|
@dc={{@item.Datacenter}}
|
2020-10-26 19:48:23 +00:00
|
|
|
@endpoint='downstream-summary-for-service'
|
2020-11-02 18:38:43 +00:00
|
|
|
@service={{@service.Service}}
|
2020-11-12 15:40:15 +00:00
|
|
|
@item={{@item.Name}}
|
2020-10-26 19:48:23 +00:00
|
|
|
@noMetricsReason={{@noMetricsReason}}
|
|
|
|
/>
|
2020-10-09 20:31:15 +00:00
|
|
|
{{/if}}
|
|
|
|
{{/if}}
|
2020-11-12 15:40:15 +00:00
|
|
|
</a>
|