From: Ron <ronljohnsonjr@gmail.com>
To: pgsql-general@lists.postgresql.org
Subject: Re: Pulling data from Postgres DB table for every 5 seconds.
Date: Wed, 9 Jan 2019 11:16:21 -0600
Message-ID: <cdf20df7-a935-e3e4-3ca7-b71a7fc2018d@gmail.com> (raw)
In-Reply-To: <CACaZr5Ta1S_wXm-ZaA=2pQU+rsR_tzN5d4NWdju8JYxX-qNnEQ@mail.gmail.com>
References: <CACaZr5TQ6CuFe8tPSwNLA68ujTjT_=cCHhA0Nx0+9=BsNV4PYA@mail.gmail.com>
<CACaZr5Ta1S_wXm-ZaA=2pQU+rsR_tzN5d4NWdju8JYxX-qNnEQ@mail.gmail.com>
On 1/9/19 11:02 AM, github kran wrote:
>
>
> Hi Postgres Team,
>
> I have an application using RDS Aurora Postgresql 9.6 version having 4
> TB of DB size. In this DB we have a table PRODUCT_INFO with around 1
> million rows and table size of 1 GB.
> We are looking for a implementation where we want to pull the data in
> real time for every 5 seconds from the DB
>
"the data". All 1GB every 5 seconds?
> ( Table mentioned above) and send it to IOT topic whenever an event
> occurs for a product. ( event is any new product information or change
> in the existing
> product information.).
>
> This table has few DML operations in real time either INSERT or UPDATE
> based on the productId. ( Update whenever there is a change in the
> product information and INSERT when a record doesnt exists for that
> product).
>
> We have REST API's built in the backend pulling data from this backend
> RDS Aurora POSTGRES DB and used by clients.
>
> *_UseCase_*
> We dont want clients to pull the data for every 5 seconds from DB but
> rather provide a service which can fetch the data from DB in real time
> and push the data to IOT topic by pulling data for every 5 seconds
> from DB.
>
Or just a tiny subset every 5 seconds?
>
> *_Questions_*
> 1) How can I get information by pulling from the DB every 5 seconds
> without impacting the performance of the DB.
> 2) What are the options I have pulling the data from this table every
> 5 seconds. Does POSTGRES has any other options apart from TRIGGER ?.
>
>
> Any ideas would be helpful.
>
> Thanks !!
> GithubKran
>
--
Angular momentum makes the world go 'round.
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-general@postgresql.org
Cc: ronljohnsonjr@gmail.com
Subject: Re: Pulling data from Postgres DB table for every 5 seconds.
In-Reply-To: <cdf20df7-a935-e3e4-3ca7-b71a7fc2018d@gmail.com>
References: <CACaZr5TQ6CuFe8tPSwNLA68ujTjT_=cCHhA0Nx0+9=BsNV4PYA@mail.gmail.com> <CACaZr5Ta1S_wXm-ZaA=2pQU+rsR_tzN5d4NWdju8JYxX-qNnEQ@mail.gmail.com> <cdf20df7-a935-e3e4-3ca7-b71a7fc2018d@gmail.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox