jira.codehaus.org

  • Log In Access more options
    • Online Help
    • Keyboard Shortcuts
    • About JIRA
    • JIRA Credits
    • What?s New
  • Dashboards Access more options (Alt+d)
  • Projects Access more options (Alt+p)
  • Issues Access more options (Alt+i)
Signup
Maven Integration for Eclipse
  • Maven Integration for Eclipse
  • MNGECLIPSE-1033

allow to use non-unique index ids

  • Log In
  • Views
    • XML
    • Word
    • Printable

Details

  • Type: Bug Bug
  • Status: Open Open
  • Priority: Major Major
  • Resolution: Unresolved
  • Affects Version/s: 0.9.6
  • Fix Version/s: 0.9.8
  • Component/s: Indexer
  • Labels:
    None
  • Number of attachments :
    0

Description

  • added a new index and pointed it at one nexus group. The context provided by nexus is "public-merged".
  • then edited the existing Central index url to point at another nexus instance.
  • clicked retrieve context and it also said public-merged.
  • When i saved it, the central one simply disappeared.

What if i really want both indexes? I don't have control all the time of the context used on the remote url so m2e should be able to handle this.

Nexus deals with it by changing the context after it's downloaded before attempting to merge them together.

Activity

Ascending order - Click to sort in descending order
  • All
  • Comments
  • Work Log
  • History
  • Activity
Hide
Permalink
Eugene Kuleshov added a comment - 03/Nov/08 7:30 PM

Unfortunately this is limitation in the indexer, the context id must match id in the index. All relevant code is actually in the nexus indexer component.

Show
Eugene Kuleshov added a comment - 03/Nov/08 7:30 PM Unfortunately this is limitation in the indexer, the context id must match id in the index. All relevant code is actually in the nexus indexer component.
Hide
Permalink
Jason van Zyl added a comment - 16/Feb/09 9:25 AM

Can we not just put the id in the properties file sitting along side the URL. The user should simply have to point at the URL.

Show
Jason van Zyl added a comment - 16/Feb/09 9:25 AM Can we not just put the id in the properties file sitting along side the URL. The user should simply have to point at the URL.
Hide
Permalink
Eugene Kuleshov added a comment - 16/Feb/09 9:32 AM

Jason, it is already done like this. You specify url and push refresh button, then id is retrieved.

Show
Eugene Kuleshov added a comment - 16/Feb/09 9:32 AM Jason, it is already done like this. You specify url and push refresh button, then id is retrieved.
Hide
Permalink
Jason van Zyl added a comment - 16/Feb/09 11:13 AM

So this should be closed then?

Show
Jason van Zyl added a comment - 16/Feb/09 11:13 AM So this should be closed then?
Hide
Permalink
Jason van Zyl added a comment - 16/Feb/09 11:14 AM

Rich, can you validate this or if it's part of your existing test suite close this up.

Show
Jason van Zyl added a comment - 16/Feb/09 11:14 AM Rich, can you validate this or if it's part of your existing test suite close this up.
Hide
Permalink
Eugene Kuleshov added a comment - 16/Feb/09 11:42 AM

The id retrieved from repository is still used as a key (pretty same actually happens in Maven itself), if two repositories would specify the same id in their properties you won't be able to add them to the Maven Indexes view without manually changing the id.

Show
Eugene Kuleshov added a comment - 16/Feb/09 11:42 AM The id retrieved from repository is still used as a key (pretty same actually happens in Maven itself), if two repositories would specify the same id in their properties you won't be able to add them to the Maven Indexes view without manually changing the id.
Hide
Permalink
Rich Seddon added a comment - 17/Feb/09 5:52 PM

Indeed, the behavior described still occurs.

Seems like the fix would be to warn the user that the ID already exists?

Show
Rich Seddon added a comment - 17/Feb/09 5:52 PM Indeed, the behavior described still occurs. Seems like the fix would be to warn the user that the ID already exists?
Hide
Permalink
Brian Fox added a comment - 17/Feb/09 5:56 PM

we should simply change the id to be the url retrieved from, it's the ony way to have it be unique. Warning the user it aready exists does nothing to help them since it would be out of their control to rename the remote index. We have the same problem in nexus and it handles it transparently by renaming the incoming id to avoid a conflict. m2e should do the same. As a user, i just want the index, i don't really care what the other guy chose to call it and if it conflicts with what some other guy called his.

