@@ -1633,6 +1633,15 @@ function Cluster() {
16331633 }
16341634 }
16351635
1636+ function showInstanceTags ( instance ) {
1637+ if ( instance . hasOwnProperty ( 'tagStrings' ) && instance . tagStrings . length ) {
1638+ var tagsText = "" ;
1639+ instance . tagStrings . forEach ( function ( tag ) {
1640+ tagsText = tagsText . concat ( tag , ' ' ) ;
1641+ } ) ;
1642+ getInstanceDiv ( instance . id ) . find ( "h3 div.pull-right" ) . prepend ( '<span class="glyphicon glyphicon-tags" title="' + tagsText + '"></span> ' ) ;
1643+ }
1644+ }
16361645
16371646 function indicateClusterPoolInstances ( clusterPoolInstances ) {
16381647 var instancesMap = _instancesMap ;
@@ -1673,10 +1682,19 @@ function Cluster() {
16731682
16741683 reviewReplicationAnalysis ( replicationAnalysis ) ;
16751684
1685+ // Tags are displayed only for not aggregated instances
1686+ for ( var instanceId in _instancesMap ) {
1687+ let instance = _instancesMap [ instanceId ] ;
1688+ getData ( "/api/tags/" + instance . Key . Hostname + "/" + instance . Key . Port , function ( tagStrings ) {
1689+ instance . tagStrings = tagStrings ;
1690+ showInstanceTags ( instance )
1691+ } ) ;
1692+ }
1693+
16761694 instances . forEach ( function ( instance ) {
16771695 if ( instance . isMaster ) {
16781696 getData ( "/api/recently-active-instance-recovery/" + instance . Key . Hostname + "/" + instance . Key . Port , function ( recoveries ) {
1679- if ( ! recoveries ) {
1697+ if ( ! recoveries || ! recoveries . length ) {
16801698 return
16811699 }
16821700 // Result is an array: either empty (no active recovery) or with multiple entries
@@ -1767,7 +1785,7 @@ function Cluster() {
17671785 } ) ;
17681786 } ) ;
17691787 getData ( "/api/recently-active-cluster-recovery/" + currentClusterName ( ) , function ( recoveries ) {
1770- if ( ! recoveries ) {
1788+ if ( ! recoveries || ! recoveries . length ) {
17711789 return
17721790 }
17731791 // Result is an array: either empty (no active recovery) or with multiple entries
0 commit comments