On 1/26/07, molecool <[EMAIL PROTECTED]> wrote:

Jeeez, I'm going to have to beat this one to death, my apologies in advance
Matt:


Matt Raible-3 wrote:
>
> The war plugin has the overlay feature:
>
> http://maven.apache.org/plugins/maven-war-plugin/examples/war-overlay.html
>
> The warpath plugin allows us to read dependencies from WARs. By
> default, Maven treats WARs as dumb dependencies with no dependencies.
> Without the warpath plugin, you can't add WAR dependencies to your
> classpath and you have to build WARs with no classes in them. We
> couldn't do AppFuse 2.0 without this plugin.
>

Okay, the maven WAR overlay is clear to me now, but I'm still a bit not sure
about the warpath. Are you saying that the 'overlayed' WAR (e.g.
appfuse-core) has its own dependencies (e.g. log4j) which the WAR overlay
does not make available? So, warpath plugin is used to enable that? I still
don't get it how otherwise building WARs without classes in them would
address that. Sorry if I'm a bit thickheaded on this one :-}


When you have a WAR as a dependency, it's treated like a static file
in Maven. You can't inherit dependencies from it. WarPath allows you
to inherit dependencies from WARs.


> Running mvn war:inplace extracts all the contents of the WAR into your
> local project.  It's pretty ugly because you don't want *everything*.
> In most cases, you simply want to override a few files.
>
> We recommend using war:inplace because after you do so, you can use
> "mvn jetty:run", which allows you to develop w/o restarting Jetty.
> It'll automatically restart if it detects any changes.  Running "mvn
> jetty:run-exploded" and "mvn package" in another window has the same
> effect.  However, jetty:run is a lot nicer because you can leverage
> your IDEs compile-on-save feature and eliminate the deploy cycle.
> Here's a video demonstration:
>
> http://static.appfuse.org/movies/2.0/struts2-crud.mov
>

Okay, but how do I 'get rid' of all the source that I don't need? Let's say
I only want to edit/update mainMenu.html - I do mvn war:inplace will get me
*everything* and at that point I am managing *all* those appfuse core
resources myself. If you post a new version tomorrow (which you always do
once I start a new appfuse project ;-) then I'll have to start removing all
the 'unchanged' core resources from my project?

That's what version numbers are for.  If you use SNAPSHOT releases,
yes, it's possible that I'll publish a newer version of mainMenu.jsp
tomorrow and it'll overwrite yours.  We're working on coming up with a
better system than timestamps, but haven't yet.  If you use a released
version of AppFuse, this won't happen.  If SVN and Maven keep
timestamps correctly, you won't get overlayed when never versions come
out - unless we've changed something.

With 2.0, it's *very* important you use source control. That way, if
you run "mvn war:inplace", you can tell what's yours and what's new.
Delete the new stuff and keep the stuff you modified. It's pretty
simple if your IDE tells you what's new.  IDEA 6 has a great "Changes"
panel that makes this super easy.


BTW, I watched that clip - how do get those classes to be populated so fast?
In Eclipse we have templates and I don't know IntelliJ, but the pace at
which you were able to produce the entire roundtrip was very impressive.
Either you're the fastest coder on the planet or you're using some cool
tools I'd like to get my hands on - LOL :-)

IDEA Live Templates.  I pre-record the code and simply "paste" it for
the various pieces. Works great for demos.  It's also possible to make
parts variables, so this is something that we could possibly
distribute to IDEA users so they can type a command and "boom" have
all the code for that particular class.


Thanks so much for your responses - I'm very excited about appfuse 2.0 and
want to make sure I'm getting off to a good start.

Again - thanks for all your questions - these should be great for the archives!

Matt


Cheers,

Michael
--
View this message in context: 
http://www.nabble.com/Appfuse-2.0---where-are-the-sources-jsps--tf3119998s2369.html#a8657069
Sent from the AppFuse - User mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




--
http://raibledesigns.com

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to