Show
Brian Fox added a comment - 17/Feb/09 5:56 PM we should simply change the id to be the url retrieved from, it's the ony way to have it be unique. Warning the user it aready exists does nothing to help them since it would be out of their control to rename the remote index. We have the same problem in nexus and it handles it transparently by renaming the incoming id to avoid a conflict. m2e should do the same. As a user, i just want the index, i don't really care what the other guy chose to call it and if it conflicts with what some other guy called his.
Hide
Permalink
Eugene Kuleshov added a comment - 18/Feb/09 12:17 AM

Rich, it already warns user if id exists.

Brian, I don't completely agree with you about using url as an index id. First of all the idea is to be able to match Maven's repo ids (so we can implement the project-scoped indexes) and second - urls would produce duplicated index identities for the same index if mirrors are used.

I'd like to learn more about nexus algorithm for renaming ids automatically.

Show
Eugene Kuleshov added a comment - 18/Feb/09 12:17 AM Rich, it already warns user if id exists. Brian, I don't completely agree with you about using url as an index id. First of all the idea is to be able to match Maven's repo ids (so we can implement the project-scoped indexes) and second - urls would produce duplicated index identities for the same index if mirrors are used. I'd like to learn more about nexus algorithm for renaming ids automatically.
Hide
Permalink
Jason van Zyl added a comment - 18/Feb/09 1:57 AM

The id should be removed from the UI and the ID should be made to be unique by using a fully qualified domain name. The URL may change over time, but the user should not select the id, it should come from the index that is generated and be guaranteed to be unique.

Show
Jason van Zyl added a comment - 18/Feb/09 1:57 AM The id should be removed from the UI and the ID should be made to be unique by using a fully qualified domain name. The URL may change over time, but the user should not select the id, it should come from the index that is generated and be guaranteed to be unique.
Hide
Permalink
Igor Fedorenko added a comment - 18/Feb/09 9:14 AM - edited

I may be missing something, but why do we force users to manually enter indexes in the first place? I believe in majority of cases users really want indexes for repositories defined in their settings.xml and/or referenced by their projects. So should not m2e just download indexes of all referenced repositories automatically?

Show
Igor Fedorenko added a comment - 18/Feb/09 9:14 AM - edited I may be missing something, but why do we force users to manually enter indexes in the first place? I believe in majority of cases users really want indexes for repositories defined in their settings.xml and/or referenced by their projects. So should not m2e just download indexes of all referenced repositories automatically?
Hide
Permalink
Eugene Kuleshov added a comment - 18/Feb/09 9:24 AM

Jason, I suppose part about making index id fully qualified by domain name should be handled by something like Nexus. Right now two default Nexus installations are producing indexes with the same ids and I don't really see how these indexes can be distinguished automatically on the client side.

Igor, the above should answer your question why user is requested to enter the index id. Also, it is not necessary that index is always defined in settings.xml, e.g. central is usually not there, but I've seen some users declare their own proprietary repository with id "central".

There is MNGECLIPSE-725 about project-specific indexes.

Show
Eugene Kuleshov added a comment - 18/Feb/09 9:24 AM Jason, I suppose part about making index id fully qualified by domain name should be handled by something like Nexus. Right now two default Nexus installations are producing indexes with the same ids and I don't really see how these indexes can be distinguished automatically on the client side. Igor, the above should answer your question why user is requested to enter the index id. Also, it is not necessary that index is always defined in settings.xml, e.g. central is usually not there, but I've seen some users declare their own proprietary repository with id "central". There is MNGECLIPSE-725 about project-specific indexes.
Hide
Permalink
Brian Fox added a comment - 18/Feb/09 1:09 PM

when you get an index, just preprocess it to change the id silently based on where it came from.

Show
Brian Fox added a comment - 18/Feb/09 1:09 PM when you get an index, just preprocess it to change the id silently based on where it came from.

People

  • Assignee:
    Rich Seddon
    Reporter:
    Brian Fox
Vote (0)
Watch (0)

Dates

  • Created:
    03/Nov/08 3:48 PM
    Updated:
    18/Feb/09 1:09 PM
  • Atlassian JIRA (v5.2.7#850-sha1:b2af0c8)
  • Report a problem
  • Powered by a free Atlassian JIRA open source license for Codehaus. Try JIRA - bug tracking software for your team.