Jump to: navigation, search

Difference between revisions of "EDT:Deployment Introduction"

m (Deployment Operation)
 
(5 intermediate revisions by 2 users not shown)
Line 1: Line 1:
 
= Introduction  =
 
= Introduction  =
  
To make an EGL application run in a test or production environment, you must have the generated HTML, Java class &amp; JavaScript files packaged into a WAR file which conforms to the&nbsp; JavaEE specification, and then deploy it to the web application server (e.g., Tomcat).&nbsp; The EGL project itself cannot export a WAR file directly, so we introduce the concept of '''deployment '''in EDT.&nbsp;&nbsp; Deployment in EDT means to copy the generated output from an EGL project to a specified JavaEE project, and to make sure the files and directory structure after the copy will conform to the JavaEE specification, and can easily be exported as a WAR file.&nbsp; EDT users can control the deployment process by specifying the configuation in a '''deployment descriptor'''. <br>  
+
To make an EGL application run in a test or production environment, you must have the generated HTML, Java class, and JavaScript files packaged into a WAR file which conforms to the Java EE specification, and then deploy it to the web application server sush as Tomcat.&nbsp; The EGL project itself cannot be exported as a WAR file directly, so we introduce the concept of '''deployment.'''&nbsp;&nbsp; Deployment in EDT means to copy the generated output from an EGL project to a specified Java EE project, and to make sure the files and directory structure after the copy will conform to the Java EE specification, and can easily be exported as a WAR file.&nbsp; EDT users can control the deployment process by specifying the configuation in a '''deployment descriptor'''. <br>
  
 
= Deployment Descriptor File  =
 
= Deployment Descriptor File  =
  
There will be a Deployment Descriptor (DD for short) file in each EGL project you have created. As we introduced in the last section, an EDT Deployment operation is needed if you are writing an EGL project with a handler or service. The DD file maintains all of the information needed for deployment. The following section will introduce the details of this.  
+
There will be a deployment descriptor (DD for short) file in each EGL project you have created. As we introduced in the last section, an EDT deployment operation is needed if you are writing an EGL project with a handler or service. The DD file maintains all of the information needed for deployment. The following section will introduce the details of this.  
  
<br>The DD file will be created automatically when you create any of the EGL project types in EDT. It will be placed in the EGLSource folder with the same name as your project. Although RUIHandler and service deployment be will added to DD file automatically when you use creation wizard, there are still some settings which will need your manual modification. See the points listed below.  
+
<br>The DD file will be created automatically when you create any of the EGL project types in EDT. It will be placed in the EGLSource folder with the same name as your project. Although RUIHandler and service deployment be will added to DD file automatically when you use the creation wizard, there are still some settings which will need your manual modification. See the points listed below.  
  
 
== '''Overview Tab:''' <br>  ==
 
== '''Overview Tab:''' <br>  ==
  
This tab shows all of the status of the details tabs. You may switch to specific tab by clicking '''Details''' or by double-clicking the item in the grid.  
+
This tab shows all of the status of the details tabs. You can switch to a specific tab by clicking '''Details''' or by double-clicking on the item in the grid.  
  
<br>The '''Target Project '''combo box lists all dynamic web projects in the current workspace. You should select one of the projects,&nbsp; or create a new one.&nbsp; When doing deployment, this filed can not be empty.  
+
<br>The '''Target Project '''combo box lists all dynamic web projects in the current workspace. You should select one of the projects,&nbsp; or create a new one.&nbsp; When doing deployment, this field can not be empty.  
  
 
<br>  
 
<br>  
Line 25: Line 25:
 
<br>You can manually modify the Rich UI Handlers and services you want to deploy in these two tabs.  
 
<br>You can manually modify the Rich UI Handlers and services you want to deploy in these two tabs.  
  
[[Image:RichUI EDT.JPG]]<br>To modify the Rich UI Handlers you want to deploy, you need to uncheck the '''Deploy all Rich UI Handler'''s checkbox. This will enable the Rich UI Handler detail table. Then you can take a multi-selection by checking the checkbox in front of the RUIHandlers you want to deploy. The selected RUIHandler resources will be deployed to the target project, including HTML and JavaScript.&nbsp; You can also modify the locale setting for the HTML file by configuring the '''Locale Settings''' table. Just select the locale by checking the checkbox.
+
[[Image:RichUI EDT.JPG]]<br>
  
