gwt-log and size of JS

23 views
Skip to first unread message

Sri

unread,
Aug 28, 2012, 7:18:15 PM8/28/12
to gwt...@googlegroups.com
Hello,
Our app is huge and we have recently moved to gwt. We love the gwt-log features and would in-fact like to have it in even in prod. If any of our client report problems, our troubleshooting team can ask the user to add ?log_level=DEBUG (or atleast WARN/ERROR) to url and re-run the scenario... but the problem we're facing is the size of the JS files that are loaded. When we tested on chrome, without gwt-log enabled, the size of the JS file was around 1.6 MB. When compiled with log-level set to DEBUG the size of the loaded JS was 4 MB. Is there a way to dynamically enable(load) logging. What is the best way to mitigate this? Thanks in advance.

-sri

Fred Sauer

unread,
Aug 28, 2012, 7:24:47 PM8/28/12
to gwt...@googlegroups.com
Just like GWT generates different JavaScript files for each browser (user agent), gwt-log will cause different JS files for each compile time log level. Combined you will get different JS files for each combination of user agent / compile time log level.

In other words, users running log level WARN or ERROR should not pay the price of any of the logging at lower levels such as debug.

Be sure you are checking the size of the JS being sent to the browser, not the total amount of JS being generated.

Fred



-sri

--
You received this message because you are subscribed to the Google Groups "gwt-log" group.
To view this discussion on the web visit https://groups.google.com/d/msg/gwt-log/-/bjIv4gnBJCkJ.
To post to this group, send email to gwt...@googlegroups.com.
To unsubscribe from this group, send email to gwt-log+u...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/gwt-log?hl=en.



--
Fred Sauer
fr...@allen-sauer.com
Reply all
Reply to author
Forward
0 new messages