Обсуждение: SVN Commit by dpage: r7544 - in trunk/pgadmin3: . pgadmin/frm pgadmin/include/utils pgadmin/ui

Поиск
Список
Период
Сортировка

SVN Commit by dpage: r7544 - in trunk/pgadmin3: . pgadmin/frm pgadmin/include/utils pgadmin/ui

От
svn@pgadmin.org
Дата:
Author: dpage

Date: 2009-01-09 21:37:04 +0000 (Fri, 09 Jan 2009)

New Revision: 7544

Revision summary: http://svn.pgadmin.org/cgi-bin/viewcvs.cgi/?rev=7544&view=rev

Log:
Add an option to ignore server version mismatches with pg_dump/pg_dumpall/pg_restore.


Modified:
   trunk/pgadmin3/CHANGELOG
   trunk/pgadmin3/pgadmin/frm/frmBackup.cpp
   trunk/pgadmin3/pgadmin/frm/frmBackupGlobals.cpp
   trunk/pgadmin3/pgadmin/frm/frmBackupServer.cpp
   trunk/pgadmin3/pgadmin/frm/frmOptions.cpp
   trunk/pgadmin3/pgadmin/frm/frmRestore.cpp
   trunk/pgadmin3/pgadmin/include/utils/sysSettings.h
   trunk/pgadmin3/pgadmin/ui/frmOptions.xrc
   trunk/pgadmin3/pgadmin/ui/xrcDialogs.cpp

Re: SVN Commit by dpage: r7544 - in trunk/pgadmin3: . pgadmin/frm pgadmin/include/utils pgadmin/ui

От
Quan Zongliang
Дата:
> Add an option to ignore server version mismatches with pg_dump/pg_dumpall/pg_restore.

Why don't add this option to backup and restore dialogs?
And use option in frmOptions as default value.
I think it will make end users feel more convenient and more happy. ^_^

Along with this topic,
I had tried to use old-version pgadmin (1.6.3) connect to newer db (8.3 & 8.4).
When click the schema node, get a error message complain
column op.oprlsortop does not exist (maybe its name changed in newer version).
Now, we have BackendMinimumVersion function to confirm backward-compatible.
Clearly, it is needed that confirm forward-compatible.
We can give a upper limit version to individual pgadmin version.
When end users wanna connect to newer db, they will get a warning message or hint.

-----------------------------------------------
Quan Zongliang
quanzongliang@gmail.com
CIT Japan:  http://www.cit.co.jp
CIT China:  http://www.citbj.com.cn


Re: SVN Commit by dpage: r7544 - in trunk/pgadmin3: . pgadmin/frm pgadmin/include/utils pgadmin/ui

От
"Dave Page"
Дата:
On Sat, Jan 10, 2009 at 2:52 AM, Quan Zongliang <quanzongliang@gmail.com> wrote:
>> Add an option to ignore server version mismatches with pg_dump/pg_dumpall/pg_restore.
>
> Why don't add this option to backup and restore dialogs?
> And use option in frmOptions as default value.
> I think it will make end users feel more convenient and more happy. ^_^

I don't want it to be too 'in your face'. It's an option that
generally shouldn't be used as it's potentially dangerous. That said,
perhaps it would make more sense to include on each dialogue, but
always defaulting to 'off' so the user is forced to select it every
time.

Unfortunately that would mean some redesigning of those 4 dialogues
which I don't really have the spare cycles for.

> Along with this topic,
> I had tried to use old-version pgadmin (1.6.3) connect to newer db (8.3 & 8.4).
> When click the schema node, get a error message complain
> column op.oprlsortop does not exist (maybe its name changed in newer version).
> Now, we have BackendMinimumVersion function to confirm backward-compatible.
> Clearly, it is needed that confirm forward-compatible.
> We can give a upper limit version to individual pgadmin version.
> When end users wanna connect to newer db, they will get a warning message or hint.

Good idea. I think a warning is fine - we shouldn't prevent operation entirely.

Can you work up a patch?

--
Dave Page
EnterpriseDB UK:   http://www.enterprisedb.com

Re: SVN Commit by dpage: r7544 - in trunk/pgadmin3: . pgadmin/frm pgadmin/include/utils pgadmin/ui

От
Quan Zongliang
Дата:
> Good idea. I think a warning is fine - we shouldn't prevent operation entirely.
>
> Can you work up a patch?

Now, const float SERVER_MIN_VERSION = 7.3f; is defined in pgAdmin3.h.
Add a new variable SERVER_MAX_VERSION here.
When end-users try to connect to db, check the version.
If it is newer, display a warning dialog.
Then the end-users click <OK> button to continue.

Ok?

-----------------------------------------------
Quan Zongliang
quanzongliang@gmail.com
CIT Japan:  http://www.cit.co.jp
CIT China:  http://www.citbj.com.cn


Re: SVN Commit by dpage: r7544 - in trunk/pgadmin3: . pgadmin/frm pgadmin/include/utils pgadmin/ui

От
"Dave Page"
Дата:
On Mon, Jan 12, 2009 at 11:13 AM, Quan Zongliang
<quanzongliang@gmail.com> wrote:
>> Good idea. I think a warning is fine - we shouldn't prevent operation entirely.
>>
>> Can you work up a patch?
>
> Now, const float SERVER_MIN_VERSION = 7.3f; is defined in pgAdmin3.h.
> Add a new variable SERVER_MAX_VERSION here.
> When end-users try to connect to db, check the version.
> If it is newer, display a warning dialog.
> Then the end-users click <OK> button to continue.
>
> Ok?

Sounds good to me.

--
Dave Page
EnterpriseDB UK:   http://www.enterprisedb.com

Re: SVN Commit by dpage: r7544 - in trunk/pgadmin3: . pgadmin/frm pgadmin/include/utils pgadmin/ui

От
Quan Zongliang
Дата:
> > Now, const float SERVER_MIN_VERSION = 7.3f; is defined in pgAdmin3.h.
> > Add a new variable SERVER_MAX_VERSION here.
> > When end-users try to connect to db, check the version.
> > If it is newer, display a warning dialog.
> > Then the end-users click <OK> button to continue.

I think again. It's really not a good idea.
Another option is needed. Otherwise, when end users connect to db
with an older version pgAdmin. They will get message box always,
but the pgAdmin maybe work fine. This must make them very angry.

Add a new option like "Don't check database version."?

-----------------------------------------------
Quan Zongliang
quanzongliang@gmail.com
CIT Japan:  http://www.cit.co.jp
CIT China:  http://www.citbj.com.cn


Re: SVN Commit by dpage: r7544 - in trunk/pgadmin3: . pgadmin/frm pgadmin/include/utils pgadmin/ui

От
Guillaume Lelarge
Дата:
Quan Zongliang a écrit :
>>> Now, const float SERVER_MIN_VERSION = 7.3f; is defined in pgAdmin3.h.
>>> Add a new variable SERVER_MAX_VERSION here.
>>> When end-users try to connect to db, check the version.
>>> If it is newer, display a warning dialog.
>>> Then the end-users click <OK> button to continue.
>
> I think again. It's really not a good idea.
> Another option is needed. Otherwise, when end users connect to db
> with an older version pgAdmin. They will get message box always,
> but the pgAdmin maybe work fine. This must make them very angry.
>
> Add a new option like "Don't check database version."?
>

I don't think so. pgAdmin should display the warning box only if they
try to backup/restore, and not at startup time.


--
Guillaume.
 http://www.postgresqlfr.org
 http://dalibo.com

Re: SVN Commit by dpage: r7544 - in trunk/pgadmin3: . pgadmin/frm pgadmin/include/utils pgadmin/ui

От
"Dave Page"
Дата:
On Mon, Jan 12, 2009 at 12:53 PM, Quan Zongliang
<quanzongliang@gmail.com> wrote:
>> > Now, const float SERVER_MIN_VERSION = 7.3f; is defined in pgAdmin3.h.
>> > Add a new variable SERVER_MAX_VERSION here.
>> > When end-users try to connect to db, check the version.
>> > If it is newer, display a warning dialog.
>> > Then the end-users click <OK> button to continue.
>
> I think again. It's really not a good idea.
> Another option is needed. Otherwise, when end users connect to db
> with an older version pgAdmin. They will get message box always,
> but the pgAdmin maybe work fine. This must make them very angry.

We always release pgAdmin before PostgreSQL anyway, so there is no
reason not to upgrade.

If you want to create a new type of message box with a 'don't show
this again' checkbox, I won't object though.

--
Dave Page
EnterpriseDB UK:   http://www.enterprisedb.com

Re: SVN Commit by dpage: r7544 - in trunk/pgadmin3: . pgadmin/frm pgadmin/include/utils pgadmin/ui

От
Quan Zongliang
Дата:
> If you want to create a new type of message box with a 'don't show
> this again' checkbox, I won't object though.

Ok, study the source and try to modify it.

-----------------------------------------------
Quan Zongliang
quanzongliang@gmail.com
CIT Japan:  http://www.cit.co.jp
CIT China:  http://www.citbj.com.cn