You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by D D <da...@gmail.com> on 2010/08/30 15:53:48 UTC

RAR artifact

Hello,

I wonder if someone could help me with rar artifact. I used the default
plugin available on Maven's website. (
http://maven.apache.org/plugins/maven-rar-plugin/) Technically the packaging
type is jar but the artifact built actually is a rar file that is renamed to
jar when installed in the repository. .

My problem is that I can't set dependency on that rar file. The compiled
code is in a jar inside the rar. Any idea what I'm doing wrong?

Thanks,
Dave

Re: RAR artifact

Posted by Stephen Connolly <st...@gmail.com>.
On 30 August 2010 15:06, Wendy Smoak <ws...@gmail.com> wrote:

> On Mon, Aug 30, 2010 at 9:53 AM, D D <da...@gmail.com> wrote:
> > My problem is that I can't set dependency on that rar file. The compiled
> > code is in a jar inside the rar. Any idea what I'm doing wrong?
>
> Then you should probably build the jar as a separate module and have
> it as a dependency from both the rar and the other thing you are
> trying to build.
>
> If that is impossible, then check out the way the war plugin is able
> to deploy both the war _and_ a jar containing the classes.  That
> behavior could probably be added to the rar plugin.
>

IIRC, the rar plugin already has that capability, but it is somewhat less
than stellar in real use.  in any case two modules is the way to go, esp if
you are using openejb to test your rar from junit tests...

[Note to self, must write up a blog post on end-to-end testing of a
enterprise-data-source <--> jca <--> ejb <--> web <--> browser <-->selenium
test case I have using jetty (for a mock enterprise data source), openejb
(for the jca & ejb container), jetty (2nd instance for the web container)
all within a single JVM!

-Stephen


> --
> Wendy
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>

Re: RAR artifact

Posted by Wendy Smoak <ws...@gmail.com>.
On Mon, Aug 30, 2010 at 9:53 AM, D D <da...@gmail.com> wrote:
> My problem is that I can't set dependency on that rar file. The compiled
> code is in a jar inside the rar. Any idea what I'm doing wrong?

Then you should probably build the jar as a separate module and have
it as a dependency from both the rar and the other thing you are
trying to build.

If that is impossible, then check out the way the war plugin is able
to deploy both the war _and_ a jar containing the classes.  That
behavior could probably be added to the rar plugin.

-- 
Wendy

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: RAR artifact

Posted by Stephen Connolly <st...@gmail.com>.
the correct packaging for a rar is to have the compiled classes as a jar
file inside the rar file.  You probably want two modules in your case...
first module is packaging:jar and compiles the classes.  second module is
the rar module and it depends on the first and just adds the rar descriptor.

-Stephen

On 30 August 2010 14:53, D D <da...@gmail.com> wrote:

> Hello,
>
> I wonder if someone could help me with rar artifact. I used the default
> plugin available on Maven's website. (
> http://maven.apache.org/plugins/maven-rar-plugin/) Technically the
> packaging
> type is jar but the artifact built actually is a rar file that is renamed
> to
> jar when installed in the repository. .
>
> My problem is that I can't set dependency on that rar file. The compiled
> code is in a jar inside the rar. Any idea what I'm doing wrong?
>
> Thanks,
> Dave
>