[pgpool-hackers: 4342] Re: Proposal: Add user_redirect_preference_list

Tatsuo Ishii ishii at sraoss.co.jp
Tue May 23 19:23:25 JST 2023


> Yes. I know the setting of app_name takes precedence if both of database and app_name are matched.
> 
> If we set:
> 
>   database_redirect_preference_list = 'test1:standby'
>   app_name_redirect_preference_list = 'app1:primary'
> 
> The following query will be sent to primary because the query matched both conditions
> and app_name takes precedence
> 
>     PGAPPNAME=app1 psql -d test1 -c "select 1"
> 
> However, users can configure the behavior of both database and app_name at the same time.
> 
> For example, the following query will be sent to standby,
> 
>     PGAPPNAME=app2 psql -d test1 -c "select 1"
> 
> and the following query will be sent to primary.
> 
>     PGAPPNAME=app1 psql -d test2 -c "select 1"
> 
> 
> I agree to unify the three settings of database, app_name and user,
> but we should mention that user can't set them at the same time.

I see your point. Maybe my idea (unifying *redirect_preference_list)
is not so good in terms of backward compatibility? If so, we should
give up the idea and just add
"user_name_redirect_preference_list". What do you think?

Best reagards,
--
Tatsuo Ishii
SRA OSS LLC
English: http://www.sraoss.co.jp/index_en/
Japanese:http://www.sraoss.co.jp


More information about the pgpool-hackers mailing list