Cannot remove downloaded artifact from repo1 cache

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Cannot remove downloaded artifact from repo1 cache

Thorsten Heit
Hi,

I've set up a local Artifactory proxy that works quite well for me. One of my POMs has a dependency to Apache Xerces 2.0.0 (yes, I know, quite old, but only that version is working for them) that was downloaded into the proxy from central repository. So far, so good.

Recently I downloaded Xerces 2.0.0, recompiled it and deployed it to my local repository together with the sources. The repository actually looks like:

Repositories
+ local-repo
|  ...
|  +- xerces
|     +- xercesImpl
|     |  |- 2.0.0
|     |  |  +- xercesImpl-2.0.0-sources.jar
|     |  |  +- xercesImpl-2.0.0-sources.pom
|     |  |  +- xercesImpl-2.0.0.jar
|     |  |  \- xercesImpl-2.0.0.pom
|     |  |  +- xercesImpl-2.0.0-sources.jar
|     |  |  +- xercesImpl-2.0.0-sources.pom
|     |  |
|     |  \- maven-metadata.xml
|     |
|     +- xmlParserAPIs
|        |- 2.0.0
|        |  +- xmlParserAPIs-2.0.0-sources.jar
|        |  +- xmlParserAPIs-2.0.0-sources.pom
|        |  +- xmlParserAPIs-2.0.0.jar
|        |  \- xmlParserAPIs-2.0.0.pom
|        |  +- xmlParserAPIs-2.0.0-sources.jar
|        |  +- xmlParserAPIs-2.0.0-sources.pom
|        |
|        \- maven-metadata.xml
...
+ repo1-cache
|  ...
|  +- xerces
|     +- xercesImpl
|     |  \- 2.0.0
|     |
|     +- xmlParserAPIs
|        \- 2.0.0

I can right-click as often as I want on "xerces" under "repo1-cache" and select "Remove" from the popup menu, but nothing happens. Artifactory only once removed the files under that groupId, but not the group itself. Doing the same under "local-repo" removes the group...

Is this a bug?


Regards

Thorsten


Reply | Threaded
Open this post in threaded view
|

Re: Cannot remove downloaded artifact from repo1 cache

Yoav Landman
Administrator
You mean you click the "repo1-cache/xerces" folder?
If so, can it be a refresh issue? What happens if you re-browse the
repositories?


On 3/13/07, Thorsten Heit <[hidden email]> wrote:

> Hi,
>
> I've set up a local Artifactory proxy that works quite well for me. One of my POMs has a dependency to Apache Xerces 2.0.0 (yes, I know, quite old, but only that version is working for them) that was downloaded into the proxy from central repository. So far, so good.
>
> Recently I downloaded Xerces 2.0.0, recompiled it and deployed it to my local repository together with the sources. The repository actually looks like:
>
> Repositories
> + local-repo
> |  ...
> |  +- xerces
> |     +- xercesImpl
> |     |  |- 2.0.0
> |     |  |  +- xercesImpl-2.0.0-sources.jar
> |     |  |  +- xercesImpl-2.0.0-sources.pom
> |     |  |  +- xercesImpl-2.0.0.jar
> |     |  |  \- xercesImpl-2.0.0.pom
> |     |  |  +- xercesImpl-2.0.0-sources.jar
> |     |  |  +- xercesImpl-2.0.0-sources.pom
> |     |  |
> |     |  \- maven-metadata.xml
> |     |
> |     +- xmlParserAPIs
> |        |- 2.0.0
> |        |  +- xmlParserAPIs-2.0.0-sources.jar
> |        |  +- xmlParserAPIs-2.0.0-sources.pom
> |        |  +- xmlParserAPIs-2.0.0.jar
> |        |  \- xmlParserAPIs-2.0.0.pom
> |        |  +- xmlParserAPIs-2.0.0-sources.jar
> |        |  +- xmlParserAPIs-2.0.0-sources.pom
> |        |
> |        \- maven-metadata.xml
> ...
> + repo1-cache
> |  ...
> |  +- xerces
> |     +- xercesImpl
> |     |  \- 2.0.0
> |     |
> |     +- xmlParserAPIs
> |        \- 2.0.0
>
> I can right-click as often as I want on "xerces" under "repo1-cache" and select "Remove" from the popup menu, but nothing happens. Artifactory only once removed the files under that groupId, but not the group itself. Doing the same under "local-repo" removes the group...
>
> Is this a bug?
>
>
> Regards
>
> Thorsten
>
> -------------------------------------------------------------------------
> Take Surveys. Earn Cash. Influence the Future of IT
> Join SourceForge.net's Techsay panel and you'll get the chance to share your
> opinions on IT & business topics through brief surveys-and earn cash
> http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
> _______________________________________________
> Artifactory-users mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/artifactory-users
>


