[shrinkwrap-issues] [JBoss JIRA] (SHRINKRES-188) Support installation of an artifact to a local repository

Tomas Rohovsky (JIRA) issues at jboss.org
Thu Jul 31 10:14:30 EDT 2014


    [ https://issues.jboss.org/browse/SHRINKRES-188?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12989509#comment-12989509 ] 

Tomas Rohovsky edited comment on SHRINKRES-188 at 7/31/14 10:14 AM:
--------------------------------------------------------------------

My use case is testing of KieContainer in Drools. I assemble an artifact (KieModule) by ShrinkWrap, so I have a JavaArchive. Then I would like to install the artifact to a local repository. It would be nice to just use SWR to install the JavaArchive. Currently, I am doing that by exporting of the archive to a temporary directory and then I am using Runtime.getRuntime().exec(	String.format("mvn install:install-file -Dfile=target/%s -DpomFile=src/main/resources/pom.xml", name));. I see three advantages of having installation of the artifact in SWR:

1. The artifact doesn't have to be stored temporarily before installing of it, because SWR already knows what JavaArchive is. 
2. exec() does't have to be called. It might be disallowed by a security manager to call it.
3. Maven doesn't have to be installed in an environment.

As you said, the name of this project infers that it is primary for resolving of artifacts. So, it is a bit out of scope, but still useful.


was (Author: trohovsky):
My use case is testing of KieContainer in Drools. I assemble artifact (KieModule) by ShrinkWrap, so I have a JavaArchive. Then I would like to install the artifact to a local repository. It would be nice to just use SWR to install the JavaArchive. Currently, I am doing that by exporting of the archive to a temporary directory and then I am using Runtime.getRuntime().exec(	String.format("mvn install:install-file -Dfile=target/%s -DpomFile=src/main/resources/pom.xml", name));. I see three advantages of having installation of the artifact in SWR:

1. The artifact doesn't have to be stored temporarily before installing of it, because SWR already knows what JavaArchive is. 
2. exec() does't have to be called. It might be disallowed by a security manager to call it.
3. Maven doesn't have to be installed in an environment.

As you said, the name of this project infers that it is primary for resolving of artifacts. So, it is a bit out of scope, but still useful.

> Support installation of an artifact to a local repository
> ---------------------------------------------------------
>
>                 Key: SHRINKRES-188
>                 URL: https://issues.jboss.org/browse/SHRINKRES-188
>             Project: ShrinkWrap Resolvers
>          Issue Type: Feature Request
>      Security Level: Public(Everyone can see) 
>          Components: impl-maven
>    Affects Versions: 2.2.0-alpha-2
>            Reporter: Tomas Rohovsky
>
> It would be a nice feature to provide installation of an artifact to a local repository.



--
This message was sent by Atlassian JIRA
(v6.2.6#6264)


More information about the shrinkwrap-issues mailing list