[pgpool-general: 803] Re: relcache_size in pgpool-II 3.2RC1

Tatsuo Ishii ishii at postgresql.org
Wed Jul 25 08:29:49 JST 2012


> Thank you very much for the patchs.
> I have installed the patch and the problem seems be solved, because I do not see the message "pool_search_relcache: cache replacement happend" anymore.

Great.

> Another problem with memory query cache. I have installed the patch and the problem with the comments in from of the queries was solved but the queries inside and explicit transaction are not catched.
> 
> This code was developed in java and may reproduce this behavior:

If your query does not include the SQL comment, is the query cached?
--
Tatsuo Ishii
SRA OSS, Inc. Japan
English: http://www.sraoss.co.jp/index_en.php
Japanese: http://www.sraoss.co.jp

> **********************************************************************
> 
> import java.sql.Connection;
> import java.sql.DriverManager;
> import java.sql.ResultSet;
> import java.sql.SQLException;
> import java.sql.Statement;
> import java.util.Properties;
> import java.util.logging.Level;
> import java.util.logging.Logger;
> 
> public class JavaApplication1 {
> 
>     public static void selectJDBC() throws SQLException, ClassNotFoundException {
>         Class.forName("org.postgresql.Driver");
>         Properties properties = new Properties();
>         properties.setProperty("user", "desarrollo");
>         properties.setProperty("password", "desarrollo");
>         for (int i = 0; i < 100; i++) {
>             Connection connection = DriverManager.getConnection("jdbc:postgresql://10.13.8.206:9999/prueba", properties);
>             Statement statement = connection.createStatement();
>             statement.execute("BEGIN;");
>             ResultSet resultSet = statement.executeQuery("/* criteria query */ select this_.id as id0_0_, this_.nombre as nombre0_0_ from public.persona this_");
>             while (resultSet.next()) {
>                 System.out.println(resultSet.getString(1) + " " + resultSet.getString(2));
>             }
>             statement.execute("COMMIT;");
>             connection.close();
>         }
>     }
>     public static void main(String[] args) {
>         try {
>             selectJDBC();
>         } catch (SQLException ex) {
>             Logger.getLogger(JavaApplication1.class.getName()).log(Level.SEVERE, null, ex);
>         } catch (ClassNotFoundException ex) {
>             Logger.getLogger(JavaApplication1.class.getName()).log(Level.SEVERE, null, ex);
>         }
>     }
> }
> 
> **********************************************************************
> 
> Regards
> 
> ________________________________________
> From: Tatsuo Ishii [ishii at postgresql.org]
> Sent: Tuesday, July 24, 2012 4:21 AM
> To: Lazáro Rubén García Martínez
> Cc: pgpool-general at pgpool.net
> Subject: Re: [pgpool-general: 799] Re: relcache_size in pgpool-II 3.2RC1
> 
>>> Tatsuo, attached are the pgpool.log and pgpool.conf file.
>>
>> Thanks. Will look into this.
> 
> It appeared that there was a "false alarm" of "pool_search_relcache:
> cache replacement happend". Please apply included patch. If you still
> see the message, please let me know and send me pgpool log.
> --
> Tatsuo Ishii
> SRA OSS, Inc. Japan
> English: http://www.sraoss.co.jp/index_en.php
> Japanese: http://www.sraoss.co.jp
> 
>>> Did you see the last mail related with on memory query cache, and the wrong behavior when a comment is writen in from of the query?
>>
>> Yes, and Nozomi Anzai is on working on this.
>> --
>> Tatsuo Ishii
>> SRA OSS, Inc. Japan
>> English: http://www.sraoss.co.jp/index_en.php
>> Japanese: http://www.sraoss.co.jp
>>
>>> Regards.
>>>
>>> ________________________________________
>>> From: Tatsuo Ishii [ishii at postgresql.org]
>>> Sent: Monday, July 23, 2012 5:43 PM
>>> To: Lazáro Rubén García Martínez
>>> Cc: pgpool-general at pgpool.net
>>> Subject: Re: [pgpool-general: 792] relcache_size in pgpool-II 3.2RC1
>>>
>>> Ca you show me the pgpool log which log_per_node_statement enabled?  I
>>> need full log, from the point when client connects, to the timing when
>>> "pool_search_relcache: cache replacement happend".
>>> --
>>> Tatsuo Ishii
>>> SRA OSS, Inc. Japan
>>> English: http://www.sraoss.co.jp/index_en.php
>>> Japanese: http://www.sraoss.co.jp
>>>
>>>> The problem is that I have incremented this value to high (3000) however in the log file this messages persists.
>>>>
>>>> "pool_search_relcache: cache replacement happend"
>>>>
>>>> Regards.
>>>> ________________________________________
>>>> From: Tatsuo Ishii [ishii at postgresql.org]
>>>> Sent: Sunday, July 22, 2012 11:36 PM
>>>> To: Lazáro Rubén García Martínez
>>>> Cc: pgpool-general at pgpool.net
>>>> Subject: Re: [pgpool-general: 792] relcache_size in pgpool-II 3.2RC1
>>>>
>>>>> Hello everyone in the list.
>>>>>
>>>>> Is there any method for configuring the property relcache_size? How can I determinate this value?
>>>>
>>>>>From pgpool.conf.sample:
>>>>
>>>> relcache_size = 256
>>>>                                    # Number of relation cache
>>>>                                    # entry. If you see frequently:
>>>>                                    # "pool_search_relcache: cache replacement happend"
>>>>                                    # in the pgpool log, you might want to increate this number.
>>>>
>>>> So you should check out the log message in pgpool.log.
>>>> --
>>>> Tatsuo Ishii
>>>> SRA OSS, Inc. Japan
>>>> English: http://www.sraoss.co.jp/index_en.php
>>>> Japanese: http://www.sraoss.co.jp
>>>>
>>>> Fin a la injusticia, LIBERTAD AHORA A NUESTROS CINCO COMPATRIOTAS QUE SE ENCUENTRAN INJUSTAMENTE EN PRISIONES DE LOS EEUU!
>>>> http://www.antiterroristas.cu
>>>> http://justiciaparaloscinco.wordpress.com
>>>>
>>>> Fin a la injusticia, LIBERTAD AHORA A NUESTROS CINCO COMPATRIOTAS QUE SE ENCUENTRAN INJUSTAMENTE EN PRISIONES DE LOS EEUU!
>>>> http://www.antiterroristas.cu
>>>> http://justiciaparaloscinco.wordpress.com
>>>
>>> Fin a la injusticia, LIBERTAD AHORA A NUESTROS CINCO COMPATRIOTAS QUE SE ENCUENTRAN INJUSTAMENTE EN PRISIONES DE LOS EEUU!
>>> http://www.antiterroristas.cu
>>> http://justiciaparaloscinco.wordpress.com
>>>
>>> Fin a la injusticia, LIBERTAD AHORA A NUESTROS CINCO COMPATRIOTAS QUE SE ENCUENTRAN INJUSTAMENTE EN PRISIONES DE LOS EEUU!
>>> http://www.antiterroristas.cu
>>> http://justiciaparaloscinco.wordpress.com
>> _______________________________________________
>> pgpool-general mailing list
>> pgpool-general at pgpool.net
>> http://www.pgpool.net/mailman/listinfo/pgpool-general
> 
> Fin a la injusticia, LIBERTAD AHORA A NUESTROS CINCO COMPATRIOTAS QUE SE ENCUENTRAN INJUSTAMENTE EN PRISIONES DE LOS EEUU!
> http://www.antiterroristas.cu
> http://justiciaparaloscinco.wordpress.com
> 
> Fin a la injusticia, LIBERTAD AHORA A NUESTROS CINCO COMPATRIOTAS QUE SE ENCUENTRAN INJUSTAMENTE EN PRISIONES DE LOS EEUU!
> http://www.antiterroristas.cu
> http://justiciaparaloscinco.wordpress.com


More information about the pgpool-general mailing list