Skip to content
Skip to breadcrumbs
Skip to header menu
Skip to action menu
Skip to quick search
Quick Search
Browse
Pages
Blog
Labels
Attachments
Mail
Advanced
What’s New
Space Directory
Feed Builder
Keyboard Shortcuts
Confluence Gadgets
Log In
Dashboard
Cargo
Copy Page
You are not logged in. Any changes you make will be marked as
anonymous
. You may want to
Log In
if you already have an account. You can also
Sign Up
for a new account.
This page is being edited by
.
Paragraph
Paragraph
Heading 1
Heading 2
Heading 3
Heading 4
Heading 5
Heading 6
Preformatted
Quote
Bold
Italic
Underline
More colours
Strikethrough
Subscript
Superscript
Monospace
Clear Formatting
Bullet list
Numbered list
Outdent
Indent
Align left
Align center
Align right
Link
Table
Insert
Insert Content
Image
Link
Attachment
Symbol
Emoticon
Wiki Markup
Horizontal rule
tinymce.confluence.insert_menu.macro_desc
Info
JIRA Issue
Status
Gallery
Tasklist
Table of Contents
Other Macros
Page Layout
No Layout
Two column (simple)
Two column (simple, left sidebar)
Two column (simple, right sidebar)
Three column (simple)
Two column
Two column (left sidebar)
Two column (right sidebar)
Three column
Three column (left and right sidebars)
Undo
Redo
Find/Replace
Keyboard Shortcuts Help
<p>Before you start you might be interested in reading the <a class="confluence-link" href="/display/CARGO/Project+Structure" data-linked-resource-id="22380" data-linked-resource-type="page" data-linked-resource-default-alias="Project Structure" data-base-url="http://docs.codehaus.org">Project Structure</a> tutorial which shows the directory organization of the Cargo sources. The <a class="confluence-link" href="/display/CARGO/Building" data-linked-resource-id="37375" data-linked-resource-type="page" data-linked-resource-default-alias="Building" data-base-url="http://docs.codehaus.org">Building</a> tutorial explains how to build Cargo from sources and the <a class="confluence-link" href="/display/CARGO/Contributing" data-linked-resource-id="38986" data-linked-resource-type="page" data-linked-resource-default-alias="Contributing" data-base-url="http://docs.codehaus.org">Contributing</a> tutorial explains what rules to follow when contributing code.</p> <p>Here are some quick steps to follow if you wish to add support for a new container in Cargo:</p> <ul> <li>Subscribe to the cargo dev mailing list and ask as many question you'd like there! <img class="emoticon emoticon-smile" data-emoticon-name="smile" border="0" src="/s/en_GB/3278/15/_/images/icons/emoticons/smile.png" alt="(smile)" title="(smile)" /></li> <li>Create a JIRA issue on <a href="https://jira.codehaus.org">https://jira.codehaus.org</a> (you'll need to register). We'll then add you to the cargo-developers group in JIRA and assign the issue to you</li> <li>Checkout Cargo from <a class="confluence-link" href="/display/CARGO/SVN" data-linked-resource-id="8857" data-linked-resource-type="page" data-linked-resource-default-alias="SVN" data-base-url="http://docs.codehaus.org">SVN</a> trunk</li> <li>Understand the Cargo project's <a class="confluence-link" href="/display/CARGO/Project+Structure" data-linked-resource-id="22380" data-linked-resource-type="page" data-linked-resource-default-alias="Project Structure" data-base-url="http://docs.codehaus.org">directory structure</a>. Container implementations are located in <code>trunk/core/containers/<em>ContainerName</em></code>.</li> <li>Have a look at existing container implementations <ul> <li>Some containers are simple to read and understand; for example <strong>jo</strong> or <strong>glassfish</strong></li> <li>Some other containers are much more feature-complete (remote deployers, datasources, etc.); for example <strong>tomcat</strong> or <strong>jonas</strong>.</li> </ul> </li> <li>Create your container's Maven module, with its package inside.</li> <li>Create the following classes: <ul> <li>A <a class="confluence-link" href="/display/CARGO/Container" data-linked-resource-id="38535" data-linked-resource-type="page" data-linked-resource-default-alias="Container" data-base-url="http://docs.codehaus.org">container</a> implementation class named <code>_ServerNameNxContainerType_Container</code> where <code>ServerName</code> is the name of the container, <code>Nx</code> the version and <code>ContainerType</code> the type of container (<code>InstalledLocal</code> or <code>Remote</code>). For example: <code>JBoss3xLocalContainer</code>.</li> <li>One or several <a class="confluence-link" href="/display/CARGO/Configuration" data-linked-resource-id="13113" data-linked-resource-type="page" data-linked-resource-default-alias="Configuration" data-base-url="http://docs.codehaus.org">configuration</a> implementation classes named <code>_ServerNameConfigurationType_Configuration</code> where <code>ConfigurationType</code> can be <code>StandaloneLocal</code>, <code>ExistingLocal</code> or <code>Runtime</code>. For example <code>JBossStandaloneLocalConfiguration</code>.</li> <li>One or several <a class="confluence-link" href="/display/CARGO/Deployer" data-linked-resource-id="22203" data-linked-resource-type="page" data-linked-resource-default-alias="Deployer" data-base-url="http://docs.codehaus.org">deployer</a> implementation classes named <code>_ServerNameDeployerType_Deployer</code> where <code>DeployerType</code> can be <code>InstalledLocal</code> or <code>Remote</code>. For example: <code>JBossInstalledLocalDeployer</code>. <ul> <li>Cargo has an SPI that you should use and that should make it easy for you. Your container class should extend <code>org.codehaus.cargo.container.spi.Abstract_ContainerType_Container</code> and your configuration class should extend <code>org.codehaus.cargo.container.spi.configuration.Abstract_ConfigurationType_Configuration</code>.</li> </ul> </li> <li>Finally, implement the <code>FactoryRegistry</code> that will register your container to CARGO and make sure you've defined a link to your container's factory registry in <code>src/main/resources/META-INF/services/org.codehaus.cargo.generic.AbstractFactoryRegistry</code>.</li> </ul> </li> <li>Run the Cargo <a class="confluence-link" href="/display/CARGO/Building" data-linked-resource-id="37375" data-linked-resource-type="page" data-linked-resource-default-alias="Building" data-base-url="http://docs.codehaus.org">build</a> to ensure everything is working. You'll probably find that you haven't followed the Cargo project's coding conventions... Fix those and build again until it passes! <img class="emoticon emoticon-wink" data-emoticon-name="wink" border="0" src="/s/en_GB/3278/15/_/images/icons/emoticons/wink.png" alt="(wink)" title="(wink)" /> Please note that when you run the build it'll automatically run the samples test suites in your container (provided you've added your container to the generic API as described in the previous step and provided you've defined the right capabilities for your container). See the <a class="confluence-link" href="/display/CARGO/Building" data-linked-resource-id="37375" data-linked-resource-type="page" data-linked-resource-default-alias="Building" data-base-url="http://docs.codehaus.org">Building</a> page for more details on the build.</li> <li>Once built, add your new container to the <code>uberpom</code> and check that the <code>uberjar</code> is still looking fine.</li> <li>Once added to the <code>uberpom</code>, add your container's download URL to the <code>samples</code> and add profiles for it. <ul> <li>As soon as you add your container to the <code>samples</code>, the Maven build will automatically attempt to configure, start, deploy some test applications, test them and stop your container.</li> </ul> </li> <li>Register on <a href="https://docs.codehaus.org/display/HAUS/Home">Codehaus' confluence</a>. Once this is done we'll add you to the <code>cargo-developers</code> user group so that you have the right to edit yourself the Cargo web site pages</li> <li>Document the new container on the <a href="https://docs.codehaus.org/display/CARGO/Home">Cargo web site</a></li> <li>Create a SVN patch and attach it to the JIRA issue you have created above</li> <li>Once the patch has been accepted: <ul> <li>Add the container to the <a href="https://docs.codehaus.org/pages/editpage.action?spaceKey=CARGO&title=Containers">Containers list</a> on the main web site</li> <li>Add the container to the <a href="https://docs.codehaus.org/pages/editpage.action?spaceKey=CARGO&title=Navigation">Navigation page</a> (left side of the CARGO Web site)</li> <li>Add the container to the <a href="https://docs.codehaus.org/pages/editpage.action?spaceKey=CARGO&title=Downloads">Downloads page</a></li> <li>Add the container to the <a href="http://bamboo.ci.codehaus.org/browse/CARGO">Continous integration</a> so that its integrity can be checked at each build <ul> <li>Note that each container is built daily, each of them separated by 45 minutes. Just put your container as last, so it is tested daily without blocking the whole CI environment.</li> </ul> </li> </ul> </li> </ul> <p>Thanks and happy coding!</p>
Please type the word appearing in the picture.
Attachments
Labels
Location
Watch this page
< Edit
Preview >
Loading…
Save
Cancel
Next hint
search
attachments
weblink
advanced