From ivy-user-return-7874-apmail-ant-ivy-user-archive=ant.apache.org@ant.apache.org Thu Apr 28 01:35:05 2011 Return-Path: X-Original-To: apmail-ant-ivy-user-archive@www.apache.org Delivered-To: apmail-ant-ivy-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 4E8062E46 for ; Thu, 28 Apr 2011 01:35:05 +0000 (UTC) Received: (qmail 31023 invoked by uid 500); 28 Apr 2011 01:35:04 -0000 Delivered-To: apmail-ant-ivy-user-archive@ant.apache.org Received: (qmail 31003 invoked by uid 500); 28 Apr 2011 01:35:04 -0000 Mailing-List: contact ivy-user-help@ant.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: ivy-user@ant.apache.org Delivered-To: mailing list ivy-user@ant.apache.org Received: (qmail 30994 invoked by uid 99); 28 Apr 2011 01:35:04 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 28 Apr 2011 01:35:04 +0000 X-ASF-Spam-Status: No, hits=-0.0 required=5.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of Kfiles@masergy.com designates 64.47.5.21 as permitted sender) Received: from [64.47.5.21] (HELO SMTP1.masergy.com) (64.47.5.21) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 28 Apr 2011 01:34:58 +0000 Received: from MTXHUB1.add0.masergy.com (10.20.1.171) by SMTP1.masergy.com (64.47.5.21) with Microsoft SMTP Server (TLS) id 8.3.137.0; Wed, 27 Apr 2011 20:34:29 -0500 Received: from MailboxServer.add0.masergy.com ([fe80::bc12:6020:ffd2:9b29]) by MTXHUB1.add0.masergy.com ([::1]) with mapi; Wed, 27 Apr 2011 20:34:36 -0500 From: Kirby Files To: "ivy-user@ant.apache.org" Date: Wed, 27 Apr 2011 20:34:36 -0500 Subject: RE: Multiple classpaths Thread-Topic: Multiple classpaths Thread-Index: AcwFL5wAs8F3I1vtTRSBp61i1s+TcQAE6D6+ Message-ID: References: <13851AFD-42F9-48E6-907D-23F8D0CC115D@dcorbin.com>,<3356885173107121990@unknownmsgid> ,<9D260125-E5D3-473B-B41C-409A43CA2358@gmail.com> In-Reply-To: <9D260125-E5D3-473B-B41C-409A43CA2358@gmail.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: acceptlanguage: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Virus-Checked: Checked by ClamAV on apache.org By default, each configuration is mapped to a configuration of the same nam= e in the dependency. So in your case, lacking a mapping in the conf attribu= te or a defaultconfmapping, you get conf=3D"production->production", that i= s "my config production depends on the production config of org.springframe= work.beans". You have two choices to resolve this. If all of your configurations and dep= endencies use default configs, you could add: default"> Or, for each dependency, you can pick the dependent configuration you want = for each of your configs: runtime;build->compile"/> If you choose to use defaultconfmapping, you can still override it on a per= -dependency basis, if you need to (and you will). Thanks, --- Kirby Files Software Architect Masergy Communications kfiles@masergy.com ________________________________________ From: DAVID CORBIN [dcorbin13@gmail.com] Sent: Wednesday, April 27, 2011 7:05 PM To: ivy-user@ant.apache.org Subject: Re: Multiple classpaths Clearly there's something I'm not grokking. Here's my ivy.xml file. --- begin --- --- end --- It doesn't work, failing with [ivy:cachepath] :: problems summary :: [ivy:cachepath] :::: WARNINGS [ivy:cachepath] :::::::::::::::::::::::::::::::::::::::::::= ::: [ivy:cachepath] :: UNRESOLVED DEPENDENCIES = :: [ivy:cachepath] :::::::::::::::::::::::::::::::::::::::::::= ::: [ivy:cachepath] :: org.springframework#org.springframework.= beans;3.0.5.RELEASE: configuration not found in org.springframework#org.spr= ingframework.beans;3.0.5.RELEASE: 'production'. It was required from com.dc= orbin#TichuServer;working@dcorbin-mackbook-pro.local production [ivy:cachepath] :: org.springframework#org.springframework.= web.servlet;3.0.5.RELEASE: configuration not found in org.springframework#o= rg.springframework.web.servlet;3.0.5.RELEASE: 'production'. It was required= from com.dcorbin#TichuServer;working@dcorbin-mackbook-pro.local production [ivy:cachepath] :: junit#junit;4.8.2: configuration not fou= nd in junit#junit;4.8.2: 'production'. It was required from com.dcorbin#Tic= huServer;working@dcorbin-mackbook-pro.local production [ivy:cachepath] :::::::::::::::::::::::::::::::::::::::::::= ::: [ivy:cachepath] [ivy:cachepath] :: USE VERBOSE OR DEBUG MESSAGE LEVEL FOR MORE DETAILS On Apr 26, 2011, at 12:42 AM, Kirby Files wrote: > To elaborate on that a little: > > defines a configuration, which may only be used by IvyDE = to choose a set of deps, or it may be used by your ant scripts to choose a = set of deps to retrieve -- or you can define which artifacts your will publish for a given configuration. You can use the "standard" set= of configurations used when Ivy maps poms from Maven (runtime, master, def= ault, etc), or define your own for buiilding, testing and deploying. > > Your element can define a defaultconfmapping. This is us= eful to establish a baseline for mapping dependent configurations (both the= standards from Maven, and your own) to your configurations: > defaultconfmapping=3D"build->*;deploy->runtime", > > or if you are consistent in all of your configuration naming, and don't u= se anything from Maven, maybe: > defaultconfmapping=3D"build->*;%->@" > > See http://ant.apache.org/ivy/history/latest-milestone/ivyfile/dependency= .html for more on mapping configurations, and how to interpret all the spec= ial symbols. > > Then go through each of your dependencies; some will only be needed when = compiling, some when you run tests, and some when you deploy (and you may h= ave different confs for publications). You can either add a > conf=3D"build" > attribute to accept the default conf mapping and only retrieve this dep w= hen building; or add > conf=3D"build->core-apis;deploy->core-runtime" > for any dependencies which require special attention due to their definin= g a number of extra non-standard configurations. > > You may also want transitive=3D"false" on any deps which come from Maven,= and are known to have bad poms. > > Thanks, > --- > Kirby Files > Software Architect > Masergy Communications > kfiles@masergy.com > ________________________________________ > From: Tim Brown [tpbrown@gmail.com] > Sent: Monday, April 25, 2011 10:30 PM > To: ivy-user@ant.apache.org > Subject: Re: Multiple classpaths > > That's exactly how we use configurations. > > The dependency declaration defines the consuming module's config in > which It needs the dependency. > > You can use conf mappings to handle variances of confs across modules, > including those which don't have confs > > > > On Apr 25, 2011, at 4:33 PM, David Corbin wrote: > >> I want to produce two classpaths. One for production and one for >> testing. It kind of looks like configurations might work, but I'm >> not 100% certain. Is this an appropriate use for configuration? >> How do I indicate in the dependency that it is part of a given >> configuration? The conf parameter seems to refer to configurations >> offered by the dependency itself >> >> Thanks >> David Corbin