Re: PGAdmin4 2.1 OSX bloat

From: Khushboo Vashi <khushboo(dot)vashi(at)enterprisedb(dot)com>
To: Darren Duncan <darren(at)darrenduncan(dot)net>
Cc: pgAdmin Support <pgadmin-support(at)postgresql(dot)org>
Subject: Re: PGAdmin4 2.1 OSX bloat
Date: 2018-02-22 10:10:47
Message-ID: CAFOhELcoHtJmAeqwSOz8bFSFjrGKxK8bJUxwMHEbJNau=Gja7A@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgadmin-support

On Thu, Feb 22, 2018 at 11:01 AM, Darren Duncan <darren(at)darrenduncan(dot)net>
wrote:

> As for where all that bloat is going, I took a minute of digging and found
> something interesting.
>
> /Volumes/pgAdmin\ 4/pgAdmin\ 4.app/Contents/Resources/web/p
> gadmin/static/js/generated/.cache/hard-source
>
> This one, single, "invisible" .cache directory in the application bundle
> is about 300MB by itself, or half of the total .app size.
>
> I suspect this is the most egregious thing, assuming that folder only is
> either needed at development or packaging time or can be generated by
> PgAdmin at runtime.
>
>

The pgAdmin 4 uses webpack hardSourceWebpackPlugin which caches the
optimised javascripts in the .cache directory, and those will be used from
the .cache directory during rebundling of webpack module, so that only the
changed files will be processed on the next build in the development
environment, and rest of the files are being picked up from the cached
directory which makes the rebundling fast. But this is only helpful in the
development environment, so the patch to fix this already sent to the
pgadmin-hackers (Patch:
https://www.postgresql.org/message-id/CAFOhELfmrfwqBf9dpYkJJOoKFdLi%2BictCEeBthdxBDNp_mqP-g%40mail.gmail.com
).

-- Darren Duncan
>
>
> On 2018-02-21 9:23 PM, Darren Duncan wrote:
>
>> On 2018-02-21 8:54 PM, fahar wrote:
>>
>>> The application size of pgAdmin4 is 184.5MB on MAC 10.13 machine and it's
>>> not reproducible, can you please share the exact steps so we can find the
>>> actual root-cause of this behavior.
>>>
>>
>> I completely verify what iPeel said.
>>
>> A PgAdmin4 2.0 OSX is 403.4MB and version 2.1 is 620.1MB in size.
>>
>> Reproduction is trivially easy.
>>
>> 1. Just go to https://www.postgresql.org/ftp/pgadmin/pgadmin4/v2.1/macos/
>> and download the disk image file pgadmin4-2.1.dmg whose COMPRESSED size is
>> 234.1MB (223.3MiB).
>>
>> 2. Open the disk image file and select the application bundle "pgAdmin
>> 4.app" and Get Info its size, which shows 621.1MB.
>>
>> I'm using Mac OS 10.12 Sierra.
>>
>> Perhaps the PgAdmin application proper is about 184MB as you said, in
>> which case it may be the combined size of that plus shared libraries or
>> runtimes included in the application bundle total the 600, but for any
>> normal user the combined size of the .app is what matters, its what they
>> are actually copying and taking up space.
>>
>> If you think the .app is only 184.5MB, then I would ask where you got
>> yours from, surely not the official url above.
>>
>> -- Darren Duncan
>>
>>
>>
>
>

In response to

Responses

Browse pgadmin-support by date

  From Date Subject
Next Message iPeel 2018-02-22 10:12:35 Re: PGAdmin4 2.1 OSX Query Tool - messages delayed by one execution
Previous Message Khushboo Vashi 2018-02-22 09:52:19 Re: PGAdmin4 2.1 OSX Query Tool - messages delayed by one execution