Re: Is it possible to direct pgadm4 installer to use the /var folder within postrgres GUIX System Home folder?

2022-08-03 Thread Aditya Toshniwal
Hi Periklis,

Please checkout https://www.pgadmin.org/docs/pgadmin4/6.12/config_py.html
You can configure:
DATA_DIR
LOG_FILE
SQLITE_PATH
SESSION_DB_PATH
STORAGE_DIR

On Thu, Aug 4, 2022 at 7:14 AM Periklis F. Didaskalou 
wrote:

> Hello,
>
> I'm wondering if anyone else is using pgadmin on a Guix System machine.
>
> I managed to edit the postgresql config file to point to a /var folder
> within posgres's account.
>
> Now I'd like to do the same with pgadmin4's need of /var/lib and /var/log
> under that local /var folder in postgres's Home folder.
>
> I must admit I didn't dig very much through the pgadmin documentation. I
> just searched for /var/lib and /var/log.
>
> Guix System doesn't allow even root to add/alter anything under root level
> /var.  You can, and it'll persist, but only until the
> next reboot. Fortunately Guix System allowed me to mount a second 4TB
> drive for postgres; which does persist.
>
> I'm trying here first before asking within a Guix System list.
>
> Peri/Periklis
>


-- 
Thanks,
Aditya Toshniwal
pgAdmin Hacker | Software Architect | *edbpostgres.com*

"Don't Complain about Heat, Plant a TREE"


Is it possible to direct pgadm4 installer to use the /var folder within postrgres GUIX System Home folder?

2022-08-03 Thread Periklis F. Didaskalou

Hello,

I'm wondering if anyone else is using pgadmin on a Guix System machine.

I managed to edit the postgresql config file to point to a /var folder 
within posgres's account.


Now I'd like to do the same with pgadmin4's need of /var/lib and 
/var/log under that local /var folder in postgres's Home folder.


I must admit I didn't dig very much through the pgadmin documentation. I 
just searched for /var/lib and /var/log.


Guix System doesn't allow even root to add/alter anything under root 
level /var.  You can, and it'll persist, but only until the
next reboot. Fortunately Guix System allowed me to mount a second 4TB 
drive for postgres; which does persist.


I'm trying here first before asking within a Guix System list.

Peri/Periklis

Content assist / autocomplete hangs the server (latest pgAdmin version)

2022-08-03 Thread Cherio
I had to examine certain aspects of a query that looks like this:

SELECT COUNT(*)
FROM schema.table
WHERE id IN (
'1',
'2',
'3',

'19998',
'1',
'2'
)

I pasted the query and autocomplete kicked in. For a minute it froze
entirely. Then it sort of let me do things but everything was like in slow
motion: the tree browser, the other SQL tabs - everything became slow as
molasses. I logged onto the server and the "pgAdmin4.py" was
keeping the CPU quite busy. It didn't recover for some time so I simply
restarted the server and switched autocomplete to manual.

Not knowing the design I may not be able to make a viable suggestion but
maybe some sort of complexity counter (configurable or at least hard-coded
at first) should be considered, which would hint to the autocomplete to
stop trying, after it realizes the task may be too complex or takes too
long to complete.

Sure, a query like the one above should probably make use of a temporary
table but it is beyond the point - there has to be a safeguard against an
overloaded autocomplete. Without such a safeguard an ugly/invalid query or
a user error could kill the server for all connected pgadmin clients.

>