Sunday, May 25, 2014

Re: Google Chrome 35 GWT plugin incompatibility

So this is how it is done in ant. The snippet below reduces significantly the cost of redeployment since it avoids war creation, and unzipping. In my (very slow) machine the difference is from 21sec to 4-5sec. In faster machines the difference may be negligible.

This snippet below will not work for classpath changes, jar library changes, web.xml changes. So it has limited development utility to speed up the dev cycle.

+       <taskdef name="reload" classname="org.apache.catalina.ant.ReloadTask" >
+               <classpath refid="tomcat.classpath" />
+       </taskdef>
+
...
+
+       <target name="dreload" description="dev reload: reload to private development tomcat instance">
+               <echo message="Syncing classes..."/>
+               <sync todir="${user.home}/tomcat/webapps/${ant.project.name}/WEB-INF/classes" verbose="true">
+                       <fileset dir="war/WEB-INF/classes"/>
+               </sync>
+               <echo message="Reloading in port ${port}"/>
+               <reload url="http://localhost:${port}/manager/text" username="${manager_username}" password="${manager_password}" path="/${webapp}" />
+       </target>
 </project>



On Sat, May 24, 2014 at 2:07 PM, Vassilis Virvilis <vasvir2@gmail.com> wrote:
Aha,

I am not into maven (yet) but the equivalent in ant land I suppose is __reload__ task http://tomcat.apache.org/tomcat-7.0-doc/manager-howto.html#Reload_An_Existing_Application

This coupled with some ant rsync magic can  drop my redeployment down to 4sec. No web.xml reloads though...









On Sat, May 24, 2014 at 1:38 AM, Thomas Broyer <t.broyer@gmail.com> wrote:
FYI, I just use the maven plugins for tomcat or jetty which run the classes right from my projects (automatically recompiled by my IDE) with automatic app reload (or just a keypress away).

See https://github.com/tbroyer/gwt-maven-archetypes for my setup.

On a project with heavy jetty customization, we just had a "dev" config for jetty to load classes from our project, with automatic app reload.
The same is available for tomcat.

--
You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.



--
Vassilis Virvilis



--
Vassilis Virvilis

--
You received this message because you are subscribed to the Google Groups "Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment