ant-ivy-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Xavier Hanin" <>
Subject Re: retrieving the modules and organizations via the API
Date Tue, 08 Apr 2008 07:55:08 GMT
On Mon, Apr 7, 2008 at 9:05 PM, Ernest Pasour <> wrote:

> I'm using 2.0B1
> I'm trying to use an Ivy object to determine the modules in my current ivy
> repo chain.  So I do something like the following:
> Ivy ivy = Ivy.newInstance();
> OrganisationEntry[] orgEntries=ivy.listOrganisationEntries();
> for (int i=0;i<orgEntries.length;i++)
> {
>        ModuleEntry[] modules=ivy.listModules(orgEntries[i]);
> }
> However, the list of OrganisationEntry objects I get back does not match
> the organizations that are expected in the ivy.xml file:
> <dependency name="JavaMail" rev="1.4.0" org="TPJ" conf="runtime,compile"/>
> In this case, I don't get back any "TPJ" organization at all.  I *do* get
> all the modules back, but with duplicates and some with bogus organizations.
> Also, if I use the Ivy api to do a resolve on a ModuleRevisionId
> constructed from the module name and [bogus] organization, it fails.
> So, my questions are:
> 1. is this a bug?
> 2. is there a way for me to query the organizations/modules that will let
> me feed them back into the ivy.xml file/resolve call correctly.
> 3. I still need to be able to query each module for the available
> revisions, which seems to work correctly at the moment, despite the
> conflicting data.

According to your code you don't seem to be calling configure on your Ivy
instance. It's very important for Ivy to work properly to be configured with
your settings. If it still fails, maybe it's because you don't have an
organization token in your pattern. In this case Ivy has no way to know the
organizations without actually parsing all metadata files in your repo,
which is possible only with the RepositoryManagementEngine, which as you can
expect doesn't perform very well.


> Thanks,
> Ernest

Xavier Hanin - Independent Java Consultant

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message