Difference between revisions of "GVExample TOUPPER"

From GreenVulcano Wiki
Jump to: navigation, search
Line 1: Line 1:
 
==Description==
 
==Description==
  
This example shows a [[synchronous service]].  
+
This example shows a [[Paradigms_of_communication|synchronous service]].  
  
 
==How To==
 
==How To==
Line 24: Line 24:
 
[[File:NewServiceWizard.jpg|thumb|New {{GVESB}} Service Wizard]]Now we are able to use the Wizard.
 
[[File:NewServiceWizard.jpg|thumb|New {{GVESB}} Service Wizard]]Now we are able to use the Wizard.
 
# From the Core View of {{VULCON}}. Right click the element Services -> Wizard New Service
 
# From the Core View of {{VULCON}}. Right click the element Services -> Wizard New Service
# A new windows will be open where you can set the name of the Service you want to create, in this case we named TOUPPER, and your Group, we used TEST_GROUP. You can also select the paradigm, for this example will be [[synchronous-synchronous]]. Click next.
+
# A new windows will be open where you can set the name of the Service you want to create, in this case we named TOUPPER, and your Group, we used TEST_GROUP. You can also select the paradigm, for this example will be [[Paradigms_of_communication#synchronous-synchronous|synchronous-synchronous]]. Click next.
 
# Set System as GVESB_TEST and Channel as TEST_CHANNEL. Then chose the Operation, in this case Test. Then finish.
 
# Set System as GVESB_TEST and Channel as TEST_CHANNEL. Then chose the Operation, in this case Test. Then finish.
  
Line 33: Line 33:
 
* A [[Main_nodes|Check node]] named ''check_status'' is also inserted for controlling the success of the preceding node.
 
* A [[Main_nodes|Check node]] named ''check_status'' is also inserted for controlling the success of the preceding node.
 
* If ''success'' flow passes to the [[Main_nodes|End node]] ''return_status''
 
* If ''success'' flow passes to the [[Main_nodes|End node]] ''return_status''
* In case of Error, flow goes to the [[Main_nodes|End node]] ''return_error''. The difference with ''return_status'' is signed by the [[Connection]] with ''check_status'' Check node. In this case an [[Error Connection]] (the Red arrow) have been used.  
+
* In case of Error, flow goes to the [[Main_nodes|End node]] ''return_error''. The difference with ''return_status'' is signed by the [[Palette|Connection]] with ''check_status'' Check node. In this case an [[Palette|Error Connection]] (the Red arrow) have been used.  
 
* Save clicking the ''Save'' icon from the Core View
 
* Save clicking the ''Save'' icon from the Core View
  

Revision as of 15:59, 11 February 2012

Description

This example shows a synchronous service.

How To

New Vulcon Project

As this is our first example, the first step will be the creation of a new VulCon Project.

  1. From the Menu panel of VulCon click File -> New -> Project. A new windows will be open containing the projects type.
  2. Select Vulcon -> "New Vulcon Project" item. Then click Next
  3. Set the project name and Location. We named the project GVEXAMPLE and the Location as ${{gv.app.home}}/TEST/TESTFS. Then click finish. The new VulCon project GVEXAMPLE has been created.

The best mode for creating a Service is through the Wizard. But for use it you must first define a new Group, System and Channel, if you do not want to use those already presents, and the workflow operations. From the core view:

  1. Right click the element Groups -> Insert after (or Insert before) -> Group. A new element Group will be created.
  2. Click on the Group new element and set the attribute id-group from the Properties View. We named it TEST_GROUP.
  3. Expand the GVSystems item.
  4. Right clicking on Systems, insert-after -> System. A new element System will be created.
  5. Set the System parameters in the Properties panel. We named it GVESB_TEST
  6. You can insert a new Channel right clicking the new System element -> Insert after (or Insert before) -> Channel*. A new Channel element will be created
  7. Click on this new Channel element and set the property id_channel. We named it TEST_CHANNEL
  8. Finally, insert the operation you need for the workflow. In this case a test-service-call. Right clicking Channel -> Insert after -> test-service-call. A new element test-service-call will be created.
  9. Set the test-service-call attributes. From the properties view set the name attribute as test.
New GreenVulcano® ESB Service Wizard

Now we are able to use the Wizard.

  1. From the Core View of VulCon. Right click the element Services -> Wizard New Service
  2. A new windows will be open where you can set the name of the Service you want to create, in this case we named TOUPPER, and your Group, we used TEST_GROUP. You can also select the paradigm, for this example will be synchronous-synchronous. Click next.
  3. Set System as GVESB_TEST and Channel as TEST_CHANNEL. Then chose the Operation, in this case Test. Then finish.


TOUPPER flow

As you can see from the core view, inside the Services element, a new Service named TOUPPER has been created. The editor will be open automatically, showing the nodes involved in our Flow.

  • The Start node sets the flow first node. In this case request
  • The Operation node request calls the test-service-call operation test and executes it.
  • A Check node named check_status is also inserted for controlling the success of the preceding node.
  • If success flow passes to the End node return_status
  • In case of Error, flow goes to the End node return_error. The difference with return_status is signed by the Connection with check_status Check node. In this case an Error Connection (the Red arrow) have been used.
  • Save clicking the Save icon from the Core View

Now you are able to test your first VulCon service from the GV Console®. But first you need to export the configuration.

Exporting configuration

Once the flow is correctly configured, the user can export the configuration and pass it to the GreenVulcano® ESB import tool, in order to add into the GreenVulcano® ESB the service just created.

  1. The Export function is available in the view "Project". Expand the project
  2. Before you proceed press F5 to refresh the file list.
  3. Right click the conf folder. It will open a drop-down list.
  4. Clicking "Export" will be open a window. Select Vulcon Export Tool -> Vulcon Project. Then Next
  5. Select the project and set the absolute path of the JAR file where the whole configuration will be saved. We have chosen ${{gv.app.home}}/TEST/TESTFS/FirstVulconProject.jar. Then Finish


For knowing how test your service using GV Console® click here.