pg.ddx.io  pgsql-jdbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: John R Pierce <pierce@hogranch.com>
To: Oliver Jowett <oliver@opencloud.com>
Cc: pgsql-jdbc@postgresql.org
Subject: Re: Connection.setReadOnly()
Date: Thu, 10 Dec 2009 17:54:09 -0800
Message-ID: <4B21A641.9030409@hogranch.com> (raw)
In-Reply-To: <4B219FAE.6070100@opencloud.com>
References: <4B21737B.50009@hogranch.com>
	<alpine.BSO.2.00.0912101744080.30821@leary.csoft.net>
	<4B219025.5070607@hogranch.com>
	<4B219FAE.6070100@opencloud.com>

Oliver Jowett wrote:
> John R Pierce wrote:
>   
>> we have a fairly large database thats fed a
>> constant stream of realtime data 24/7 from a factory doing both inserts
>> and updates...    many different sorts of things have to query this
>> database, including mechanical/electrical engineering types doing adhoc
>> queries for oddball reports and such who are not SQL experts.   its way
>> to easy for them to accidentally create a transaction that they never
>> end, causing multiday blockage of VACUUM, massive table bloat, etc.
>>     
>
> Presumably they could also run a query that accidentally consumes all
> the CPU and I/O bandwidth on your server (hello missing WHERE clause!)
>   

on the typical server we use with 8 or 16 or more processors, and lots 
of fiberchannel bandwidth for storage, they can at most bung up a single 
core and some fraction of the total disk IO demand.   the administrators 
are fairly used to run away reporting queries in the oracle space, and 
will kill them off without hesitation if they are impacting operational 
transactions..

> It sounds like what you need is an intermediate layer that enforces
> transaction and query timeouts, rather than giving your mech/eng types
> direct access to the DB.
>   

thats kind of hard to do well when you need totally off the wall adhoc 
queries to answer complex engineering questions.    on our larger scale 
systems we have a seperate dedicated database for reporting queries that 
runs on its own hardware, but this postgres system is meant to be a 
lower-cost version for a smaller/simpler operation, so the array of 
several back end servers we have traditionally used have all been folded 
onto this one server (currently the production evaluation server is on 
an 8 core Sun v490 with 16GB ram etc).





view thread (17+ messages)  latest in thread

Message-ID: <4B21A641.9030409@hogranch.com>
Permalink:  ../4B21A641.9030409@hogranch.com/
Also on:    postgresql.org/message-id/4B21A641.9030409@hogranch.com

 · 

reply

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-jdbc@postgresql.org
  Cc: pierce@hogranch.com, oliver@opencloud.com
  Subject: Re: Connection.setReadOnly()
  In-Reply-To: <4B21A641.9030409@hogranch.com>
  References: <4B21737B.50009@hogranch.com> <alpine.BSO.2.00.0912101744080.30821@leary.csoft.net> <4B219025.5070607@hogranch.com> <4B219FAE.6070100@opencloud.com> <4B21A641.9030409@hogranch.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