[[Image:ServiceDeplooy EDT.JPG]]<br>In the Service Deployment tab, all of the REST services you have created will be listed in the table. If you forgot to check the option '''Create as Web Services''' when creating your services, you can modify them in this tab easily. Just click the '''Add''' button at the right of the table. The '''Add Web Services''' wizard will pop up, and you can manage the services in this pop up window. When your configuration is complete, click '''Finish''' to accept it.  
+
To modify the Rich UI Handlers you want to deploy, you need to uncheck the '''Deploy all Rich UI Handlers''' checkbox. You can select one or more RUI handlers you want to deploy. The selected RUI handlers will be deployed to the target project, including HTML and JavaScript.&nbsp; You can also modify the locale settings for the HTML file by configuring the '''Locale Settings''' table.
 +
 
 +
[[Image:ServiceDeplooy EDT.JPG]]<br>
 +
 
 +
In the '''Service Deployment''' tab, all of the REST services you have created will be listed in the table. If you forgot to check the option '''Create as Web Services''' when creating your services, you can modify them in this tab. Just click the '''Add''' button at the right of the table. The '''Add Web Services''' wizard will pop up, and you can manage the services in this window. When your configuration is complete, click '''Finish''' to accept it.
  
 
== '''Resource Bindings:'''  ==
 
== '''Resource Bindings:'''  ==
  
The resource binding tab configures the database resources or deployed REST services you may want to use in this project.&nbsp; If the project contains database logic,&nbsp; EGL REST services, or non-EGL service invocations, you may use these tabs to configure these settings.<br>For details of Resource Binding, see&nbsp; [[EDT:Resource Binding Introduction|Resource Binding Introduction]].  
+
The '''Resource Binding''' tab configures the database resources or deployed REST services you may want to use in this project.&nbsp; If the project contains database logic,&nbsp; EGL REST services, or non-EGL service invocations, you may use these tabs to configure these settings.<br>For details of Resource Binding, see&nbsp; [[EDT:Resource Binding Introduction|Resource Binding Introduction]].  
  
 
== '''Imports &amp; Resources:'''  ==
 
== '''Imports &amp; Resources:'''  ==
  
The'''Imports''' tab allows you to reference another DD file in a different project to reuse some of the settings. It can make your project structure more clear. For example, suppose you have two EGL projects, where the first one includes all Rich UI Handlers, and the other one includes all services. Then when you deploy the Rich UI Handler project, you can simply&nbsp; import the project that contains your&nbsp; services. This can reduce&nbsp; redundancy and provide better consistency.
+
The '''Imports''' tab allows you to reference another DD file in a different project to reuse some of the settings. It can make your project structure more clear. For example, suppose you have two EGL projects, where the first one includes all Rich UI Handlers, and the other one includes all services. Then when you deploy the Rich UI Handler project, you can simply import the project that contains your services. This can reduce redundancy and provide better consistency.  
  
<br>The '''Resources''' tab allows you to modify the resources you want to deploy. By default, all resources in'''WebContent''', '''generatedJava''', '''generatedJavaScript''', and '''src''' folders will be deployed. For example, you can modify the resources to remove the '''src''' folder to reduce the size of the target project.<br>  
+
<br>The '''Resources''' tab allows you to modify the resources you want to deploy. By default, all resources in the '''WebContent''', '''generatedJava''', '''generatedJavaScript''', and '''src''' folders will be deployed. For example, you can modify the resources to remove the '''src''' folder to reduce the size of the target project.<br>
  
 
= Deployment Operation<br>  =
 
= Deployment Operation<br>  =
  
There are two way to trigger a deployment operation. You can trigger it by right-clicking on the DD file to bring up the context menu, and then select '''Deploy EGL Descriptor''', or by clicking this button [[Image:Deploy EDT.JPG]]&nbsp;at the top-right of the DD file editor view. If the target project of the DD file is empty, there will be an alert notifying you to modify it. You will also see an alert if no RUIHandler or Service Deployment has been added in the DD file.  
+
There are two way to trigger a deployment operation. You can trigger it by right-clicking on the DD file to bring up the context menu, and then selecting '''Deploy EGL Descriptor'''; or by clicking this button [[Image:Deploy EDT.JPG]]&nbsp;at the top right of the DD file editor view. If the target project of the DD file is empty, there will be an alert notifying you to modify it since EGL projects are deployed as web projects. You will also see an alert if no Rich UI Handler or service deployment has been added in the DD file since nothing has been selected to deploy.  
  
<br>  
+
<br>
  
 
= Some Tips of Deployment  =
 
= Some Tips of Deployment  =
  
