[pgpool-hackers: 367] Re: Auto-learning database-modifying functions

Bruce Momjian bruce at momjian.us
Thu Oct 3 05:34:19 JST 2013


On Thu, Sep 12, 2013 at 09:38:00AM +0900, Tatsuo Ishii wrote:
> > On Wed, Sep 11, 2013 at 08:31:30PM +0500, Ahsan Hadi wrote:
> >>     > I know you can specify a pattern to identify database-modifying
> >>     > functions, but I am wondering if you could send queries containing
> >>     > questionable functions to the read-only server, and if you get a
> >>     > read-only error, then send them to the write server.  A more interesting
> 
> I think the "resend the failed query to master server if read-only
> fails because of read-only error" part is pretty hard to implement if
> user started an explicit transaction. To rery the query, you need to
> remenber which as been succeeded and which result packets are already
> sent to the user. I think the work to implement it is not worth the
> gain.

This would be used only for queries not in transaction blocks.

-- 
  Bruce Momjian  <bruce at momjian.us>        http://momjian.us
  EnterpriseDB                             http://enterprisedb.com

  + It's impossible for everything to be true. +


More information about the pgpool-hackers mailing list