You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by si...@apache.org on 2019/06/30 11:59:34 UTC

[pulsar] branch master updated: Dashboard filter out old namespace data from home screen (#4597)

This is an automated email from the ASF dual-hosted git repository.

sijie pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/pulsar.git


The following commit(s) were added to refs/heads/master by this push:
     new cc022f1  Dashboard filter out old namespace data from home screen (#4597)
cc022f1 is described below

commit cc022f1691d23eebecd9fdfc3a2437d26dbbc208
Author: rshermanTHG <48...@users.noreply.github.com>
AuthorDate: Sun Jun 30 12:59:29 2019 +0100

    Dashboard filter out old namespace data from home screen (#4597)
    
    ### Motivation
    
    Duplicate namespace information was being shown in the home page e.g. Number of namespaces in a tenant.
    
    ### Modifications
    
    On the home screen filter to include data only from namespaces with the current timestamp.
---
 dashboard/django/stats/views.py | 1 +
 1 file changed, 1 insertion(+)

diff --git a/dashboard/django/stats/views.py b/dashboard/django/stats/views.py
index fe6011b..b49994b 100644
--- a/dashboard/django/stats/views.py
+++ b/dashboard/django/stats/views.py
@@ -48,6 +48,7 @@ def home(request):
             numNamespaces = Subquery(
                 Namespace.objects.filter(
                     deleted=False,
+                    timestamp=ts,
                     property=OuterRef('pk')
                 ).values('property')
                     .annotate(cnt=Count('pk'))