Update transportpce version and features list
[integration/distribution.git] / docs / add-project-distribution.rst
index dd1e6485d1af96bf1f01427f9050d753f8c8c1c7..5787f663a8e0f215ed66ebeda8460950ab7e7197 100644 (file)
@@ -6,136 +6,235 @@ Add Projects to distribution
 Managed Projects
 ----------------
 
-Managed projects must be in the distribution. Follow the next steps below
+Add features to distribution
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+Managed projects must be in the distribution. Follow the steps below
 to add your karaf features to distribution:
 
 #. Download int/dist repository:
 
-.. code-block:: bash
+   .. code-block:: bash
 
-    git clone ssh://<user>@git.opendaylight.org:29418/integration/distribution
+      git clone ssh://<user>@git.opendaylight.org:29418/integration/distribution
 
 #. Make sure the projects you depend are already in the pom file:
 
-.. code-block:: bash
+   .. code-block:: bash
 
-    features/repos/index/pom.xml
+      features/repos/index/pom.xml
 
 #. Check your project version is correct in the file:
 
-.. code-block:: bash
+   .. code-block:: bash
 
-    artifacts/upstream/properties/pom.xml
+      artifacts/upstream/properties/pom.xml
 
 #. Declare your feature repositories and user-facing features dependencies:
 
-If your project artifacts pom.xml contains your karaf feature repos and features,
-just add your project artifacts dependency in:
+   If your project artifacts pom.xml contains your karaf feature repos and features,
+   just add your project artifacts dependency in:
 
-.. code-block:: bash
+   .. code-block:: bash
 
-    artifacts/upstream/artifacts/pom.xml
+      artifacts/upstream/artifacts/pom.xml
 
-Otherwise add your project feature repositories and your user-facing features to:
+   Otherwise add your project feature repositories and your user-facing features to:
 
-.. code-block:: bash
+   .. code-block:: bash
 
-    artifacts/upstream/feature-repos/pom.xml
-    artifacts/upstream/single-features/pom.xml
+      artifacts/upstream/feature-repos/pom.xml
+      artifacts/upstream/single-features/pom.xml
 
-.. note:: Always add your maven dependencies in alphabethical order.
-          This also applies to the next steps.
+   .. note:: Always add your maven dependencies in alphabethical order.
+             This also applies to the next steps.
 
 #. Add your feature repositories in:
 
-.. code-block:: bash
+   .. code-block:: bash
 
-    features/repos/index/pom.xml
+      features/repos/index/pom.xml
 
 #. Add your user facing features in either:
 
-.. code-block:: bash
+   .. code-block:: bash
 
-    features/singles/odl-integration-compatible-with-all/pom.xml
+      features/singles/odl-integration-compatible-with-all/pom.xml
 
-if your feature is compatible.
+   if your feature is compatible.
 
-.. code-block:: bash
+   .. code-block:: bash
 
-    features/singles/odl-integration-all/pom.xml
+      features/singles/odl-integration-all/pom.xml
 
-if your feature is not compatible.
+   if your feature is not compatible.
 
-.. note:: You do not need to add a feature if it is already contained
-          in another feature you have already included.
+   .. note:: You do not need to add a feature if it is already contained
+             in another feature you have already included.
 
-Remember compatible features are those that can co-exist with other features in ODL because:
+   Remember compatible features are those that can co-exist with other features in ODL because:
 
-* They do not interfere with any other feature
-* They are not network intrusive (e.g. configure network devices or push flows out-of-the-box)
+   * They do not interfere with any other feature
+   * They are not network intrusive (e.g. configure network devices or push flows out-of-the-box)
 
 #. Push changes to int/dist and wait for patch verification and review.
 
-Once the patch is merged your project will be part of the OpenDaylight distribution
-and join the distribution-check verification.
+   Once the patch is merged your project will be part of the OpenDaylight managed distribution which is
+   normally available in nexus managed-distribution_ and will join the distribution-check verification.
+
+Trigger distribution build
+~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+Once the project is in the distribution it is recommended to build and publish a new distribution
+every time a merge happens in the project. Follow the steps below to add this trigger:
+
+#. Download releng/builder repository:
+
+   .. code-block:: bash
+
+      git clone ssh://<user>@git.opendaylight.org:29418/releng/builder
+
+#. Add your merge job in following file under distribution-managed section:
 
+   .. code-block:: bash
+
+      jjb/integration/distribution/distribution-jobs.yaml
+
+      - project:
+          name: distribution-managed
+          ...
+          stream:
+            - fluorine:
+                branch: 'master'
+                dependencies: >
+                    aaa-merge-{stream},
+                    bgpcep-merge-{stream},
+                    coe-merge-{stream},
+          ...
+
+#. Push changes to releng/builder and wait for patch verification and review.
 
 Self-Managed Projects
 ---------------------
 
-Self-Managed projects must only be in the distribution if they want to be packaged in distrbution
+Add features to distribution
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+Self-Managed projects must only be in the distribution if they want to be packaged in distribution
 and released at the same time as the Managed projects do.
 
 Follow the next steps to add your karaf features to the OpenDaylight distribution:
 
 #. Download int/dist repository:
 
