This documentation is for WSO2 Private PaaS 4.0.0. View documentation for the latest release.
Page Comparison - Building from Source (v.5 vs v.6) - WSO2 Private PaaS 4.0.0 - WSO2 Documentation

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

WSO2 invites you to contribute by checking out the source of WSO2 Private PaaS from the GitHub, building the product and making changes. You can contribute back by sending a pull a request for review. For information on using Git version control system, go to the the Git documentation.

Info

Building from source is optional. Users who do not want to make changes to the source

...

code can simply download the binary distribution of the product and install it.

Downloading the source

  1. Clone WSO2 Private PaaS Git repository to a folder of your choice.  The location of the extracted source is referred to as  <PRIVATE_PAAS_HOME>.
    git clone https://github.com/wso2/private-paas.git <local-folder-name>
    For example: 
    git clone https://github.com/wso2/private-paas.git PRIVATE_PAAS_HOME

    Info

      Make sure that you have setup Git properly. For more information, go to  Getting Started with Git .

  2. Navigate to the <PRIVATE_PAAS_HOME> directory.
    cd PRIVATE_PAAS_HOME

  3. Checkout WSO2 Private PaaS 4.0.0 tag to a folder of your choice:
    git checkout -b <REMOTE_BRANCH/TAG> <LOCAL_BRANCH>
    For example:
    git checkout -b 4.0.0 4.0.0

...

  1. To edit the source code in your IDE, set up your development environment by running one of the following commands:

    If you are using a later Eclipse version and if you get errors (library path etc.) when trying to import the source code using the Existing Projects into Workspace option, you can solve them by importing the source code as a Maven project. To do this; open Eclipse and click Import in the File menu and then click Existing Maven Projects as shown below: 

    Image Modified

  2. Add the required changes to the source code.

...

Info

Prerequisites

  • Install Maven and JDK. See Installation Prerequisites for compatible versions. 
  • Set the environment variable MAVEN_OPTS="-Xms768m -Xmx3072m -XX:MaxPermSize=1200m" to avoid the maven OutOfMemoryError.
  • Make sure the build server has an active Internet connection to download dependencies while building.

The following are two methods in which you can build the source and copy the Apache Stratos Cartridge Agent, Apache Stratos Load Balancer and Apache Stratos distribution files. Use either one of the following methods to carry out this task:

Table of Contents
maxLevel5
minLevel5
 

Method 1 - Building the source and manually copy the Apache Stratos distributions
  1. Run the  build.sh script  script that is located in the  <PRIVATE_PAAS_HOME>/ source  directory to build the source.
    ./build.sh -b

  2. Manually copy the Apache the Apache Stratos Cartridge Agent, Apache Stratos Load Balancer and Apache Stratos distributions to the  <PRIVATE_PAAS_HOME>/packs directory directory. The latter mentioned Apache Stratos distributions can be found in the following directories:

    ProductLocation
    Apache Stratos Cartridge Agent<PRIVATE_PAAS_HOME>/source/products/cartridge-agent/modules/distribution/target/apache-stratos-cartridge-agent-4.0.0-bin.zip
    Apache Stratos Load Balancer<PRIVATE_PAAS_HOME>/source/products/load-balancer/modules/distribution/target/apache-stratos-load-balancer-4.0.0.zip
    Apache Stratos<PRIVATE_PAAS_HOME>/source/products/stratos/modules/distribution/target/apache-stratos-4.0.0.zip
Method 2 - Simultaneously building the source and copying the required product distributions

Run the following command to simultaneously build the source and copy the required product distributions (namely Apache Stratos Cartridge Agent, Apache Stratos Load Balancer and Apache Stratos distributions) to the  <PRIVATE_PAAS_HOME>/packs directory: 

. /build.sh -c

 

Committing your changes

You can contribute to WSO2 products by committing your changes to GitHub. Whether you are a committer or a non-committer, you can contribute with your code as explained in the Get Involved section.