camel-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From conflue...@apache.org
Subject [CONF] Apache Camel > Camel Maven Archetypes
Date Tue, 22 May 2012 14:40:00 GMT
<html>
<head>
    <base href="https://cwiki.apache.org/confluence">
            <link rel="stylesheet" href="/confluence/s/2042/9/1/_/styles/combined.css?spaceKey=CAMEL&amp;forWysiwyg=true"
type="text/css">
    </head>
<body style="background: white;" bgcolor="white" class="email-body">
<div id="pageContent">
<div id="notificationFormat">
<div class="wiki-content">
<div class="email">
    <h2><a href="https://cwiki.apache.org/confluence/display/CAMEL/Camel+Maven+Archetypes">Camel
Maven Archetypes</a></h2>
    <h4>Page <b>edited</b> by             <a href="https://cwiki.apache.org/confluence/display/~davsclaus">Claus
Ibsen</a>
    </h4>
        <br/>
                         <h4>Changes (1)</h4>
                                 
    
<div id="page-diffs">
                    <table class="diff" cellpadding="0" cellspacing="0">
    
            <tr><td class="diff-snipped" >...<br></td></tr>
            <tr><td class="diff-unchanged" >| camel-archetype-blueprint | *Camel
2.8:* This archetype is used to create a new Maven project for Camel routes to be running
in OSGi using Blueprint. | <br>| camel-archetype-component | This archetype is used
for creating a new Maven project for Camel [Components]. Use this if there is a component
missing in Camel that you want to create yourself. | <br></td></tr>
            <tr><td class="diff-added-lines" style="background-color: #dfd;">|
camel-archetype-component-scala | *Camel 2.10:* This archetype is used for creating a new
Maven project for Camel [Components] using Scala. Use this if there is a component missing
in Camel that you want to create yourself. | <br></td></tr>
            <tr><td class="diff-unchanged" >| camel-archetype-dataformat | *Camel
2.9:* This archetype is used for creating a new Maven project for Camel [Data Format]s. Use
this if there is a data format missing in Camel that you want to create yourself. | <br>|
camel-archetype-java | This archetype is used to create a new Maven project for Camel routes.
You can use this quickly to get up to speed. | <br></td></tr>
            <tr><td class="diff-snipped" >...<br></td></tr>
    
            </table>
    </div>                            <h4>Full Content</h4>
                    <div class="notificationGreySide">
        <h2><a name="CamelMavenArchetypes-CamelMavenArchetypes"></a>Camel
Maven Archetypes</h2>

<p>Camel is distributed with the following archetypes for Maven end users.</p>

<h3><a name="CamelMavenArchetypes-ArchetypeSupported"></a>Archetype Supported</h3>

<div class='table-wrap'>
<table class='confluenceTable'><tbody>
<tr>
<th class='confluenceTh'> Archetype </th>
<th class='confluenceTh'> Description </th>
</tr>
<tr>
<td class='confluenceTd'> camel-archetype-activemq </td>
<td class='confluenceTd'> This archetype is used to create a new Maven project for Camel
routes. You can use this quickly to get up to speed using Camel with ActiveMQ </td>
</tr>
<tr>
<td class='confluenceTd'> camel-archetype-blueprint </td>
<td class='confluenceTd'> <b>Camel 2.8:</b> This archetype is used to create
a new Maven project for Camel routes to be running in OSGi using Blueprint. </td>
</tr>
<tr>
<td class='confluenceTd'> camel-archetype-component </td>
<td class='confluenceTd'> This archetype is used for creating a new Maven project for
Camel <a href="/confluence/display/CAMEL/Components" title="Components">Components</a>.
Use this if there is a component missing in Camel that you want to create yourself. </td>
</tr>
<tr>
<td class='confluenceTd'> camel-archetype-component-scala </td>
<td class='confluenceTd'> <b>Camel 2.10:</b> This archetype is used for
creating a new Maven project for Camel <a href="/confluence/display/CAMEL/Components" title="Components">Components</a>
using Scala. Use this if there is a component missing in Camel that you want to create yourself.
</td>
</tr>
<tr>
<td class='confluenceTd'> camel-archetype-dataformat </td>
<td class='confluenceTd'> <b>Camel 2.9:</b> This archetype is used for creating
a new Maven project for Camel <a href="/confluence/display/CAMEL/Data+Format" title="Data
Format">Data Format</a>s. Use this if there is a data format missing in Camel that
you want to create yourself. </td>
</tr>
<tr>
<td class='confluenceTd'> camel-archetype-java </td>
<td class='confluenceTd'> This archetype is used to create a new Maven project for Camel
routes. You can use this quickly to get up to speed. </td>
</tr>
<tr>
<td class='confluenceTd'> camel-archetype-scala </td>
<td class='confluenceTd'> This archetype is used to create a new Maven projects for
building Camel routes in the <a href="/confluence/display/CAMEL/Scala+DSL" title="Scala
DSL">Scala DSL</a>.  The archetype contains a sample RouteBuilder as well as configuration
for using the routes from Spring and OSGi. </td>
</tr>
<tr>
<td class='confluenceTd'> camel-archetype-spring </td>
<td class='confluenceTd'> This archetype is used to create a new Maven project for Camel
routes. You can use this quickly to get up to speed. </td>
</tr>
<tr>
<td class='confluenceTd'> camel-archetype-spring-dm </td>
<td class='confluenceTd'> <b>Camel 2.8:</b> This archetype is used to create
a new Maven project for Camel routes to be running in OSGi using Spring DM. </td>
</tr>
<tr>
<td class='confluenceTd'> camel-archetype-war </td>
<td class='confluenceTd'> <b>Camel 2.6 or older:</b> This archetype is used
to create a new Camel project that deploys the <a href="/confluence/display/CAMEL/Web+Console"
title="Web Console">Camel Web Console, REST API</a>, and your routes as a <a href="http://en.wikipedia.org/wiki/Sun_WAR_(file_format)"
class="external-link" rel="nofollow">WAR</a> file. </td>
</tr>
<tr>
<td class='confluenceTd'> camel-archetype-webconsole </td>
<td class='confluenceTd'> <b>Camel 2.7:</b> This archetype is used to create
a new Camel project that deploys the <a href="/confluence/display/CAMEL/Web+Console" title="Web
Console">Camel Web Console, REST API</a>, and your routes as a <a href="http://en.wikipedia.org/wiki/Sun_WAR_(file_format)"
class="external-link" rel="nofollow">WAR</a> file. </td>
</tr>
<tr>
<td class='confluenceTd'> camel-archetype-web </td>
<td class='confluenceTd'> <b>Camel 2.7:</b> This archetype is used to create
a new Camel project that deploys Camel Routes using Spring or Java DSL as a <a href="http://en.wikipedia.org/wiki/Sun_WAR_(file_format)"
class="external-link" rel="nofollow">WAR</a> file. </td>
</tr>
</tbody></table>
</div>



