Re: "In-Place" Web Development
I'm going to patch the war task for some of the devs here and try this out this week (with 2 new goals as described). If it goes well I'll put the patch in JIRA. If it goes badly they kick my ass ;) Ben Walding wrote: Please update the wiki with the solution that you have been given. That way others can gain from the time that people have spent helping you! Cheers, Ben Dave Ford wrote: Thanks Brian. That's exactly what I was looking for. Problem solved! Dave Ford Smart Soft - The Developer Training Company http://www.smart-soft.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: "In-Place" Web Development
> Please update the wiki with the solution that you have been given. That > way others can gain from the time that people have spent helping you! I'll do that. I want to work with it for a few more days to make sure I haven't over looked anything. Dave Ford Smart Soft - The Developer Training Company http://www.smart-soft.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: "In-Place" Web Development
Please update the wiki with the solution that you have been given. That way others can gain from the time that people have spent helping you! Cheers, Ben Dave Ford wrote: Thanks Brian. That's exactly what I was looking for. Problem solved! Dave Ford Smart Soft - The Developer Training Company http://www.smart-soft.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: "In-Place" Web Development
Thanks Brian. That's exactly what I was looking for. Problem solved! Dave Ford Smart Soft - The Developer Training Company http://www.smart-soft.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: "In-Place" Web Development
Dave, I don't get why you want to use the war plugin *and* in-place editing. You really want to do one or the other. It sounds like the only 'goodness' you want from maven is the initial population of src/webapp/WEB-INF/lib (etc). You only want to go back to the war plugin to actually create a war, or run tests. So just do that. Write a goal which has war:webapp as a prerequisite, to copy the jars back to src/webapp/WEB-INF/lib. Now run it *once*, to prepopulate your lib dir. You might as well get it to copy all the classes over too, it'll save time later. At this point any decent IDE will not need to be told where to look for jars (so you won't bother with maven-generated ide config files), and can compile to src/webapp/WEB-INF/classes for you. Now you can just edit your webapp in your ide as per usual. Finally, write another goal to clean up the mess by getting rid of src/webapp/WEB-INF/*.tld, src/webapp/WEB-INF/lib/*.jar and src/webapp/WEB-INF/classes/**/*.class. You should be able to work inplace with that - the only time you'd go back to maven would be to create the war, run tests, generate tlds, update jars, etc. Something like this would do: (untested) Dave Ford wrote: But what about testing : can you set an efficient unit testing environment with "in-place" structuration? Certainly. I have had it for years. Which steps are necessary to run cactus tests for example ? Do you think your developpers will go through this steps each time they modify code ? No and they shouldn't - unless they are VERY patient and have time to kill. You're over doing the whole XP thing if you think you need to run your whole suite of tests every time you change a to a on a jsp page. The point is, for micro-changes, you don't want to run your whole suite of tests. You want instant feedback. I'm now considering changing my directory structure and writing my own webapp plug-in that supports in-place editing. I'm scared however. I wonder how many (as of yet unexplored) webapp-supporting-plugins I'll break in the process. Dave Ford Smart Soft - The Developer Training Company http://www.smart-soft.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: "In-Place" Web Development
> But what about testing : can you set an efficient unit testing environment > with "in-place" structuration? Certainly. I have had it for years. > Which steps are necessary to run cactus tests > for example ? Do you think your developpers will go through this steps each > time they modify code ? No and they shouldn't - unless they are VERY patient and have time to kill. You're over doing the whole XP thing if you think you need to run your whole suite of tests every time you change a to a on a jsp page. The point is, for micro-changes, you don't want to run your whole suite of tests. You want instant feedback. I'm now considering changing my directory structure and writing my own webapp plug-in that supports in-place editing. I'm scared however. I wonder how many (as of yet unexplored) webapp-supporting-plugins I'll break in the process. Dave Ford Smart Soft - The Developer Training Company http://www.smart-soft.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: "In-Place" Web Development
> This helps the problem only slightly. It still has to copy the whole > directory. Also, the war:webapp goal runs all my unit tests. I suppose I > could create a new goal that just copies the bare minimum. But it seems > illogical to slow down the development cycle with unnecessary copying and > waiting. > You don;t need to copy a directory! you have at least 3 alternative solutions: a) set your maven.war.webapp.dir=${maven.appserver.home}/webapps/NAME OF YOUR APPLICATION b) Configure you Web Server and point to dierctory where your web application is (can be simply /target/webapp) c) use maven-appserver-plugin (only with Tomcat) Michal - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: "In-Place" Web Development
> Take a look at http://wiki.codehaus.org/maven/CreatingWebApplications I have looked there. That's where I learned how to change my development environment from the previously mentioned responsive, productive setup to my new, slow-and-painful setup that requires me to run a bunch of unnecessary processing tasks just to make a minor change to a class or jsp. In the above referenced link, there is a note that says: > During the development cycle you typically want / need fast turn > around of changes into the running container. This can be achieved > by using the maven console (maven console) and using the war:webapp goal This helps the problem only slightly. It still has to copy the whole directory. Also, the war:webapp goal runs all my unit tests. I suppose I could create a new goal that just copies the bare minimum. But it seems illogical to slow down the development cycle with unnecessary copying and waiting. I'm too young to have experienced the days when you would write your program and then have to walk to a different room to see the output. But now I know how painful it must have been :) I want to follow the Maven directory structure standards because in doing so, I'll gain the most benefit from Maven. I have already given in on moving my tests into their own tree :) But this webapp thing will KILL my productivity thus negating the benefits of Maven. Dave Ford Smart Soft - The Developer Training Company http://www.smart-soft.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: RE : "In-Place" Web Development
what if you're not using ejb? The information contained in this e-mail is intended only for the person or entity to which it is addressed and may contain confidential and/or privileged material. If You are not the intended recipient of this e-mail, the use of this information or any disclosure, copying or distribution is Prohibited and may be unlawful. If you received this in error, please contact the sender and delete the material from any computer. The views expressed in this e-mail may not necessarily be the views of The PCMS Group plc and should not be taken as authority to carry out any instruction contained. > -Original Message- > From: BRUNOT Sébastien [mailto:[EMAIL PROTECTED] > Sent: 01 August 2003 09:53 > To: 'Maven Users List' > Subject: RE : "In-Place" Web Development > > > I used to agree with that... I've been coding J2EE app for > two years now, > always using this way of working, and considering two > distinct processes : > > 1) Code Authoring, done by the developper, using this "in-place" > structuration ; > 2) Module Assembling, done by the architect, using ant... > > But what about testing : can you set an efficient unit > testing environment > with "in-place" structuration ? Wich steps are necessary to > run cactus tests > for example ? Do you think your developpers will go through > this steps each > time they modify code ? With maven, this is a single command > operation that > build, run tests, deploy... > > Another point is That "in-place" structuration is impossible > for your ejb > modules. > > Sebastien BRUNOT > > -Message d'origine- > De : Dave Ford [mailto:[EMAIL PROTECTED] > Envoyé : vendredi 1 août 2003 01:17 > À : Maven Users > Objet : "In-Place" Web Development > > > How do people do "in-place" web development with Maven? I have been > developing web apps "in-place" now for quite some time (pre-maven). By > in-place, I mean the following: > > - My development servlet container (Resin) runs an un-jared web app > - My development webapp and the executable webapp are one in the same > - Jikes/IntelliJ places class files directly in WEB-INF/classes > - My servlet container is setup so that it doesn't cache > pages or class > files > so i never have to restart anything or reload the web app > > This is super convenient and fast. I can make changes to jsp > pages and .java > files, press ctrl-F9 in IntelliJ, Alt-Tab to the browser and > F5 to see my > changed web app. The time between making a change and viewing > the change is > 1/4 second. I'm used to this. > > So now, I've set up my web app to work with Maven's war > plugin and I have > lost the in-place development luxury because I have to run > the war:webapp > goal every time I want to run my JSP. So, I'm considering > ditching what > appears to be the standard way of doing webapps with Maven. > > Q1: Do people actually work this way? That is, copy the > entire webapp folder > every time they want to test out a small change in a jsp or class? > > Q2: If not, how do they organize the webapp to do in-place > web development > but also. > > Thanks > Dave Ford > Smart Soft - The Developer Training Company http://www.smart-soft.com > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE : "In-Place" Web Development
I used to agree with that... I've been coding J2EE app for two years now, always using this way of working, and considering two distinct processes : 1) Code Authoring, done by the developper, using this "in-place" structuration ; 2) Module Assembling, done by the architect, using ant... But what about testing : can you set an efficient unit testing environment with "in-place" structuration ? Wich steps are necessary to run cactus tests for example ? Do you think your developpers will go through this steps each time they modify code ? With maven, this is a single command operation that build, run tests, deploy... Another point is That "in-place" structuration is impossible for your ejb modules. Sebastien BRUNOT -Message d'origine- De : Dave Ford [mailto:[EMAIL PROTECTED] Envoyé : vendredi 1 août 2003 01:17 À : Maven Users Objet : "In-Place" Web Development How do people do "in-place" web development with Maven? I have been developing web apps "in-place" now for quite some time (pre-maven). By in-place, I mean the following: - My development servlet container (Resin) runs an un-jared web app - My development webapp and the executable webapp are one in the same - Jikes/IntelliJ places class files directly in WEB-INF/classes - My servlet container is setup so that it doesn't cache pages or class files so i never have to restart anything or reload the web app This is super convenient and fast. I can make changes to jsp pages and .java files, press ctrl-F9 in IntelliJ, Alt-Tab to the browser and F5 to see my changed web app. The time between making a change and viewing the change is 1/4 second. I'm used to this. So now, I've set up my web app to work with Maven's war plugin and I have lost the in-place development luxury because I have to run the war:webapp goal every time I want to run my JSP. So, I'm considering ditching what appears to be the standard way of doing webapps with Maven. Q1: Do people actually work this way? That is, copy the entire webapp folder every time they want to test out a small change in a jsp or class? Q2: If not, how do they organize the webapp to do in-place web development but also. Thanks Dave Ford Smart Soft - The Developer Training Company http://www.smart-soft.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: "In-Place" Web Development
You are right, but if you don't want to duplicated your JARs in WEB- INF/lib you need a way to populate it either tweaking your IDE or running Maven. Or is there a better solution?! Cheers, Siegfried Goeschl On 1 Aug 2003 at 10:55, Simon Matic Langford wrote: > This is all very well, but we have some developers who'd ideally like > to not have to run maven at all whilst doing webapp development, but > still leverage it for building all our reports and doing build checks > before code checkin. > > ie we don't want to be copying files about, is this possible, so far > I've told them no. > > The information contained in this e-mail is intended only for the > person or entity to which it is addressed and may contain confidential > and/or privileged material. If You are not the intended recipient of > this e-mail, the use of this information or any disclosure, copying or > distribution is Prohibited and may be unlawful. If you received this > in error, please contact the sender and delete the material from any > computer. The views expressed in this e-mail may not necessarily be > the views of The PCMS Group plc and should not be taken as authority > to carry out any instruction contained. > > > > -Original Message- > > From: Siegfried Göschl [mailto:[EMAIL PROTECTED] > > Sent: 01 August 2003 10:53 > > To: Maven Users List > > Subject: RE: "In-Place" Web Development > > > > > > Hi Brett, > > > > I came along this issue two weeks ago using Eclipse, Tomcat, Struts > > and the Tomcat Plugin for Eclipse. > > > > What I'm doing: > > > > +) I left MAVEN alone and tweaked the Eclipse confiugration to > > generate the class file into src/webapp/WEB-INF/classes. > > > > +) added a postGoal to war:webapp calling a locally defined goal > > local:webapp > > > > > > > > Copy libs to ${maven.war.src}/WEB-INF/lib > > > > > > > > > > > > > > Copy class files to ${maven.war.src}/WEB-INF/classes > > > >> dir="${maven.build.dir}/${pom.artifactId}/WEBINF/classes"> > > > > > > > > > > > > > > What it does is to copy the libs and generated classes from target > > into src/webapp/WEB-INF. And this is the place where the "in-place" > > development is done - the main inconvenience is changing the > > referenced JARs. > > > > > > Cheers, > > > > Siegfried Goeschl > > > > > > > > On 1 Aug 2003 at 15:59, Brett Porter wrote: > > > > > This isn't really in place though.. Although it is quick enough > > > for me. > > > > > > If you want it in place, what I've done in the past is have > > the target > > > dir set to the current directory so that WEB-INF/lib and classes > > > get populated by maven (everything else src=dest so its no > > problem), then > > > symlink or configure whatever tomcat instance you are > > running to that > > > directory, compile into WEB-INF/classes, tweak your JSPs, etc > > > > > > - Brett > > > > > > > -Original Message- > > > > From: Ben Walding [mailto:[EMAIL PROTECTED] > > > > Sent: Friday, 1 August 2003 3:45 PM > > > > To: Maven Users List > > > > Subject: Re: "In-Place" Web Development > > > > > > > > > > > > Take a look at > > > > http://wiki.codehaus.org/maven/CreatingWebApplications > > > > > > > > Dave Ford wrote: > > > > > > > > >How do people do "in-place" web development with Maven? > > I have been > > > > > developing web apps "in-place" now for quite some time > > > > (pre-maven). By > > > > >in-place, I mean the following: > > > > > > > > > > > > > > > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For > > additional commands, e-mail: [EMAIL PROTECTED] > > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] For > additional commands, e-mail: [EMAIL PROTECTED] > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: "In-Place" Web Development
This is all very well, but we have some developers who'd ideally like to not have to run maven at all whilst doing webapp development, but still leverage it for building all our reports and doing build checks before code checkin. ie we don't want to be copying files about, is this possible, so far I've told them no. The information contained in this e-mail is intended only for the person or entity to which it is addressed and may contain confidential and/or privileged material. If You are not the intended recipient of this e-mail, the use of this information or any disclosure, copying or distribution is Prohibited and may be unlawful. If you received this in error, please contact the sender and delete the material from any computer. The views expressed in this e-mail may not necessarily be the views of The PCMS Group plc and should not be taken as authority to carry out any instruction contained. > -Original Message- > From: Siegfried Göschl [mailto:[EMAIL PROTECTED] > Sent: 01 August 2003 10:53 > To: Maven Users List > Subject: RE: "In-Place" Web Development > > > Hi Brett, > > I came along this issue two weeks ago using Eclipse, Tomcat, Struts > and the Tomcat Plugin for Eclipse. > > What I'm doing: > > +) I left MAVEN alone and tweaked the Eclipse confiugration to > generate the class file into src/webapp/WEB-INF/classes. > > +) added a postGoal to war:webapp calling a locally defined goal > local:webapp > > > > Copy libs to ${maven.war.src}/WEB-INF/lib > > > > > > > Copy class files to ${maven.war.src}/WEB-INF/classes > > > > > > > > > What it does is to copy the libs and generated classes from target > into src/webapp/WEB-INF. And this is the place where the "in-place" > development is done - the main inconvenience is changing the > referenced JARs. > > > Cheers, > > Siegfried Goeschl > > > > On 1 Aug 2003 at 15:59, Brett Porter wrote: > > > This isn't really in place though.. Although it is quick enough for > > me. > > > > If you want it in place, what I've done in the past is have > the target > > dir set to the current directory so that WEB-INF/lib and classes get > > populated by maven (everything else src=dest so its no > problem), then > > symlink or configure whatever tomcat instance you are > running to that > > directory, compile into WEB-INF/classes, tweak your JSPs, etc > > > > - Brett > > > > > -Original Message- > > > From: Ben Walding [mailto:[EMAIL PROTECTED] > > > Sent: Friday, 1 August 2003 3:45 PM > > > To: Maven Users List > > > Subject: Re: "In-Place" Web Development > > > > > > > > > Take a look at > > > http://wiki.codehaus.org/maven/CreatingWebApplications > > > > > > Dave Ford wrote: > > > > > > >How do people do "in-place" web development with Maven? > I have been > > > > developing web apps "in-place" now for quite some time > > > (pre-maven). By > > > >in-place, I mean the following: > > > > > > > > > - > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: "In-Place" Web Development
Hi Brett, I came along this issue two weeks ago using Eclipse, Tomcat, Struts and the Tomcat Plugin for Eclipse. What I'm doing: +) I left MAVEN alone and tweaked the Eclipse confiugration to generate the class file into src/webapp/WEB-INF/classes. +) added a postGoal to war:webapp calling a locally defined goal local:webapp Copy libs to ${maven.war.src}/WEB-INF/lib Copy class files to ${maven.war.src}/WEB-INF/classes What it does is to copy the libs and generated classes from target into src/webapp/WEB-INF. And this is the place where the "in-place" development is done - the main inconvenience is changing the referenced JARs. Cheers, Siegfried Goeschl On 1 Aug 2003 at 15:59, Brett Porter wrote: > This isn't really in place though.. Although it is quick enough for > me. > > If you want it in place, what I've done in the past is have the target > dir set to the current directory so that WEB-INF/lib and classes get > populated by maven (everything else src=dest so its no problem), then > symlink or configure whatever tomcat instance you are running to that > directory, compile into WEB-INF/classes, tweak your JSPs, etc > > - Brett > > > -Original Message- > > From: Ben Walding [mailto:[EMAIL PROTECTED] > > Sent: Friday, 1 August 2003 3:45 PM > > To: Maven Users List > > Subject: Re: "In-Place" Web Development > > > > > > Take a look at > > http://wiki.codehaus.org/maven/CreatingWebApplications > > > > Dave Ford wrote: > > > > >How do people do "in-place" web development with Maven? I have been > > > developing web apps "in-place" now for quite some time > > (pre-maven). By > > >in-place, I mean the following: > > > > - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: "In-Place" Web Development
This isn't really in place though.. Although it is quick enough for me. If you want it in place, what I've done in the past is have the target dir set to the current directory so that WEB-INF/lib and classes get populated by maven (everything else src=dest so its no problem), then symlink or configure whatever tomcat instance you are running to that directory, compile into WEB-INF/classes, tweak your JSPs, etc - Brett > -Original Message- > From: Ben Walding [mailto:[EMAIL PROTECTED] > Sent: Friday, 1 August 2003 3:45 PM > To: Maven Users List > Subject: Re: "In-Place" Web Development > > > Take a look at http://wiki.codehaus.org/maven/CreatingWebApplications > > Dave Ford wrote: > > >How do people do "in-place" web development with Maven? I have been > >developing web apps "in-place" now for quite some time > (pre-maven). By > >in-place, I mean the following: > >
Re: "In-Place" Web Development
Take a look at http://wiki.codehaus.org/maven/CreatingWebApplications Dave Ford wrote: How do people do "in-place" web development with Maven? I have been developing web apps "in-place" now for quite some time (pre-maven). By in-place, I mean the following: - My development servlet container (Resin) runs an un-jared web app - My development webapp and the executable webapp are one in the same - Jikes/IntelliJ places class files directly in WEB-INF/classes - My servlet container is setup so that it doesn't cache pages or class files so i never have to restart anything or reload the web app This is super convenient and fast. I can make changes to jsp pages and .java files, press ctrl-F9 in IntelliJ, Alt-Tab to the browser and F5 to see my changed web app. The time between making a change and viewing the change is 1/4 second. I'm used to this. So now, I've set up my web app to work with Maven's war plugin and I have lost the in-place development luxury because I have to run the war:webapp goal every time I want to run my JSP. So, I'm considering ditching what appears to be the standard way of doing webapps with Maven. Q1: Do people actually work this way? That is, copy the entire webapp folder every time they want to test out a small change in a jsp or class? Q2: If not, how do they organize the webapp to do in-place web development but also. Thanks Dave Ford Smart Soft - The Developer Training Company http://www.smart-soft.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
"In-Place" Web Development
How do people do "in-place" web development with Maven? I have been developing web apps "in-place" now for quite some time (pre-maven). By in-place, I mean the following: - My development servlet container (Resin) runs an un-jared web app - My development webapp and the executable webapp are one in the same - Jikes/IntelliJ places class files directly in WEB-INF/classes - My servlet container is setup so that it doesn't cache pages or class files so i never have to restart anything or reload the web app This is super convenient and fast. I can make changes to jsp pages and .java files, press ctrl-F9 in IntelliJ, Alt-Tab to the browser and F5 to see my changed web app. The time between making a change and viewing the change is 1/4 second. I'm used to this. So now, I've set up my web app to work with Maven's war plugin and I have lost the in-place development luxury because I have to run the war:webapp goal every time I want to run my JSP. So, I'm considering ditching what appears to be the standard way of doing webapps with Maven. Q1: Do people actually work this way? That is, copy the entire webapp folder every time they want to test out a small change in a jsp or class? Q2: If not, how do they organize the webapp to do in-place web development but also. Thanks Dave Ford Smart Soft - The Developer Training Company http://www.smart-soft.com - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]