Creating an Integration Project¶
An integration project consists of one or several project directories. These directories store the various artifacts that you create for your integration sequence. An integration project can be created as a Maven Multi Module (MMM) project by default. This enables you to add ESB Configs, Composite Exporter, Registry Resources, Connector Exporter, Docker Exporter, and Kubernetes Exporter as sub-modules to the project.
An integration project is the recommended way of creating an “Integration Solution” for the WSO2 Enterprise Integrator as it simplifies the CICD workflow.
Integration project¶
To create an integration project:
-
Open WSO2 Integration Studio and click New Integration Project in the Getting Started view as shown below.
-
In the New Integration Project dialog box that opens, enter a name for your integration project. Select the relevant check boxes if you want to create Registry Resources, Connector Exporter, Docker Exporter, or Kubernetes Exporter in addition to the ESB Configs and Composite Exporter.
Sub projects¶
An integration project can consist of multiple sub-projects. So multiple small projects can exist under a single integration project, where each of these can be dependent on each other and can be grouped together. However, it is not necessary that all sub-projects in an integration project be dependent on every other sub-project.
To add sub-projects to an existing integration project, right-click the integration project and hover over New to see the available project creation options.
Once you create the new sub project, you can see this nested under your integration project folder in the project explorer.
The following table lists out the available projects that can be associated with an integration project.
Sub project | Description |
---|---|
ESB Configs | This project stores the ESB artifacts that are used when defining a mediation flow. This includes addition of any synapse artifacts to your integration project that enables features of a typical ESB.
![]()
|
Composite Exporter | This project allows you to package all the artifacts (stored as sub-projects under the same integration project) into one composite application (C-APP). This C-APP can then be deployed in the WSO2 EI server.
![]() |
Registry Resources | Create this project if you want to create registry resources for your mediation flow. You can later use these registry artifacts when you define your mediation sequences in the ESB config project.
WSO2 registry has three components, namely local, config, and governance. Registry resources and metadata can be added into each component in the registry.
![]() |
Connector Exporter | Create this project if you wish to use EI connectors in your mediation sequence (defined in the ESB config project). All connector artifacts need to be stored in a connector exporter module before packaging.
![]() |
Docker Exporter | Create a Docker Exporter project if you want to deploy your integration solutions inside a Docker environment. This project directory allows you to package multiple integration projects into a single Docker image and then build and push to the Docker registries. For more information on Docker-specific project creation information, see Create Docker Project. |
Kubernetes Exporter | A Kubernetes Exporter project allows you to deploy your integration solutions in a Kubernetes environment. This module allows you to package multiple integration projects and modules into a single Docker image. Also, a file named integration_cr.yaml is generated, which can be used to carry out Kubernetes deployments based on the k8s-ei-operator. For more information on Kubernetes-specific project creation information, see Create Kubernetes Project. |
Maven Multi Module projects¶
The Maven Multi Module (MMM) integration project is the parent project in an integration solution and sub-projects can be added under this parent project. By default, an integration project is an MMM project unless you specify otherwise.
By building the parent MMM project, you can build all the sub-projects in the integration solution simultaneously. This allows you to seamlessly push your integration solutions to a CI/CD pipeline. Therefore, it is recommended as a best practice to create your Config project and other projects inside an MMM integration project.
This allows you to manage multiple projects such as Config projects, Composite Application projects, and Registry Resource projects as a single entity.
Although the recommended approach is to create an integration project, which essentially has all the functionality of an MMM project, you can also create an MMM project separately.
To create the MMM project:
-
Open WSO2 Integration Studio and click New Maven Multi Module Project in the Getting Started view.
-
In the Maven Modules Creation Wizard that opens, enter an artifact ID and other parameters as shown below. The artifact ID will be the name of your MMM project.
-
Click Finish. The MMM project is created in the project explorer.
Now you can create other projects inside the MMM project. For example, let's create a Config project and a Composite Application project.
You can create sub-projects under this parent MMM project.
Moving sub projects to MMM project¶
You can import existing sub projects (ESB Config project, Registry resource project, Composite project, etc.) into an existing Maven Multi Module Project (Integration Project).
Right-click the project, and click Import to Maven Muti Module.
Building selected MMM profiles¶
When you create an integration project, you have a parent MMM project with child modules (sub projects). The MMM project in WSO2 Integration Studio now includes multiple maven profiles. Therefore, you can build selected profiles instead of building the complete MMM project.
Maven profiles:
Profile Name | Description |
---|---|
Solution | Builds the integration artifacts stored in the ESB Config sub project. |
Docker | Builds the integration artifacts stored in the ESB Config and Docker sub projects. |
Kubernetes | Builds the integration artifacts stored in the ESB Config and Kubernetes sub projects. |
To build a selected Maven profile:
Note
When you build a Docker or Kubernetes profile using this method, you need to have Maven 3.5.2 or a later version installed.
- Open a terminal and navigate to the MMM project folder.
-
Execute the following command:
mvn clean install -P <Profile_name>
Tip
If you don't specify a profile name with the
-P
parameter, the default profile will apply.