<div class='panelMacro'><table class='infoMacro'><colgroup><col width='24'><col></colgroup><tr><td
valign='top'><img src="/confluence/images/icons/emoticons/information.gif" width="16"
height="16" align="absmiddle" alt="" border="0"></td><td>When using these archetypes,
make sure your package name is not org.apache.camel (or a sub package of this) as this will
instruct Camel to search in its own packages for your routes. This can also cause Camel not
to start, as shown in CAMEL-1197.</td></tr></table></div>

<h3><a name="CamelMavenArchetypes-Snapshotarchetypes"></a>Snapshot archetypes</h3>

<p>If you would like to use an archetype from an unreleased version of Camel, you just
need to let the maven-archetype-plugin know where to look for it. For example, say someone
wanted to create a WAR based project based on Camel 2.9.0. He'd need to use the following
command</p>

<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
<pre class="code-java">
mvn archetype:generate \
  -DarchetypeGroupId=org.apache.camel.archetypes \
  -DarchetypeArtifactId=camel-archetype-war \
  -DarchetypeVersion=2.9.0 \
  -DarchetypeRepository=https:<span class="code-comment">//repository.apache.org/content/groups/snapshots-group</span>
</pre>
</div></div>

<p>Notice that archetypes will now be downloaded from <a href="https://repository.apache.org/content/groups/snapshots-group"
class="external-link" rel="nofollow">Apache's snapshot repo</a> instead of <a
href="http://repo1.maven.org/maven2" class="external-link" rel="nofollow">Maven central</a>.</p>

<p>When the project is created, you may need to add another repository to the pom.xml
file. This is to load a SNAPSHOT version of the camel-maven-plugin </p>

<div class="code panel" style="border-width: 1px;"><div class="codeContent panelContent">
<pre class="code-java">
&lt;pluginRepositories&gt;
  &lt;pluginRepository&gt;
    &lt;releases&gt;
      &lt;enabled&gt;<span class="code-keyword">false</span>&lt;/enabled&gt;
    &lt;/releases&gt;
    &lt;snapshots/&gt;
    &lt;id&gt;Apache Snapshot Repository&lt;/id&gt;
    &lt;url&gt;http:<span class="code-comment">//repository.apache.org/snapshots&lt;/url&gt;
</span>  &lt;/pluginRepository&gt;
&lt;/pluginRepositories&gt;
</pre>
</div></div>

<h3><a name="CamelMavenArchetypes-Examples"></a>Examples</h3>
<p>See <a href="/confluence/display/CAMEL/Creating+a+new+Spring+based+Camel+Route"
title="Creating a new Spring based Camel Route">Creating a new Spring based Camel Route</a>
for a sample how to use the camel-archetype-java and camel-archetype-spring archetypes.</p>
    </div>
        <div id="commentsSection" class="wiki-content pageSection">
        <div style="float: right;">
            <a href="https://cwiki.apache.org/confluence/users/viewnotifications.action"
class="grey">Change Notification Preferences</a>
        </div>
        <a href="https://cwiki.apache.org/confluence/display/CAMEL/Camel+Maven+Archetypes">View
Online</a>
        |
        <a href="https://cwiki.apache.org/confluence/pages/diffpagesbyversion.action?pageId=87085&revisedVersion=19&originalVersion=18">View
Changes</a>
                |
        <a href="https://cwiki.apache.org/confluence/display/CAMEL/Camel+Maven+Archetypes?showComments=true&amp;showCommentArea=true#addcomment">Add
Comment</a>
            </div>
</div>
</div>
</div>
</div>
</body>
</html>

Mime
View raw message