Reply | Threaded
Open this post in threaded view
|

Re: Cannot remove downloaded artifact from repo1 cache

Thorsten Heit
In reply to this post by Thorsten Heit
Hello again,

> The repository actually looks
> like:
> ...
> + repo1-cache
> |  ...
> |  +- xerces
> |     +- xercesImpl
> |     |  \- 2.0.0
> |     |
> |     +- xmlParserAPIs
> |        \- 2.0.0
>
> I can right-click as often as I want on "xerces" under "repo1-cache" and
> select "Remove" from the popup menu, but nothing happens. Artifactory only
> once removed the files under that groupId, but not the group itself. Doing
> the same under "local-repo" removes the group...

Today I accidentially managed to import some files directly under <repositories>/apache-m2-snapshots-cache which proxies (as the name suggests) the snapshot repository at http://people.apache.org/repo/m2-snapshot-repository -- I just forgot that I have to create the necessary subdirectory structure in the directory from which I want to import the files. Anyway. Actually the repo looks like

+ apache-m2-snapshots-cache
  +-- maven-default-skin-1.1-20061114.072151-2-sources.jar
  +-- maven-default-skin-1.1-20061114.072151-2.jar
  +-- maven-default-skin-1.1-20061114.072151-2.pom
  +-- org
      +-- ...
(the files were meant to be put under
<apache-m2-snapshots-cache>/org/apache/maven/skins/maven-default-skin/1.1-SNAPSHOT/)

Unfortunately I'm not able to purge these files from the repo; the "Remove" entry in the context menu is grayed out. I can only view one of these files or trigger "Zap cache". Trying to view one of these three files results in an error message:

2007-03-14 18:06:14,203 [WARN ] artifactory.resource.ArtifactResource  - Failed to build a ArtifactResource from 'maven-default-skin-1.1-20061114.072151-2.pom'. The groupId, artifactId and version are unreadable..
2007-03-14 18:06:14,203 [ERROR] wicket.RequestCycle   - Failed to execute JcrCallback.
java.lang.RuntimeException: Failed to execute JcrCallback.
        at org.artifactory.jcr.JcrHelper.doInSession(JcrHelper.java:139)
        at org.artifactory.webapp.wicket.browse.BrowseRepoPanel$3.respond(BrowseRepoPanel.java:279)
        at wicket.ajax.AbstractDefaultAjaxBehavior.onRequest(AbstractDefaultAjaxBehavior.java:220)
        at wicket.request.target.component.listener.BehaviorRequestTarget.processEvents(BehaviorRequestTarget.java:97)
        at wicket.request.AbstractRequestCycleProcessor.processEvents(AbstractRequestCycleProcessor.java:89)
        at wicket.RequestCycle.processEventsAndRespond(RequestCycle.java:968)
        at wicket.RequestCycle.step(RequestCycle.java:1041)
        at wicket.RequestCycle.steps(RequestCycle.java:1115)
        at wicket.RequestCycle.request(RequestCycle.java:456)
        at wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:254)
        at wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:124)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
        at org.artifactory.webapp.servlet.RepoFilter.doFilterInternal(RepoFilter.java:77)
        at org.artifactory.webapp.servlet.ArtifactoryFilter.doFilter(ArtifactoryFilter.java:73)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
        at org.artifactory.webapp.servlet.AccessFilter.doFilterInternal(AccessFilter.java:59)
        at org.artifactory.webapp.servlet.ArtifactoryFilter.doFilter(ArtifactoryFilter.java:73)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
        at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
        at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
        at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
        at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
        at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
        at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
        at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
        at java.lang.Thread.run(Unknown Source)
