Note that there are some explanatory texts on larger screens.

plurals
  1. POwrite scaling postgresql
    primarykey
    data
    text
    <p>i have a very write centric application that uses postgres hstore. my typical work flow is a <code>SELECT</code> followed by a number of <code>UPDATE</code>s or <code>INSERT</code>s (mostly the former). This happens at typically around 500 'tasks' a second.</p> <p>so my single postgres instance just can't cope. i see that the postgres server is cpu bound and the postgres processes are <code>UPDATE</code>ing all the time. Disk I/O appears fine and i have plenty of memory free (44GB out of 48). i've tried tuning as per <a href="http://wiki.postgresql.org/wiki/Tuning_Your_PostgreSQL_Server" rel="nofollow">postgres's wiki page</a> and pg_tune, but i just need a bit more performance.</p> <p>my tables follow the following design:</p> <pre><code> Column | Type | Modifiers | Storage | Stats target | Description ------------+--------------------------+---------------------------------------------------------------------+----------+--------------+------------- id | integer | not null default nextval('table_id_seq'::regclass) | plain | | created_at | timestamp with time zone | not null | plain | | updated_at | timestamp with time zone | not null | plain | | context | hstore | default hstore((ARRAY[]::character varying[])::text[]) | extended | | data | hstore | default hstore((ARRAY[]::character varying[])::text[]) | extended | | </code></pre> <p>and nearly all of my <code>UPDATE</code>s are of the type:</p> <pre><code>UPDATE &lt;table&gt; updated_at=&lt;date&gt; WHERE id=&lt;id&gt; </code></pre> <p>upon digging, i've found two projects that claims to help with write performance:</p> <ul> <li><a href="http://postgres-xc.sourceforge.net/" rel="nofollow">postgres-xc</a></li> <li><a href="http://postgres-r.org/" rel="nofollow">postgres-r</a></li> </ul> <p>which would you recommend for my (rather simplistic) workflow?</p> <p>(and yes, i have tried mongo, however, i miss the query schematics of SQL)</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload