Hi Andreas,

Thanks for your help.

I actually figured some of this out by trial and error.

With a project creating an aar archive just set packaging to aar when using the 
aar plugin and the aar file gets deployed to the repo.
Then reference this in the embedded axis webapp and the aar file is placed in 
WEB-INF/services as required.

I'm having some trouble with adding mar files though. I tried to add a 
dependency to the org.apache.rampart mar but it couldn't be resolved. So I 
manually installed it but although the war now builds it doesn't add the mar to 
the WEB-INF/modules directory.

I keep hacking away but if anyone wants to put me out of my misery I'd really 
appreciate it.

Thanks,

Ric



----- Original Message ----
From: Andreas Veithen <[EMAIL PROTECTED]>
To: [email protected]
Sent: Tuesday, 18 March, 2008 7:33:33 PM
Subject: Re: Deploying Axis Artifacts to Maven Repo

Ric,

I'm not sure if this answers your question (if not please provide more  
details about what you are trying to achieve), but I can give you a  
few hints:

* There are dedicated Maven plugins to build aar and mar projects:  
axis2-aar-maven-plugin and axis2-mar-maven-plugin. In the Axis2  
sources, you should find some examples of how to use them.

* If you want to bundle aar or mar files into your Web application, I  
think the easiest way is to use the "copy" goal of the maven- 
dependency-plugin. Here is an example:

<plugin>
  <groupId>org.apache.maven.plugins</groupId>
  <artifactId>maven-dependency-plugin</artifactId>
  <executions>
    <execution>
      <id>copy</id>
      <phase>initialize</phase>
      <goals>
        <goal>copy</goal>
      </goals>
      <configuration>
        <artifactItems>
          <artifactItem>
            <groupId>org.apache.synapse</groupId>
            <artifactId>synapse</artifactId>
            <version>${synapse.version}</version>
            <type>mar</type>
            <destFileName>synapse.mar</destFileName>
          </artifactItem>
          <artifactItem>
            <groupId>org.apache.axis2</groupId>
            <artifactId>soapmonitor</artifactId>
            <version>${axis2.version}</version>
            <type>mar</type>
            <destFileName>soapmonitor.mar</destFileName>
          </artifactItem>
        </artifactItems>
        <outputDirectory>${project.build.directory}/webResources/WEB- 
INF/repository/modules</outputDirectory>
      </configuration>
    </execution>
  </executions>
</plugin>

Andreas


On 18 Mar 2008, at 14:59, RICHARD FEATHERSTONE wrote:

> Hi
>
> Can anyone provide any pointers for how they are handling axis2  
> artifacts with maven2.
>
> How are you deploying aar and mar projects to repositories and then  
> adding those artifacts to dependant projects (for example when  
> running axis2 engine embedded in webapp)?
> Do modules and services have to use the mar and aar extensions or  
> could they just be jars?
>
> Thanks in advance.
>
> Ric


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to