Caused by: java.lang.StringIndexOutOfBoundsException: String index out of range: -1
        at java.lang.String.substring(Unknown Source)
        at org.artifactory.resource.SimpleRepoResource.getRelDirPath(SimpleRepoResource.java:47)
        at org.artifactory.repo.JcrRepo.getPomContent(JcrRepo.java:339)
        at org.artifactory.webapp.wicket.window.WindowPanel.getArtifactMetadataContent(WindowPanel.java:63)
        at org.artifactory.webapp.wicket.browse.BrowseRepoPanel.access$400(BrowseRepoPanel.java:48)
        at org.artifactory.webapp.wicket.browse.BrowseRepoPanel$3$1.doInJcr(BrowseRepoPanel.java:285)
        at org.artifactory.webapp.wicket.browse.BrowseRepoPanel$3$1.doInJcr(BrowseRepoPanel.java:279)
        at org.artifactory.jcr.JcrHelper.doInSession(JcrHelper.java:135)
        ... 32 more
2007-03-14 18:06:17,156 [WARN ] artifactory.resource.ArtifactResource  - Failed to build a ArtifactResource from 'maven-default-skin-1.1-20061114.072151-2-sources.jar'. The groupId, artifactId and version are unreadable..
2007-03-14 18:06:17,156 [WARN ] artifactory.resource.ArtifactResource  - Failed to build a ArtifactResource from 'maven-default-skin-1.1-20061114.072151-2.jar'. The groupId, artifactId and version are unreadable..
2007-03-14 18:06:17,156 [WARN ] artifactory.resource.ArtifactResource  - Failed to build a ArtifactResource from 'maven-default-skin-1.1-20061114.072151-2.pom'. The groupId, artifactId and version are unreadable..


Is this a subsequent error or something different?


Cheers

Thorsten


Reply | Threaded
Open this post in threaded view
|

Re: Cannot remove downloaded artifact from repo1 cache

Frederic Simon-3
Yes it is different,
By doing a deploy at the root, you generated a virtual empty groupId which is forbidden in Maven term, and so (also) in term of artifactory query data.
if we solve your JIRA entry https://www.jfrog.org/jira/browse/RTFACT-62 in the next version (1.2.1) you should be able to clean the cache completly from the UI and so solve your issue.
In this version, the only way to solve the situation will be to change the remoteRepository key vlaue to another value so artifactory will recreate a new DB entry for the apache-m2-repo entry.
You can also do a full export of all repositories and delete the all ${ARTIFACTORY_HOME}/repos/jcr folder. It will keep the users/security configuration but all data in repositpories will be empty. You can the reimport "clean" repositories.

Please fell free to enter a new bug description in http://www.jfrog.org/jira/ if you want.

On 3/14/07, Thorsten Heit <[hidden email]> wrote:
Hello again,

> The repository actually looks
> like:
> ...
> + repo1-cache
> |  ...
> |  +- xerces
> |     +- xercesImpl
> |     |  \- 2.0.0
> |     |
> |     +- xmlParserAPIs
> |        \- 2.0.0
>
> I can right-click as often as I want on "xerces" under "repo1-cache" and
> select "Remove" from the popup menu, but nothing happens. Artifactory only
> once removed the files under that groupId, but not the group itself. Doing
> the same under "local-repo" removes the group...

Today I accidentially managed to import some files directly under <repositories>/apache-m2-snapshots-cache which proxies (as the name suggests) the snapshot repository at http://people.apache.org/repo/m2-snapshot-repository -- I just forgot that I have to create the necessary subdirectory structure in the directory from which I want to import the files. Anyway. Actually the repo looks like

+ apache-m2-snapshots-cache
  +-- maven-default-skin-1.1-20061114.072151-2-sources.jar
  +-- maven-default-skin-1.1-20061114.072151-2.jar
  +-- maven-default-skin-1.1-20061114.072151-2.pom
  +-- org
      +-- ...
(the files were meant to be put under
<apache-m2-snapshots-cache>/org/apache/maven/skins/maven-default-skin/1.1-SNAPSHOT/)

Unfortunately I'm not able to purge these files from the repo; the "Remove" entry in the context menu is grayed out. I can only view one of these files or trigger "Zap cache". Trying to view one of these three files results in an error message:

