WSO2 Developer Studio is a SOA development environment to build and manage your applications. It has in-built application creation and lifecycle management tooling support for a better, integrated development experience.
Let's use WSO2 Developer Studio to edit a new application in the same way you did using Codenvy in a previous tutorial.
Important: If you are using Developer Studio via the P2 zip file, the Online P2 Repository, or the Eclipse Market Place instead of the complete installation distribution, you need to update your Egit plugin before you use the App Factory tooling feature. To update your Egit plugin, go to http://download.eclipse.org/egit/updates/ via Eclipse.
- Log in to the App Factory and create a new application (e.g.,
- Install WSO2 Developer Studio in your environment. For instructions, see Installation.
- Open the Developer Studio console, select the dashboard and click Switch to App Cloud / App Factory perspective.
Click the Login icon.
In the login screen, click the App Factory option, give the URL in the format
tory_host>and give the same credentials that you used to log in to the App Factory.
Tip: If you registered more than one organization with your credentials, you will be prompted to select an organization after logging in.
The App Factory perspective opens. Note the following:
- Your application's key (auto generated when creating the application in the App Factory) appears under the Applications List in the upper right-hand corner. If required, click Refresh to update the list of applications.
- Details of the currently selected application appear in the lower right-hand corner
- Build console appears in the lower center
Let's check out your code and modify it.
- Right click on your application and click Open. The available branches of the application appear under it. As you use a new application in this example, it only shows the main branch.
Right-click on the main branch (or any other branch, if any) and click Check Out and Import. The application opens in the Project Explorer.
If you get an error saying that the Maven application directory is not specified, it is because you have not defined <
M2_HOME>system variable to point to your Maven installation directory. You can opt to ignore the error as the projects get imported into your workspace anyway, without the Maven dependencies being resolved.
Tip: To check out the code as a background process, right click the branch you want to work with and click Check Out. Then, right click the branch again and click Import to workspace.
Do the required modifications to the source code using the Developer Studio editor and Save the file.
For example, let's open the
index.jspfile and change the heading of the output to "Hello cloud user" and the name of the button to "Click here".
- Right click on the project in the Project Explorer and click Team > Commit. If prompted for credentials, give your Git credentials, which are the same ones that you used to log in to the App Factory.
- Enter a commit message, select the files you want to commit and click Commit and Push. This will add the changes you did in Developer Studio to the files in the remote repository.
Right click on the project from application list view and click Deploy.
Tip: You can build your code using the Developer Studio to see if there are no build issues, but it does not affect the builds in the App Factory. You must build, deploy and launch your application from the App Factory's UI.
Note the build logs that that appear in the console at the bottom of the window.
Tip: To view the latest build logs for a different branch, right click on the branch in the application list view and click Build Logs.
If the build is successful, come back to the App Factory console, open the application and click its Repos & Builds page. Then build, deploy and launch the application using the relevant buttons.
- Note the changes you added shown in the launched application.