[pgpool-general: 123] Re: question of pgpool's behavior

Tatsuo Ishii ishii at postgresql.org
Wed Dec 28 11:47:06 JST 2011


It appeared that the bug was introduced in 3.0.3 and this bug has
affected 3.1 series as well.  More precisely, the bug was caused by
this commit:

http://git.postgresql.org/gitweb/?p=pgpool2.git;a=commit;h=ce1e89d2927b0367cf7cb4269493a1a408736d24

I believe Kitagawa has been working on this issue.
--
Tatsuo Ishii
SRA OSS, Inc. Japan
English: http://www.sraoss.co.jp/index_en.php
Japanese: http://www.sraoss.co.jp

>> Hi, all
>> 
>> I'm checking pgpool behavior and documented behavior.
>> Mainly, I run regression test included PostgreSQL 9.1.1.
>> I have some questions.
>> 
>> ===================================
>> 1. behavior about PREPARE statement
>> ===================================
>> 
>> When I execute PREPARE statement on standby PostgreSQL,
>> any response is not back to the client.
>> 
>> I've executed query espected becoming error like bellow.
>>   # PREPARE q4(nonexistenttype) AS select $1;
>> 
>> Is this same behavior with [pgpool-general: 99] bug ?
> 
> No. At least my patch did not solve the problem.
> 
> I did some random tests with various versions of pgpool-II and found
> that 3.0.0 is ok.  3.0.6 and 3.1.1 are not good. So it seems somewhere
> after 3.0.0, pgpool-II has been broken in this regard. Need more
> investigation...
> --
> Tatsuo Ishii
> SRA OSS, Inc. Japan
> English: http://www.sraoss.co.jp/index_en.php
> Japanese: http://www.sraoss.co.jp
> 
>> =============================================
>> 2. behavior about standard_conforming_strings
>> =============================================
>> 
>> When I execute escape strings via pgpool,
>> the result is difference from one executed on PostgreSQL.
>> before executing the query, I changed 'standard_conforming_strings'
>> parameter
>> to off.
>>   # SET standard_conforming_strings TO off;
>> 
>> this is the query.
>>   # select 'a\\bcd' as f1, 'a\\b\'cd' as f2, 'a\\b\'''cd' as f3, 'abcd\\'
>> as f4, 'ab\\\'cd' as f5, '\\\\' as f6;
>> 
>> ---------------------------------------------------------------------------------
>> testdb=# select 'a\\bcd' as f1, 'a\\b\'cd' as f2, 'a\\b\'''cd' as f3,
>> 'abcd\\'   as f4, 'ab\\\'cd' as f5, '\\\\' as f6;
>> WARNING:  nonstandard use of \\ in a string literal
>> LINE 1: select 'a\\bcd' as f1, 'a\\b\'cd' as f2, 'a\\b\'''cd' as f3,...
>>                ^
>> HINT:  Use the escape string syntax for backslashes, e.g., E'\\'.
>> WARNING:  nonstandard use of \\ in a string literal
>> LINE 1: select 'a\\bcd' as f1, 'a\\b\'cd' as f2, 'a\\b\'''cd' as f3,...
>>                                ^
>> HINT:  Use the escape string syntax for backslashes, e.g., E'\\'.
>> WARNING:  nonstandard use of \\ in a string literal
>> LINE 1: select 'a\\bcd' as f1, 'a\\b\'cd' as f2, 'a\\b\'''cd' as f3,...
>>                                                  ^
>> HINT:  Use the escape string syntax for backslashes, e.g., E'\\'.
>> WARNING:  nonstandard use of \\ in a string literal
>> LINE 1: ...bcd' as f1, 'a\\b\'cd' as f2, 'a\\b\'''cd' as f3, 'abcd\\'  ...
>>                                                              ^
>> HINT:  Use the escape string syntax for backslashes, e.g., E'\\'.
>> WARNING:  nonstandard use of \\ in a string literal
>> LINE 1: ...'cd' as f2, 'a\\b\'''cd' as f3, 'abcd\\'   as f4, 'ab\\\'cd'...
>>                                                              ^
>> HINT:  Use the escape string syntax for backslashes, e.g., E'\\'.
>> WARNING:  nonstandard use of \\ in a string literal
>> LINE 1: ...'''cd' as f3, 'abcd\\'   as f4, 'ab\\\'cd' as f5, '\\\\' as ...
>>                                                              ^
>> HINT:  Use the escape string syntax for backslashes, e.g., E'\\'.
>>   f1   |   f2   |   f3    |  f4   |   f5   | f6
>> -------+--------+---------+-------+--------+----
>>  a\bcd | a\b'cd | a\b''cd | abcd\ | ab\'cd | \\
>> (1 row)
>> ---------------------------------------------------------------------------------
>> 
>> via pgpool, the result is bellow.
>> 
>> ---------------------------------------------------------------------------------
>> testdb=# select 'a\\bcd' as f1, 'a\\b\'cd' as f2, 'a\\b\'''cd' as f3,
>> 'abcd\\'   as f4, 'ab\\\'cd' as f5, '\\\\' as f6;
>> Invalid command \. Try \? for help.
>> ---------------------------------------------------------------------------------
>> 
>> 
>> ========================================
>> 3. documentation about DECLARE statement
>> ========================================
>> current document says like bellow,
>> ----
>> These queries can be sent to both the primary node and the standby node.
>> If load balancing is enabled, these types of queries can be sent to the
>> standby node.
>> However, if delay_threshold is set and the replication delay is higher
>> than delay_threshold, queries are sent to the primary node.
>> 
>> SELECT not listed above
>> COPY TO
>> DECLARE, FETCH, CLOSE
>> SHOW
>> ----
>> 
>> on the other hand, "Release Note" in Japanese document says that
>> pgpool-II 2.2.6 had been changed NOT to do load balancing with
>> DECLARE, CLOSE, FETCH and MOVE statements.
>> 
>> 
>> which is rigth ?
>> 
>> 
>> regards,
>> -------------------
>> Tomonari Katsumata
> _______________________________________________
> pgpool-general mailing list
> pgpool-general at pgpool.net
> http://www.pgpool.net/mailman/listinfo/pgpool-general


More information about the pgpool-general mailing list