{% extends "base.html" %} {% from "_macros.html" import th %} {% block title %}{{ t('流面板 Stream board · 柏讯寻新') }}{% endblock %} {% block content %}

{{ t('流面板') }}

{{ t('数据流获取与处理的运行健康(只读)read-only runtime health of the stream plane') }}

{# ── 1. stream health (3.6) ───────────────────────────── #}

{{ t('流面健康度') }}

{% if health is none %}

{{ t('未配置 Redis 流面,无健康度数据(仅展示存储水位与执行分布)') }}

{% elif health.error %}

{{ t('流面不可达') }} {{ health.error }}

{% else %}
{{ th(t('积压')) }}{{ th(t('未确认')) }}{{ th(t('最老滞后')) }}{{ th(t('消费者')) }}{{ th(t('告警')) }}
{{ "{:,}".format(health.length) }} {{ "{:,}".format(health.pending) }} {% if health.oldest_pending_idle_ms is not none %}{{ (health.oldest_pending_idle_ms / 1000) | round(1) }}s{% else %}—{% endif %} {{ health.consumers }} {% if health.alert %}{{ t('告警') }} {{ health.alert_reasons | join('; ') }}{% else %}{{ t('正常') }}{% endif %}
{% endif %} {# ── 2. storage watermark (2.7) ───────────────────────── #}

{{ t('存储水位') }}

{% set wm = watermark.rollup %}
{{ th(t('覆盖概念')) }}{{ th(t('覆盖点')) }}{{ th(t('跨源共存')) }}{{ th(t('rollup 新鲜度')) }}{{ th(t('hook 健康')) }}
{{ "{:,}".format(wm.concepts_covered) }} {{ "{:,}".format(wm.points_total) }} {{ "{:,}".format(wm.coexisting_points_total) }} {% if wm.age_hours is not none %}{{ wm.age_hours }}h{% else %}—{% endif %} {% if watermark.drift.hook_healthy %}{{ t('健康') }}{% else %}{{ t('漂移') }} {{ watermark.drift }}{% endif %}
{% if watermark.store %}

{{ t('本地存量') }} {{ "{:,}".format(watermark.store.rows or 0) }} {{ t('行') }} · {% if watermark.store.obs_month_dist %}{{ t('obs_month 桶') }}: {{ (watermark.store.obs_month_dist | length) - 1 }} {{ t('个月') }}{% if '_unmappable' in watermark.store.obs_month_dist %} · {{ t('default 分区收容') }} {{ watermark.store.obs_month_dist['_unmappable'] }}{% endif %}{% else %}{{ t('obs_month 分布未采样') }}{% endif %}

{% else %}

{{ t('census 尚未采样(存储存量与 obs_month 分布待刷新)') }}

{% endif %} {# ── 3. execution distribution ────────────────────────── #}

{{ t('执行模型分布') }}

{{ t('近') }} {{ recent_total }} {{ t('次运行') }}

{{ th(t('租约式 leasing')) }}{{ th(t('作业式 job')) }}
{{ leasing_runs }} {{ job_runs }}
{% endblock %}