If you are using Java external types in your projects, you should have configured the Java build path of your EGL project to make sure there are no compile errors inthe&nbsp; generated Java code. But when you deploy the EGL project to the target project, the external JAR can not be deployed to the target project. You need to modify the Java build path again in the target project manually.  
+
If you are using Java external types in your projects, you should have configured the Java build path of your EGL project to make sure there are no compile errors in the generated Java code. But when you deploy the EGL project to the target project, the external JAR can not be deployed to the target project. You need to modify the Java build path again in the target project manually.  
  
 
<br>  
 
<br>  
  
 
[[Category:EDT]]
 
[[Category:EDT]]

Latest revision as of 13:04, 20 February 2012

Introduction

To make an EGL application run in a test or production environment, you must have the generated HTML, Java class, and JavaScript files packaged into a WAR file which conforms to the Java EE specification, and then deploy it to the web application server sush as Tomcat.  The EGL project itself cannot be exported as a WAR file directly, so we introduce the concept of deployment.   Deployment in EDT means to copy the generated output from an EGL project to a specified Java EE project, and to make sure the files and directory structure after the copy will conform to the Java EE specification, and can easily be exported as a WAR file.  EDT users can control the deployment process by specifying the configuation in a deployment descriptor.

Deployment Descriptor File

There will be a deployment descriptor (DD for short) file in each EGL project you have created. As we introduced in the last section, an EDT deployment operation is needed if you are writing an EGL project with a handler or service. The DD file maintains all of the information needed for deployment. The following section will introduce the details of this.


The DD file will be created automatically when you create any of the EGL project types in EDT. It will be placed in the EGLSource folder with the same name as your project. Although RUIHandler and service deployment be will added to DD file automatically when you use the creation wizard, there are still some settings which will need your manual modification. See the points listed below.

Overview Tab:

This tab shows all of the status of the details tabs. You can switch to a specific tab by clicking Details or by double-clicking on the item in the grid.


The Target Project combo box lists all dynamic web projects in the current workspace. You should select one of the projects,  or create a new one.  When doing deployment, this field can not be empty.


Overview EDT.JPG

Rich UI and Service Deployment:

One of the main purposes for the DD file is to deploy Rich UI Handlers and REST services to the target project. These two types of EGL files will be added to the DD file by default when you create them with the creation wizard.


You can manually modify the Rich UI Handlers and services you want to deploy in these two tabs.

RichUI EDT.JPG

To modify the Rich UI Handlers you want to deploy, you need to uncheck the Deploy all Rich UI Handlers checkbox. You can select one or more RUI handlers you want to deploy. The selected RUI handlers will be deployed to the target project, including HTML and JavaScript.  You can also modify the locale settings for the HTML file by configuring the Locale Settings table.

ServiceDeplooy EDT.JPG

In the Service Deployment tab, all of the REST services you have created will be listed in the table. If you forgot to check the option Create as Web Services when creating your services, you can modify them in this tab. Just click the Add button at the right of the table. The Add Web Services wizard will pop up, and you can manage the services in this window. When your configuration is complete, click Finish to accept it.

Resource Bindings:

The Resource Binding tab configures the database resources or deployed REST services you may want to use in this project.  If the project contains database logic,  EGL REST services, or non-EGL service invocations, you may use these tabs to configure these settings.
For details of Resource Binding, see  Resource Binding Introduction.

Imports & Resources:

The Imports tab allows you to reference another DD file in a different project to reuse some of the settings. It can make your project structure more clear. For example, suppose you have two EGL projects, where the first one includes all Rich UI Handlers, and the other one includes all services. Then when you deploy the Rich UI Handler project, you can simply import the project that contains your services. This can reduce redundancy and provide better consistency.


The Resources tab allows you to modify the resources you want to deploy. By default, all resources in the WebContent, generatedJava, generatedJavaScript, and src folders will be deployed. For example, you can modify the resources to remove the src folder to reduce the size of the target project.

Deployment Operation

There are two way to trigger a deployment operation. You can trigger it by right-clicking on the DD file to bring up the context menu, and then selecting Deploy EGL Descriptor; or by clicking this button Deploy EDT.JPG at the top right of the DD file editor view. If the target project of the DD file is empty, there will be an alert notifying you to modify it since EGL projects are deployed as web projects. You will also see an alert if no Rich UI Handler or service deployment has been added in the DD file since nothing has been selected to deploy.


Some Tips of Deployment

If you are using Java external types in your projects, you should have configured the Java build path of your EGL project to make sure there are no compile errors in the generated Java code. But when you deploy the EGL project to the target project, the external JAR can not be deployed to the target project. You need to modify the Java build path again in the target project manually.