2007-03-14 18:06:14,203 [WARN ] artifactory.resource.ArtifactResource  - Failed to build a ArtifactResource from 'maven-default-skin-1.1-20061114.072151-2.pom'. The groupId, artifactId and version are unreadable..
2007-03-14 18:06:14,203 [ERROR] wicket.RequestCycle   - Failed to execute JcrCallback.
java.lang.RuntimeException: Failed to execute JcrCallback.
        at org.artifactory.jcr.JcrHelper.doInSession(JcrHelper.java :139)
        at org.artifactory.webapp.wicket.browse.BrowseRepoPanel$3.respond(BrowseRepoPanel.java:279)
        at wicket.ajax.AbstractDefaultAjaxBehavior.onRequest(AbstractDefaultAjaxBehavior.java:220)
        at wicket.request.target.component.listener.BehaviorRequestTarget.processEvents(BehaviorRequestTarget.java:97)
        at wicket.request.AbstractRequestCycleProcessor.processEvents(AbstractRequestCycleProcessor.java:89)
        at wicket.RequestCycle.processEventsAndRespond(RequestCycle.java:968)
        at wicket.RequestCycle.step(RequestCycle.java:1041)
        at wicket.RequestCycle.steps(RequestCycle.java:1115)
        at wicket.RequestCycle.request (RequestCycle.java:456)
        at wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:254)
        at wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:124)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter (ApplicationFilterChain.java:202)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
        at org.artifactory.webapp.servlet.RepoFilter.doFilterInternal(RepoFilter.java :77)
        at org.artifactory.webapp.servlet.ArtifactoryFilter.doFilter(ArtifactoryFilter.java:73)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
        at org.artifactory.webapp.servlet.AccessFilter.doFilterInternal(AccessFilter.java:59)
        at org.artifactory.webapp.servlet.ArtifactoryFilter.doFilter (ArtifactoryFilter.java:73)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java :173)
        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
        at org.apache.catalina.core.StandardHostValve.invoke (StandardHostValve.java:126)
        at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
        at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
        at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
        at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection (Http11BaseProtocol.java:664)
        at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
        at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java :80)
        at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
        at java.lang.Thread.run(Unknown Source)
Caused by: java.lang.StringIndexOutOfBoundsException: String index out of range: -1
        at java.lang.String.substring(Unknown Source)
        at org.artifactory.resource.SimpleRepoResource.getRelDirPath(SimpleRepoResource.java:47)
        at org.artifactory.repo.JcrRepo.getPomContent(JcrRepo.java :339)
        at org.artifactory.webapp.wicket.window.WindowPanel.getArtifactMetadataContent(WindowPanel.java:63)
        at org.artifactory.webapp.wicket.browse.BrowseRepoPanel.access$400(BrowseRepoPanel.java:48)
        at org.artifactory.webapp.wicket.browse.BrowseRepoPanel$3$1.doInJcr(BrowseRepoPanel.java:285)
        at org.artifactory.webapp.wicket.browse.BrowseRepoPanel$3$1.doInJcr(BrowseRepoPanel.java:279)
        at org.artifactory.jcr.JcrHelper.doInSession(JcrHelper.java:135)
        ... 32 more
2007-03-14 18:06:17,156 [WARN ] artifactory.resource.ArtifactResource  - Failed to build a ArtifactResource from 'maven-default-skin-1.1-20061114.072151-2-sources.jar '. The groupId, artifactId and version are unreadable..
2007-03-14 18:06:17,156 [WARN ] artifactory.resource.ArtifactResource  - Failed to build a ArtifactResource from 'maven-default-skin-1.1-20061114.072151-2.jar '. The groupId, artifactId and version are unreadable..
2007-03-14 18:06:17,156 [WARN ] artifactory.resource.ArtifactResource  - Failed to build a ArtifactResource from 'maven-default-skin-1.1-20061114.072151-2.pom '. The groupId, artifactId and version are unreadable..


Is this a subsequent error or something different?


Cheers

Thorsten

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Artifactory-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/artifactory-users



--
------------------------
Frederic Simon - Senior Architect
AlphaCSP Israel
Malam Group
Phone: +972 3 5312388  * Fax: +972 3 5312512 Mobile: +972 54 954301
13 Gosh Etzion St.,Givat Shmuel 54030, Israel
http://www.alphacsp.com/ http://www.malam.com/
------------------------