Why does my war take up so much space when deploying on GAE?

When I compile the GAE / GWT (Java) project (compiling all 6 permutations), the entire WAR folder is 93.9 Mo in weight on my computer (Mac OS extended version). When deployed to GAE, the admin console (quota details page) shows that my app is taking up 18% of the free quota. The value is 180Mb. How is this possible? Am I missing something? Does Google use a large block file system? How can you optimize the use of available storage space? I'm already JARing in my "classes" folder, but the gain (in terms of space ...) doesn't matter.

The biggest problem (from my point of view) is that my own GWT + server-side code + "external" library (PDFJet) takes a tiny 1.9MB. All the rest (> 91Mb) are taken by their own appengine and datanucleus libraries. Why should we include those in deployment? They are used by everyone. I think it would be best for all of us when they are centrally and automatically deployed. I do not understand.

Any advice or comments on this?

+3


source to share


1 answer


You need to make sure the GWT compilation output is set for production deployment and in your case for the cloud .

Provide production deployment

1) GWT compiler flag for STYLE IS OBF

2) Compiling GWT disables the stack trace emulator feature. In .gwt.xml

<set-property name="compiler.stackMode" value="strip" />

      



Provide cloud deployment

1) The GWT compiler flag for additional and deployment is used to redirect excess deployment files from a WAR file. I am assuming you have a massive folder called deploy in your WEB-INF.

Edit -

1) Link to GWT compiler options - https://developers.google.com/web-toolkit/doc/latest/DevGuideCompilingAndDebugging

2) Link to google group discussion - https://groups.google.com/forum/?fromgroups=#!topic/google-web-toolkit/-WtEfDvUI4g

+5


source







All Articles