-.. code-block:: bash
+   .. code-block:: bash
+
+      git clone ssh://<user>@git.opendaylight.org:29418/integration/distribution
+
+#. Add your feature repository in:
+
+   .. code-block:: bash
+
+      opendaylight/pom.xml
 
-    git clone ssh://<user>@git.opendaylight.org:29418/integration/distribution
+   .. note:: Always add your maven dependencies in alphabethical order.
+             This also applies to the next steps.
 
-#. Add your feature reporsitory in:
+#. Push changes to int/dist and wait for patch verification and review.
+
+   Once the patch is merged your project will be part of the new OpenDaylight distribution which is
+   normally available in nexus full-distribution_.
+
+   .. note:: In order to install a Self-Managed feature, you have to first install the feature repository
+             in karaf, the example below shows how to install a repository from the karaf console.
+
+   .. code-block:: bash
 
-.. code-block:: bash
+      opendayligt>feature:repo-add mvn:org.opendaylight.sxp/features-sxp//xml/features
 
-    opendaylight/pom.xml
+   .. note:: If the feature version is not specified in the URL (see example above), Karaf will use
+             the latest version (normally only one stored) in the the system folder.
 
-.. note:: Always add your maven dependencies in alphabethical order.
-          This also applies to the next steps.
+   .. note:: You can alternatively add the repository in the karaf boot file etc/org.apache.karaf.features.cfg
+
+Add features to sanity test
+~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+Distribution sanity test runs once a day to verify all projects features, managed
+and sef-managed, can be installed with no issues. Follow below steps to add your
+features to the sanity test.
 
 #. Download releng/builder repository:
 
-.. code-block:: bash
+   .. code-block:: bash
+
+      git clone ssh://<user>@git.opendaylight.org:29418/releng/builder
+
+#. Open the distribution-jobs.yaml file:
 
-    git clone ssh://<user>@git.opendaylight.org:29418/releng/builder
+   .. code-block:: bash
 
-#. Add your feature repo and user-facing features in:
+      jjb/integration/distribution/distribution-jobs.yaml
 
-.. code-block:: bash
+   Add your feature repo and user-facing features in the distribution section:
 
-    jjb/releng-defaults.yaml
+   .. code-block:: bash
+
+      stream:
+        - fluorine:
+            branch: 'master'
+            karaf-version: odl
+            # Self-Managed projects repos and features:
+            sm-repos: >
+                mvn:org.opendaylight.sxp/features-sxp//xml/features,
+                mvn:org.opendaylight.tsdr/features-tsdr//xml/features
+            sm-features: >
+                odl-sxp-routing,
+                odl-tsdr-core,
+                odl-tsdr-openflow-statistics-collector,
+                odl-tsdr-netflow-statistics-collector
+
+   .. note:: If the feature version is not specified in the URL (see example above), Karaf will use
+             the latest version (normally only one stored) in the the system folder.
+
+#. Push changes to releng/builder and wait for patch verification and review.
+
+   Once the patch is merged your project will be tested in the distribution-sanity_.
+
+Trigger distribution build
+~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+Once the project is in the distribution it is recommended to build and publish a new distribution
+every time a merge happens in the project. Follow the steps below to add this trigger:
+
+#. Download releng/builder repository:
 
-See this example for the file section:
+   .. code-block:: bash
 
-.. code-block:: bash
+      git clone ssh://<user>@git.opendaylight.org:29418/releng/builder
 
-    # Self-Managed projects features
-    sm-repos: >
-        mvn:org.opendaylight.sxp/features-sxp/1.7.0-SNAPSHOT/xml/features
+#. Open the distribution-jobs.yaml file:
 
-    sm-features: >
-        odl-sxp-controller
+   .. code-block:: bash
 
-#. Push changes to int/dist and releng/builder and wait for patch verification and review.
+      jjb/integration/distribution/distribution-jobs.yaml
 
-Once the patches are merged your project will be part of the OpenDaylight distribution
-and join the distibution-sanity verification.
+   And add your merge job in the distribution-full section:
 
-.. note:: In order to install a Self-Managed feature, you have to first install the feature repository
-          in karaf, the example below shows how to install a repository from the karaf console.
+   .. code-block:: bash
 
-.. code-block:: bash
+      - project:
+          name: distribution-full
+          ...
+          stream:
+            - fluorine:
+                branch: 'master'
+                dependencies: >
+                    sxp-merge-{stream},
+           ...
 
-   opendayligt>feature:repo-add mvn:org.opendaylight.sxp/features-sxp/1.7.0-SNAPSHOT/xml/features
+#. Push changes to releng/builder and wait for patch verification and review.
 
-.. note:: You can alternatively add the repository in the karaf boot file etc/org.apache.karaf.features.cfg
+.. _managed-distribution: https://nexus.opendaylight.org/content/repositories/opendaylight.snapshot/org/opendaylight/integration/karaf
+.. _full-distribution: https://nexus.opendaylight.org/content/repositories/opendaylight.snapshot/org/opendaylight/integration/opendaylight
+.. _distribution-sanity: https://jenkins.opendaylight.org/releng/view/Sanity