Search Postgresql Archives

Re: schema advice for event stream with tagging and filtering

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On Tue, Aug 16, 2016 at 6:38 PM, Chris Withers <chris@xxxxxxxxxxxxxxxx> wrote:
Hi All,

What would be the best schema to use when looking to implement an event stream with tagging and filtering?

An event is a row with a primary key along the lines of (colo, host, category) and an associated set of tags, where each tag has a type and a value (eg: {"color": "red", "owner": "fred", "status": "open"...}).

Events come in as a streams of creates/updates as a cluster of http posts to a web app.

Not sure which version of PostgreSQL you are using. Did you consider JSON/JSONB data-types which is strongly supported by PostgreSQL ? You can consider having a table with JSON or JSONB column type. If you can use JSONB, then, it supports indexing as well.

That should make web app easy to push JSON format data to PostgreSQL.

Regards,
Venkata B N

Fujitsu Australia

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux