WSO2 Carbon Studio in a Nutshell

Archived Content
This article is provided for historical perspective only, and may not reflect current conditions. Please refer to relevant product page for more up-to-date product information and resources.
  • By Dakshitha Ratnayake
  • 29 Aug, 2011


The WSO2 Carbon platform consists of a number middleware products that are different to each other in terms of functionality, look-and-feel and configuration (of course they all lie on the same Carbon platform). These products require their own set of configuration files or 'artifacts' to be deployed within them in order to provide customized services to the user. The users will have to deploy these artifacts in order to generate services. Sometimes, creating lengthy artifacts, creating many artifacts that are different to each other and deploying them to different servers/products is time consuming and cumbersome. Therefore, the need for a tool that can ease the creation and deployment process for these said artifacts arose. WSO2 Carbon Studio was created to fulfil this requirement. 


What is WSO2 Carbon Studio


Simply put, Carbon Studio is an Eclipse plugin, just like any 3rd party plugin that you can install in Eclipse. When you install the plugin to the Eclipse IDE, you will be able to work in an SOA development environment along with the standard features of Eclipse. For detailed instruction on how to install WSO2 Carbon Studio, please refer to the article: How to install Carbon Studio.


The Main Features of Carbon Studio


Let's first take a look at the WSO2 product stack.



The lean, complete, OSGi-based WSO2 Carbon platform includes a range of SOA products that deliver messaging, data, business, presentation, identity, security, governance, monitoring and management services. You can select and use the services to fulfill your unique middleware requirements. Maybe all you need is just an Application Server to host your applications or an Enterprise Service Bus and a Data Services Server. The full stack or individual products of WSO2 middleware products stack covers a comprehensive array of enterprise middleware needs.


With Carbon Studio, you can easily create artifacts for the WSO2 Carbon platform. The types of artifacts are mostly java-based or xml configurations designed differently for each of the products in the Carbon platform. Development of these artifacts is surprisingly easy with the graphical editors simplifying the experience of editing xml-based configurations. The availability of easy development and debugging capabilities of Java-based artifacts such as Axis2-based services, registry handlers, data validators and synapse mediators, makes it so much better than doing everything manually. You can even run your products/servers within Carbon Studio and test your applications. Carbon Studio is all about making your life easier with respect to creating your SOA applications for the WSO2 Carbon platform.

How to Create an Artifact

You can easily create a custom artifact such as a data service, an endpoint, a bpel process or any other artifact. For example, say you need to create a data service. The configuration files for a data service is a dbs file (with the extension dbs e.g. dataservice1.dbs). dbs files are used in the WSO2 Data Services Server to save the information about databases, queries and the data service operations that are linked to those queries. To create a dbs file you can either go through the wizard in the Data Services Server to create a data service or else you can use Carbon Studio to create a dbs file.  



To create a dbs file in Carbon Studio you first need to create a CApp project. The abbreviation CApp stands for Carbon Application. It's just like any other Java project that you can create within Eclipse, except you can create Carbon Artifacts inside them. Before you create a data service or any other artifact file you need to have a CApp created.


This is how you create a CApp ->

When you right-click on your CApp, you can select an artifact from an array of Carbon artifacts as shown below. Choose what you want to create . You can have different types of artifacts in one CApp.

The Artifacts are Created. What's Next?


Once the CApp and the artifacts are created, how do you deploy them into their respective servers?  


A dbs file must be deployed in the Data Services Server and a bpel process must be deployed in the BPS Server etc. But, your CApp contains different artifacts. The good news is you don’t have to manually filter these different articles and deploy them yourself. You can deploy the whole container into the servers and the servers will take care of the whole filtering process and will only take the artifacts that belong to them. As a result, when you want to deploy this CApp project into different servers, you must first convert the CApp project to an archive file. The archive file is known as a CAR file, which is short for Carbon Archive. The CAR file is what needs to get into the servers. 


There are two ways to deploy artifacts. You can add the servers from within Carbon Studio, add the Carbon Applications (CApps) to the servers and start the servers. The artifacts will be deployed in their respective servers. Or else, you need to create a CAR in order to deploy it outside Carbon Studio on to your server instance like I mentioned earlier.


In a nutshell, you can simply create the relevant artifacts within Carbon Studio, create many of them in one CApp, create a CAR file from the CApp and deploy the CAR into you servers. Your services will be instantly deployed for you!

The Biggest Advantage of Carbon Studio

Considering the above facts, the biggest advantage of Carbon Studio is, if you know your way around the Carbon platform or if you know your way around a particular server that you are interested in such as the ESB server, you can create synapse.xml or sequence.xml files quickly and deploy them all in one go by using Carbon Studio. This I believe is the strongest feature in Carbon Studio. Even if you are new to the Carbon platform and  are still learning about the products you can still easily create these artifacts because Carbon Studio provides a user-friendly and precise user interface.

1. Carbon Studio

2. How to install Carbon Studio


Dakshitha Ratnayake, Software Engineer, WSO2 Inc.



About Author

  • Dakshitha Ratnayake
  • Senior Lead - Solutions Engineer
  • WSO2