Cannot delete uploaded NPM

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

Cannot delete uploaded NPM

Phil Cryer
Running Artifactory Pro 4.4.2

I'm working on a script to download NPM artifacts from npmjs.org to my
local machine, and then change my registry and publish them to my
artifactory server. I know you can use artifactory as a 'proxy' to get
it for you, but we don't want to do it that way. So, we've tried a few
things, almost have it working correctly, but now we have an error and
we cannot delete the uploaded item that was put in the wrong place. We
have a local repo called npm-local, and cannot delete it, or its
contents. In the browser it looks like this:

npm-local
  boom/-
    boom-0.4.2.tgz
    boom-2.6.1.tgz

Trying to remove either of the tgz files or the boom/- directory gives
the error: "Could not create fsitem"

Trying to remove the npm-local repo gives the error "Repository
'npm-local' does not exist"

I've tried searching for it on the filesystem and I cannot find it -
could I stop artifactory and manually remove some directory to wipe out
all of npm-local? Logs below.

==> logs/artifactory.log <==

2016-02-02 15:07:37,796 [http-nio-127.0.0.100-8081-exec-18] [ERROR]
(o.a.r.c.e.GlobalExceptionMapper:46) - Could not create fsItem

java.lang.IllegalArgumentException: Could not create fsItem

        at
        org.artifactory.storage.db.fs.model.DbFsItemProvider.getOrCreateMutableFsItem(DbFsItemProvider.java:158)
        ~[artifactory-storage-db-4.4.2.jar:na]

        at
        org.artifactory.storage.db.fs.model.DbFileProvider.getOrCreMutableFile(DbFileProvider.java:73)
        ~[artifactory-storage-db-4.4.2.jar:na]

        at
        org.artifactory.repo.db.DbStoringRepoMixin.createOrGetFile(DbStoringRepoMixin.java:649)
        ~[artifactory-core-4.4.2.jar:na]

        at
        org.artifactory.repo.db.DbLocalRepo.createOrGetFile(DbLocalRepo.java:238)
        ~[artifactory-core-4.4.2.jar:na]

        at
        org.artifactory.repo.service.mover.BaseRepoPathMover.getMutableVfsTargetFile(BaseRepoPathMover.java:553)
        ~[artifactory-core-4.4.2.jar:na]

        at
        org.artifactory.repo.service.mover.BaseRepoPathMover.copyFile(BaseRepoPathMover.java:410)
        ~[artifactory-core-4.4.2.jar:na]

        at
        org.artifactory.repo.service.mover.DefaultRepoPathCopier.operationOnFile(DefaultRepoPathCopier.java:42)
        ~[artifactory-core-4.4.2.jar:na]

        at
        org.artifactory.repo.service.mover.BaseRepoPathMover.moveFile(BaseRepoPathMover.java:527)
        ~[artifactory-core-4.4.2.jar:na]

        at
        org.artifactory.repo.service.mover.BaseRepoPathMover.handleFile(BaseRepoPathMover.java:384)
        ~[artifactory-core-4.4.2.jar:na]

        at
        org.artifactory.repo.service.mover.BaseRepoPathMover.moveCopyRecursive(BaseRepoPathMover.java:187)
        ~[artifactory-core-4.4.2.jar:na]

        at
        org.artifactory.repo.service.mover.BaseRepoPathMover.moveOrCopy(BaseRepoPathMover.java:125)
        ~[artifactory-core-4.4.2.jar:na]

        at
        org.artifactory.repo.service.mover.CopyRepoPathService.handleMoveOrCopy(CopyRepoPathService.java:26)
        ~[artifactory-core-4.4.2.jar:na]

        at
        org.artifactory.repo.service.mover.RepoPathMover.moveOrCopy(RepoPathMover.java:95)
        ~[artifactory-core-4.4.2.jar:na]

        at
        org.artifactory.repo.service.mover.CopyRepoPathService.executeOperation(CopyRepoPathService.java:18)
        ~[artifactory-core-4.4.2.jar:na]

        at
        org.artifactory.repo.service.mover.CopyRepoPathService$$FastClassBySpringCGLIB$$c096001b.invoke(<generated>)
        ~[spring-core-4.1.5.RELEASE.jar:na]

        at
        org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:204)
        ~[spring-core-4.1.5.RELEASE.jar:4.1.5.RELEASE]

        at
        org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:649)
        ~[spring-aop-4.1.5.RELEASE.jar:4.1.5.RELEASE]

        at
        org.artifactory.repo.service.mover.CopyRepoPathService$$EnhancerBySpringCGLIB$$d4b249a7.executeOperation(<generated>)
        ~[spring-core-4.1.5.RELEASE.jar:na]

        at
        org.artifactory.repo.service.RepositoryServiceImpl.moveOrCopy(RepositoryServiceImpl.java:1133)
        ~[artifactory-core-4.4.2.jar:na]

        at
        org.artifactory.repo.service.RepositoryServiceImpl.copy(RepositoryServiceImpl.java:1105)
        ~[artifactory-core-4.4.2.jar:na]

        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        ~[na:1.8.0_45]

        at
        sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
        ~[na:1.8.0_45]

        at
        sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        ~[na:1.8.0_45]

        at java.lang.reflect.Method.invoke(Method.java:497)
        ~[na:1.8.0_45]

        at
        org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:317)
        ~[spring-aop-4.1.5.RELEASE.jar:4.1.5.RELEASE]

        at
        org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:190)
        ~[spring-aop-4.1.5.RELEASE.jar:4.1.5.RELEASE

------------------------------------------------------------------------------
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=267308311&iu=/4140
_______________________________________________
Artifactory-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/artifactory-users
Reply | Threaded
Open this post in threaded view
|

Re: Cannot delete uploaded NPM

drorb
This post was updated on .
Artifacts in Artifactory are stored in a checksum storage by their binary checksum. In addition the metadata is stored in a database. Deleting files directly from the checksum storage is not recommended and will leave Artifactory in an inconsistent state.

From the information you posted, it looks like the NPM packages you are trying to delete are in an inconsistent state
Do you have the trash can feature enabled?
If so, can you check if the boom NPM package exists inside the Trash can repository?
Reply | Threaded
Open this post in threaded view
|

Re: Cannot delete uploaded NPM

Phil Cryer
Thanks drorb, I was able to delete it from the trashcan this morning,
and I no longer see it under the repos!

--
http://philcryer.com / 04A1 69CC A79F 7188

On Wed, Feb 3, 2016, at 09:15 AM, drorb wrote:

> Do you have the trashcan feature enabled?
> If so, can you check if the boom NPM package exists inside the trashcan
> repository?
>
>
>
> --
> View this message in context:
> http://forums.jfrog.org/Cannot-delete-uploaded-NPM-tp7580786p7580791.html
> Sent from the Artifactory - Users mailing list archive at Nabble.com.
>
> ------------------------------------------------------------------------------
> Site24x7 APM Insight: Get Deep Visibility into Application Performance
> APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
> Monitor end-to-end web transactions and take corrective actions now
> Troubleshoot faster and improve end-user experience. Signup Now!
> http://pubads.g.doubleclick.net/gampad/clk?id=267308311&iu=/4140
> _______________________________________________
> Artifactory-users mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/artifactory-users

------------------------------------------------------------------------------
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=267308311&iu=/4140
_______________________________________________
Artifactory-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/artifactory-users