You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Kristian Rink <ka...@zimmer428.net> on 2009/09/22 08:34:47 UTC

Re: war artifacts: copying dependent .jars elsewhere instead of bundling them?

Hi Anders;

and first, thanks a bunch for your comments, much appreciated. :)

Anders Hammar schrieb:
> I think you should have scope 'provided'. Your use case is what that's for.

Yes, that's what I thought as well, but, well, it's not always the case -
we're using the same app code base for various deployments, but in not all
situations the artifacts actually _are_ provided / to be placed in the
server environment... And so far I hesitated having two different war
artifacts just to address this issue... but maybe it would be a cleaner
solution?


> Regarding handling your dependencies for production, that's more of a server
> deployment issue isn't it? What I think you can use is the copy-dependensies
> mojo of the dependency plugin (
> http://maven.apache.org/plugins/maven-dependency-plugin/copy-dependencies-mojo.html).
> As the dependencies are shared between several applications, I would create
> a separate project where I do this and the put them in an assembly (zip/tar
> file).

Thanks for pointing me there, taking a first look this seems pretty much
what I need. I'll play around with it and see how far it gets me; at the
moment, thanks a bunch again for your help. :)

Cheers,
Kristian


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: war artifacts: copying dependent .jars elsewhere instead of bundling them?

Posted by Kristian Rink <ka...@zimmer428.net>.
Anders Hammar schrieb:
> You can have one project with a primary artifact (including all
> dependencies) and an extra artifact (w/o deps) using a classifier. I don't
> think you should worry about have many artifacts. If you do that, then you
> will have problems with maven...:-)

I see. :) So by then this is the way I'm about to go, seems indeed the
cleanest approach of doing things. Thanks again for your help and all the best!
Kristian



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: war artifacts: copying dependent .jars elsewhere instead of bundling them?

Posted by Anders Hammar <an...@hammar.net>.
>
> Anders Hammar schrieb:
> > I think you should have scope 'provided'. Your use case is what that's
> for.
>
> Yes, that's what I thought as well, but, well, it's not always the case -
> we're using the same app code base for various deployments, but in not all
> situations the artifacts actually _are_ provided / to be placed in the
> server environment... And so far I hesitated having two different war
> artifacts just to address this issue... but maybe it would be a cleaner
> solution?
>
>
You can have one project with a primary artifact (including all
dependencies) and an extra artifact (w/o deps) using a classifier. I don't
think you should worry about have many artifacts. If you do that, then you
will have problems with maven...:-)

/Anders