[Laszlo-dev] For Review: Change 20080919-dda-I Summary: Create tools to track file size improvements

Donald Anderson dda at ddanderson.com
Fri Sep 19 11:56:05 PDT 2008


Thanks, I updated the comment in test/appsize/readme.txt so that  
others can find
this info.  (That file is referred to from the top level build.xml)

On Sep 19, 2008, at 2:46 PM, Philip Romanik wrote:

> Hi Don,
>
> Yes, that's it. I needed to specify compression="on" as well. I  
> added the following to my <Connector... />
>
>          compression="on"
>          compressionMinSize="2048"
>          compressableMimeType="application/xml,text/html,text/ 
> xml,text/javascript,application/x-javascript,application/ 
> javascript,application/x-shockwave-flash"
>
>
> The totalsize now differ by about 1400 bytes.
>
> Thanks!
>
> Phil
>
>
>> To explain the different sizes you are seeing, it is likely that  
>> you do not have compression turned on
>> for your tomcat.  In your conf/server.xml you'll want a line that  
>> looks like this:
>>
>>          <Connector port="8080" .......
>>                                        
>> compressableMimeType="application/xml,text/html,text/xml,text/ 
>> javascript,application/x-javascript,application/ 
>> javascript,application/x-shockwave-flash"/>
>>
>> I'll put a note in test/appsize/readme.txt to that effect also.
>>
>> - Don
>>
>>
>> On Sep 19, 2008, at 1:50 PM, Philip Romanik wrote:
>>
>>
>> Approved!
>>
>> I see very different values comparing appsize-input.txt vs the  
>> appsize-output.txt generated on my (Windows) machine. I'm attaching  
>> both files.
>>
>>
>>
>>
>>
>> Change 20080919-dda-I by dda at lester.local on 2008-09-19 12:09:32 EDT
>>
>>     in /Users/dda/laszlo/src/svn/openlaszlo/trunk-a
>>
>>     for http://svn.openlaszlo.org/openlaszlo/trunk
>>
>>
>>
>> Summary: Create tools to track file size improvements
>>
>>
>>
>> New Features: ability to compare file sizes against previous versions
>>
>>
>>
>> Bugs Fixed: LPP-6892 (partial: completes collecting baseline  
>> measurements)
>>
>>
>>
>> Technical Reviewer: promanik (pending)
>>
>> QA Reviewer: (pending)
>>
>> Doc Reviewer: (pending)
>>
>>
>>
>> Documentation:
>>
>>
>>
>> Release Notes:
>>
>>
>>
>> Details:
>>
>>     The idea was to make an easy-to-use and cross-platform way
>>
>>     to compare the application sizes with 4.0, and also with any
>>
>>     other points we need.
>>
>>
>>
>>     Each 'application' checked is composed of a number of URLs.
>>
>>     The URLs need to be determined separatedly (firebug is one good
>>
>>     way to do this).  A property file contains a list of all
>>
>>     URLs used for each application, along with previous sizes
>>
>>     for comparison.  The previous sizes do not have to be present.
>>
>>
>>
>>     The tool that does the checking is called 'netsize', since it
>>
>>     looks at the actually bytes transmitted over the net, rather
>>
>>     than file sizes.  It's a very simple HTTP client that just
>>
>>     fetches URLs and looks at the size.  The only checking of
>>
>>     content is to try to detect 404 errors that may show up as an
>>
>>     error page.
>>
>>
>>
>>     One suggestion was to fail the build if the apps grow by too
>>
>>     much.  Perhaps we'll consider that in the future, but it's
>>
>>     certainly easy enough now to check larger changes to track
>>
>>     the effect on file sizes.
>>
>>
>>
>>     The completes the requirement to collect baseline measurements
>>
>>     against 4.0 and gives us tools to improves the sizes.
>>
>>     LPP-6892 will be left open to track various improvement ideas.
>>
>>
>>
>> Tests:
>>
>>     After assuring that tomcat is running and that the app is  
>> deployed,
>>
>>     in $LPS_HOME, ran:
>>
>>        ant appsize
>>
>>     to see that the file sizes have not changed since earlier  
>> today :-)
>>
>>     Also ran:
>>
>>        ant -Dappsize.input=appsize-4.0.txt appsize
>>
>>     to see that the file sizes have changed somewhat since 4.0
>>
>>
>>
>>     Other uses are detailed in test/appsize/readme.txt, including
>>
>>     the -Dappsize.flags, -Dappsize.dir, -Dappsize.output and - 
>> Dappsize.branch
>>
>>     options.
>>
>>
>>
>> Files:
>>
>> A      test/appsize
>>
>> A      test/appsize/appsize-input.txt
>>
>> A      test/appsize/appsize-4.0.txt
>>
>> A      test/appsize/readme.txt
>>
>> A      WEB-INF/lps/server/src/org/openlaszlo/test/netsize
>>
>> A      WEB-INF/lps/server/src/org/openlaszlo/test/netsize/ 
>> UrlSizer.java
>>
>> A      WEB-INF/lps/server/src/org/openlaszlo/test/netsize/ 
>> TotalSizer.java
>>
>> A      WEB-INF/lps/server/src/org/openlaszlo/test/netsize/ 
>> Netsize.java
>>
>> A      WEB-INF/lps/server/src/org/openlaszlo/test/netsize/Sizer.java
>>
>> A      WEB-INF/lps/server/src/org/openlaszlo/test/netsize/ 
>> AppSizer.java
>>
>> M      build.xml
>>
>>
>>
>> Changeset: http://svn.openlaszlo.org/openlaszlo/patches/20080919-dda-I.tar
>>
>>
>> --
>>
>> Don Anderson
>> Java/C/C++, Berkeley DB, systems consultant
>>
>> voice: 617-547-7881
>> email: dda at ddanderson.com
>> www: http://www.ddanderson.com
>>
>>
>>
>> <appsize-input.txt><appsize-output.txt>
>>
>>
>> --
>>
>> Don Anderson
>> Java/C/C++, Berkeley DB, systems consultant
>>
>> voice: 617-547-7881
>> email: dda at ddanderson.com
>> www: http://www.ddanderson.com
>>
>>
>>


--

Don Anderson
Java/C/C++, Berkeley DB, systems consultant

voice: 617-547-7881
email: dda at ddanderson.com
www: http://www.ddanderson.com



-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.openlaszlo.org/pipermail/laszlo-dev/attachments/20080919/6b4a094b/attachment-0001.html


More information about the Laszlo-dev mailing list