You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by lh...@apache.org on 2024/04/04 07:46:26 UTC

(pulsar-manager) branch master updated: Create Index on topics_stats to fix tenants tab latency (#420)

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

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


The following commit(s) were added to refs/heads/master by this push:
     new 672863e  Create Index on topics_stats to fix tenants tab latency (#420)
672863e is described below

commit 672863e1a8cdbfc9b392e1b676b48507cd9f6d9d
Author: Sourabh Agrawal <so...@nutanix.com>
AuthorDate: Thu Apr 4 13:16:20 2024 +0530

    Create Index on topics_stats to fix tenants tab latency (#420)
    
    * Create Index on topics_stats to fix tenants tab latency
    
    * Trigger Build
---
 src/main/resources/META-INF/sql/postgresql-schema.sql | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/src/main/resources/META-INF/sql/postgresql-schema.sql b/src/main/resources/META-INF/sql/postgresql-schema.sql
index 40d1d32..3376023 100644
--- a/src/main/resources/META-INF/sql/postgresql-schema.sql
+++ b/src/main/resources/META-INF/sql/postgresql-schema.sql
@@ -46,6 +46,8 @@ CREATE TABLE IF NOT EXISTS topics_stats (
   time_stamp BIGINT
 );
 
+CREATE INDEX IF NOT EXISTS ix_topics_stats_timestamp on topics_stats(time_stamp);
+
 CREATE TABLE IF NOT EXISTS publishers_stats (
   publisher_stats_id BIGSERIAL PRIMARY KEY,
   producer_id BIGINT,