This page describes how to create a gadget for use with the Gadget Server.
To create a gadget, open the WSO2 Developer Studio Dashboard and click Gadget from the Gadget Server category.
There are three ways to create a gadget.
- New Gadget
- Import Gadget from File System
- Import Dashboard Archive
With the New Gadget option, you will get a simple gadget.xml with the specified name. Give the necessary information such as Project Name, Gadget XML and click Finish.
Once you click Finish, you will see that a new project has been created in the workspace and it will contain the Gadget XML with the specified name and a file called gadget-conf.xml which includes the metadata for gadget deployment.
With the Import Gadget Resources from File System option, you can browse to a location where you have gadget configuration files, images and other related resources.
Once you click Finish, you will see that the new project has been created with the given name with the imported resources in the workspace.
With the third option, you can browse to a Dashboard Archive [DAR] file, and create a new gadget project.
Once you click Finish, you will see that the DAR file you have specified has been extracted and a new project has been created in the workspace.
As you did for all the other projects, you can export the created gadget in to a deployable artifact by right-clicking on the project and clicking Export Project as Deployable Archive. A Dashboard Archive [DAR] file is created, which is a bundle that you can deploy in to any WSO2 Gadget Server. At the same time, you can group it as a Composite Application Project and create the Composite Application Archive [CAR] file and deploy into the WSO2 Gadget Server.