All Downloads are FREE. Search and download functionalities are using the official Maven repository.

ui.common.topicOnClusterStatus.ftl Maven / Gradle / Ivy

There is a newer version: 0.8.0
Show newest version
<#-- @ftlvariable name="topicOnClusterStatus" type="com.infobip.kafkistry.service.topic.TopicOnClusterInspectionResult" -->

<#import "../common/util.ftl" as util>

<#assign detailedStatuses = []>
<#list (topicOnClusterStatus.wrongValues)![] as wrongValue>
    <#assign detailedStatuses = detailedStatuses + [wrongValue.type]>

<#list (topicOnClusterStatus.updateValues)![] as updateValue>
    <#assign detailedStatuses = detailedStatuses + [updateValue.type]>

<#list (topicOnClusterStatus.ruleViolations)![] as ruleViolation>
    <#assign detailedStatuses = detailedStatuses + [ruleViolation.type]>

<#list (topicOnClusterStatus.currentConfigRuleViolations)![] as ruleViolation>
    <#assign detailedStatuses = detailedStatuses + [ruleViolation.type]>

<#list topicOnClusterStatus.typeDescriptions as typeDescription>
    <#assign detailedStatuses = detailedStatuses + [typeDescription.type]>


<#list topicOnClusterStatus.types as statusType>
    <#if !(detailedStatuses?seq_contains(statusType))>
        <@util.namedTypeStatusAlert type=statusType/>
    


<#assign alertInline = false>

<#macro valueAssertDetail valueAssertion>
    <#-- @ftlvariable name="valueAssertion" type="com.infobip.kafkistry.service.topic.WrongValueAssertion" -->
    <#assign statusType = valueAssertion.type>
    <@util.namedTypeStatusAlert type=statusType alertInline=false/>
    <#assign wrongStatusType = !statusType.valid>
    
What: "${valueAssertion.key}"
<#if wrongStatusType> Expected: <#else> New: <#if valueAssertion.expectedDefault> (to be default / not-overridden) <#else> ${valueAssertion.expected}
<#if wrongStatusType> Actual: <#else> Old: ${valueAssertion.actual} <#if valueAssertion.message??>
Message: ${valueAssertion.message}

<#if topicOnClusterStatus.wrongValues??> <#list topicOnClusterStatus.wrongValues as wrongValue> <#if wrongValue?is_first>
<@valueAssertDetail valueAssertion=wrongValue/> <#if topicOnClusterStatus.updateValues??> <#list topicOnClusterStatus.updateValues as updateValue> <#if updateValue?is_first>
<@valueAssertDetail valueAssertion=updateValue/> <#import "violaton.ftl" as violatonUtil> <#if topicOnClusterStatus.ruleViolations??> <#list topicOnClusterStatus.ruleViolations as ruleViolation> <@util.namedTypeStatusAlert type=ruleViolation.type alertInline=false/> <@violatonUtil.interpretMessage violation=ruleViolation.violation/>
<#if topicOnClusterStatus.currentConfigRuleViolations??> <#list topicOnClusterStatus.currentConfigRuleViolations as ruleViolation> <@util.namedTypeStatusAlert type=ruleViolation.type alertInline=false/> <@violatonUtil.interpretMessage violation=ruleViolation.violation/>
<#if topicOnClusterStatus.typeDescriptions?size gt 0> <#list topicOnClusterStatus.typeDescriptions as typeDescription> <@util.namedTypeStatusAlert type=typeDescription.type alertInline=false/> <@violatonUtil.richMessage message=typeDescription.message placeholders=typeDescription.placeholders/>




© 2015 - 2024 Weber Informatics LLC | Privacy Policy