This guide provides the information of how to setup an Eclipse Dirigible instance, how to use it to build your very first “hello-world.js” service and the references section pointing to the documentation with more detailed technical details for the different aspects of the platform and its components and capabilities.
Get the binary
- In case you want to use a prebuild package, you can get the one built for your environment from the downloads section.
- To build Eclipse Dirigible from sources by yourself, just follow the instructions at the README.
Choose the environment
- You can choose one of the options available to get an Eclipse Dirigible instance depending on your target environment.
- A shared trial instance is also available and can be accessed from here: http://trial.dirigible.io.
There are many configuration options, so you can connect to different databases, use different platforms, choose a specific set of plugins and many more.
Access the instance
In case of the standard setup on Apache Tomcat on your local machine you can point your browser to the location:
Write the hello-world.js service
- Once you have a running Dirigible instance you can start with your project. Choose the
File -> New -> Projectmenu.
- Enter the name of the project and click
- Use right-click on the project icon in the Workspace Explorer to open the popup menu. Select
- Once you enter the name of the service you can open it in the editor with double click on the file icon.
- It already contains the hello world service implementation.
var response = require("http/v4/response"); response.println("Hello World!"); response.flush(); response.close();
- Now just publish the project by clicking on the
Publishmenu of the project.
- You can check in the
Update the hello-world.js service
- Go to line 3 in the editor and change:
The click Ctrl+S (Command+S for Mac) to save the file content.
You can see that in the
Previewview the output has changed immediately. This is due to the default configuration of auto-publish on save.
More about this dynamic behavior you can find at the concepts section: Dynamic Applications
So far we saw how easy is to create and modify a RESTful service. More samples can be found here. If you would like to know more about how to write more complex services, you can go to the API section.