cornercorner
FeaturesPluginsDocs & SupportCommunityPartners

Enterprise Application Project UI Spec

This UI spec defines the UI for J2EE Enterprise Application projects in the CDP J2EE.  It is based on the Build System UI Spec , J2SE Project Type UI Spec, EJB Module Project UI Spec and Web App Project UI Spec.

Author: Ann Sunhachawee, Jiri Kopsa, Jan Rojcek

$Revision: 1.1 $
$Date: 2005/04/25 13:35:44 $
Changes: available in CVS

Table of Contents:

Overview

An Enterprise Application can be made up of multiple J2EE modules (EJB modules, Web modules, Resource Adapters, Application Clients, Utility JARs). These archives can be external to the IDE or they can result from the build process of other projects (i.e. EJB Module Project, WEB Module Project or Java Library Project).

Tasks

  1. Create an Enterprise Application
  2. Add/Remove J2EE module projects (ejb modules, web apps, app client) to the Enterprise Application
  3. Add/Remove J2EE module external archives to the Enterprise Application
  4. Add /Remove libraries to the Enterprise Application
  5. View and manipulate contents of Enterprise Application
  6. View the J2EE module projects and JARs contained in the enterprise app
  7. Configure deployment
  8. Standard Deployment data (application.xml) , including context path of the web app
  9. Server Specific deployment data
  10. Run Enterprise App (note: this task (downloading client stubs) won't be supported in EA2)
  11. Deploy/Undeploy Enterprise App on a local or remote server
  12. Debug Enterprise App
  13. Import existing Enterprise Application into project (free form project) - note: won't be supported in EA2
  14. Validate App
  15. Add help files, documentation for the deployer, libraries used by J2EE modules for packaging in the EAR

New Project Wizard

There is the "Enterprise Application" new project wizard in the "Enterprise" category to create new enterprise application project.

Step 1: New Project - Choose Project

Figure: Choose Project wizard panel

+---------------------------------------------------------------------------------+
| New Project |
+---------------------------------------------------------------------------------+
| Choose Project |
| ------------------------------------------------------------------------------- |
| |
| Categories: Projects: |
| +-----------------------+ +---------------------------------------------------+ |
| | General | |/[e] Enterprise Application////////////////////////| |
| | Web | | [e] Enterpries Application with Existing Sources | |
| |/Enterprise////////////| | [m] EJB Module | |
| | Samples | | [m] EJB Module with Existing Sources | |
| | | | [f] EJB Module with Existing Ant Script | |
| | | | | |
| | | | | |
| +-----------------------+ +---------------------------------------------------+ |
| |
| Description: |
| +-----------------------------------------------------------------------------+ |
| | | |
| | | |
| | | |
| +-----------------------------------------------------------------------------+ |
+---------------------------------------------------------------------------------+

Components:

Step 2: New Enterprise Application - Name and Location

This wizard creates an enterprise application. After finishing the wizard the project node is expanded and selected. Expanded nodes are also Configuration Files and J2EE Modules.

Figure: Name and Location wizard panel

+---------------------------------------------------------------------------------+
| New Enterprise Application |
+---------------------------------------------------------------------------------+
| Name and Location |
| ------------------------------------------------------------------------------- |
| |
| Project Name: |_EnterpriseApplication_________________________________________| |
| |
| Project Location: |_/users/me___________________________________| [ Browse... ] |
| Project Folder: |_/users/me/EnterpriseApplication_____________| |
| |
| ------------------------------------------------------------------------------- |
| |
| Server: |_Sun Java System Application Server 8________________________v_| |
| J2EE Version: |_J2EE 1.4_______v_| |
| |
| [x] Create EJB Module: |_EnterpriseApplication-EJBModule__________| |
| [x] Create Web Application Module: |_EnterpriseApplication-WebModule__________| |
| |
| Recommendation: In order to create portable J2EE applications, it is recommended|
| to use JDK 1.4 for all J2EE 1.4 and J2EE 1.3 projects. Since you have only JDK |
| 1.5, you may want to at least set the source levels to 1.4. |
| [x] Set Source Levels to 1.4. |
| |
| [x] Set as Main Project |
| |
+---------------------------------------------------------------------------------+

Components of this wizard step are:

  1. Project Name text field (N) - specifies the project name which is used as project folder name. Project name have to be a valid folder name. Initially contains EnterpriseApplication<x> name, where <x> is a number of created Enterprise Applications. Always enabled.
  2. Project Location text field (L) - specifies the location of project folder. By default the text field contains <all-projects-home> (which might equal to user home). Next time the wizard is invoked the <all-projects-home>  defaults to what the user set it to the last time. Always enabled.
  3. Browse button (w) - opens a file chooser titled Browse Project Location with OK and Cancel buttons for selecting the project folder location. Always enabled.
  4. Project Folder text field (r) - non-editable text field showing the full path of created project folder.
  5. Server combo box (S) - specifies the J2EE server instance. Shows the names of all registered server instances in the Server Manager.
  6. J2EE Version combo box (J) - always disabled and showing J2EE 1.4 version number.
  7. Create EJB Module check box (E) - specifies whether an EJB module is created together with the enterprise application. Checked by default.
  8. Create EJB Module editable text field (E) - specifies the name of created EJB module project. The default name is <project-name>-EJBModule, e.g. "EnterpriseApplication10EJBModule". Enabled only if the checkbox is checked.
  9. Create Web Application Module check box (W) - specifies whether a Web Application module is created together with the enterprise application. Checked by default.
  10. Create Web Application Module editable text field (W) - specifies the name of created Web Application module project. The default name is <project-name>-WebModule, e.g. "EnterpriseApplication10WebModule". Enabled only if the checkbox is checked.
  11. Recommendation message and Use JDK 1.4 / Set Source Levels to 1.4 checkbox - the behaviour is the same as in the New Web Application wizard; with several corrections/extensions:
    • The checkbox applies to the module projects created by the wizard, not the enterprise application project.
    • If none of the Create * Module checkboxes is checked, the "Use JDK 1.4 / Set Source Levels to 1.4" checkbox is disabled.
  12. Set as Main Project check box (S) - specifies that the newly created project should be set as the main project. Enabled by default.

Wizard buttons' behavior:

  • Back button - always enabled.
  • Next button - always disabled.
  • Finish button - enabled if a project name and a valid project folder is set.

In-line error messages:

  1. Project Name have to be a valid folder name - if the project name is not properly formatted.
  2. Project Folder Already Exists - if the entered project folder already exists.

Step 2: New Enterprise Application with Existing Sources - Name and Location

This wizard creates an enterprise application from existing blueprint sources. After finishing the wizard the project node is expanded and selected. Expanded nodes are also Configuration Files and J2EE Modules.

Figure: Name and Location wizard panel

+---------------------------------------------------------------------------------+
| New Enterprise Application with Existing Sources |
+---------------------------------------------------------------------------------+
| Name and Location |
| ------------------------------------------------------------------------------- |
| |
| Select the folder that contains all the sources for the Enterprise Application. |
| The sources have to be in Blueprint source structure. |
| |
| Location: |_/users/me/MyEnterpiseApp____________________________| [ Browse... ] |
| |
| Specify a name and location for the new project. |
| |
| Project Name: |_EnterpriseApplication1________________________| |
| Project Folder: |_/users/me/EnterpriseApplication1______________| [ Browse... ] |
| |
| ------------------------------------------------------------------------------- |
| |
| Server: |_Sun Java System Application Server 8________________________v_| |
| J2EE Version: |_J2EE 1.4_______v_| |
| |
| Recommendation: In order to create portable J2EE applications, it is recommended|
| to use JDK 1.4 for all J2EE 1.4 and J2EE 1.3 projects. Since you have only JDK |
| 1.5, you may want to at least set the source levels to 1.4. |
| [x] Set Source Levels to 1.4. |
| |
| [x] Set as Main Project |
| |
+---------------------------------------------------------------------------------+

Components of this wizard step are:

  1. Location text field (o) - specifies the location of the existing Blueprint structured enterprise appplication to import.
  2. Browse (Location) button (b) - opens a file chooser titled Browse Existing Source Location with OK and Cancel buttons for selecting the location of the project being imported. The file chooser starts in the user home folder. Always enabled.
  3. Project Name text field (N) - specifies the project name which is used as project folder name. Project name have to be a valid folder name. Initially contains EnterpriseApplication<x> name, where <x> is a number of created Enterprise Applications. Always enabled.
  4. Project Folder text field (L) - specifies the project folder. By default the text field contains <all-projects-home>/<project-name>. If the user doesn't specify a different project folder manually then the <project-name> part of default project folder is automatically taken from the project name field and changed if the user changes the value in project name field. Next time the wizard is invoked the same <all-projects-home> is used by default as the user set it the last time. Always enabled.
  5. Browse (Project Folder) button (o) - opens a file chooser titled Browse Project Folder with OK and Cancel buttons for selecting the project folder. Always enabled.
  6. Server combo box (S) - specifies the J2EE server instance. Shows the names of all registered server instances in the Server Manager.
  7. J2EE Version combo box (J) - always disabled and showing J2EE 1.4 version number.
  8. Recommendation message and Use JDK 1.4 / Set Source Levels to 1.4 checkbox - the behaviour is the same as in the New Enterprise Application wizard.
  9. Set as Main Project check box (S) - specifies that the newly created project should be set as the main project. Enabled by default.

Wizard buttons' behavior:

  • Back button - always enabled.
  • Next button - always disabled.
  • Finish button - enabled if the project location contains a valid Blueprint enterprise application, and valid project name and project folder is set.

In-line error messages:

  1. The Location doesn't contain a Blueprint enterprise application. - if the project name is not properly formatted.
  2. Project Name have to be a valid folder name - if the project name is not properly formatted.
  3. Project Folder Already Exists - if the entered project folder already exists.

Project Window

Figure: Project window

+---------------------------------------------------------+
| Projects |
+---------------------------------------------------------+
|- [E] MyEnterpriseApp1 |
| - [C] Configuration Files |
| - [x] application.xml |
| - [x] <filename of server-specific DD> |
| - [M] J2EE Modules |
| - [e] <name of ejb module project> |
| - [w] <name of webapp module project> |
| - [f] <name of ejb module jar file> |
| - [v] <name of webapp module jar file> |
| |
| |
| |
+---------------------------------------------------------+

Node: Enterprise Application

  • Read-only name: <project-name>
  • Tooltip: Enterprise Application
  • Contextual menu:
    Add J2EE Module...
    ----------------------------
    Build Project
    Clean & Build Project
    Clean Project
    Verify Project
    ----------------------------
    Run Project
    Debug Project
    Deploy Project
    ----------------------------
    Set Main Project
    Open Required Projects
    Close Project
    ----------------------------
    Find...
    ----------------------------
    Properties
  • Add J2EE Module- opens the Add J2EE Module dialog.
  • Run Project- will run the server (if it is not running), followed by deploy. If the server was running in the debug mode, the IDE will bring up a dialog box asking "The debugging session on the {deployment target} is running. Do you want to terminate it and start the server in standard mode?". The IDE will terminate the debug session, detach the debugger, stop the server before starting in standard mode if the dialog box is confirmed.
  • Debug Project - will run the server in debug mode and attach a debugger, followed by deploy. If the server was running in the standard mode, the IDE will bring up a dialog box asking "The {deployment target} is currently running in standard mode. Do you want to stop it and start it in the debug mode?". The IDE will stop the server and start it in debugging mode if the dialog box is confirmed.
  • Verify Project - validates the application, the result is presented in the output window. The Validate function is also part of the deployment process.
  • Deploy Project - deploys the application (can do incremental deployment if possible). The action will check whether the application is present on the deployment target at first. If so, it will show a message box with the message "Application already deployed.".

Dialog: Add J2EE Module

Figure: Add J2EE Module dialog

+-----------------------------------------+
| Add J2EE Module |
+-----------------------------------------+
| J2EE Modules: |
| +-------------------------------------+ |
| |/[e] EJBModule1//////////////////////| |
| | [w] WebApplication1 | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| +-------------------------------------+ |
| |
| [[ Add ]] [ Cancel ] |
+-----------------------------------------+

[w] - Web Application project icon
[e] - Enterprise JavaBeans Module project icon
Components of this dialog are:
  1. J2EE Modules list (J) - Displays the list of all the open web application and ejb module projects sorted alphabetically. The first item is selected initially. Allows multi-selection.
  2. Add button - Closes the dialog and adds the selected modules into the enterprise application underneath the J2EE Modules node. The J2EE Modules node is expanded and newly added modules are selected. This is the default button. Enabled only if a project is selected in the J2EE Modules list.
  3. Cancel button - Closes the dialog without returning a class. Always enabled.

Node: Configuration Files

This node contains the content of the /conf folder.

  • Read-only name: Configuration Files
  • Tooltip: <path-to-configurations-folder>
  • Contextual menu:
    Find...

Node: Configuration File (application.xml)

  • Double-clicking will open the XML editor for that file.
  • Editable name: application.xml
  • Tooltip: <XML Document>

Node: Configuration File (sun-application.xml, or other server-specific deployment descriptor)

  • Double-clicking will open the editor provided by the plugin. The UI of this editor will be the same as provided by the plugin in NetBeans 4.0 with the exception that no child nodes for EJB modules or Web Application modules will be presented.
  • Editable name: sun-application.xml
  • Tooltip: <Deployment Descriptor>

Node: J2EE Modules

  • Read-only name: Configuration Files
  • Contextual menu:
    Add J2EE Module...
  • Add J2EE Module - opens the Add J2EE Module dialog.

Node: Individual J2EE Module

  • Read-only name: <project-name>
  • Contextual menu:
    Open Project
    Remove
  • Open - opens the project representing the J2EE module in Project window.
  • Remove - removes the selected module from the enterprise application.

File Window

Figure: File window

+----------------------------------------------------------+
| Files |
+----------------------------------------------------------+
| - [ ] EJBApp Node |
| - [ ] MyEnterpriseApp1 |
| + [ ] build/ |
| + [ ] dist/ |
| + [ ] nbproject/ |
| - [ ] src/ |
| - [ ] conf/ |
| - [ ] application.xml |
| - [ ] <alternate dd xml> |
| - [ ] build.xml |
| |
+----------------------------------------------------------+

Project Properties Dialog

Figure: Project Properties dialog

+--------------------------------------------------------------------------------------------+
| Project Properties - My Enterprise App |
+--------------------------------------------------------------------------------------------+
| Categories: |
| +----------------+ |
| | Sources | |
| | | |
| | Build | |
| | Packaging | |
| | | |
| | Run | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| +----------------+ |
| [[ OK ]] [ Cancel ] |
+--------------------------------------------------------------------------------------------+
Components of this dialog are:
  1. Categories list (C) - displays a list of property categories.
  2. OK button - closes the dialog and commits the changes.
  3. Cancel button - closes the dialog and cancels the changes.

Sources

Figure: Sources properties panel

+--------------------------------------------------------------------------------------------+
| Project Properties - My Enterprise App |
+--------------------------------------------------------------------------------------------+
| Categories: |
| +----------------+ |
| |/Sources////////| Project Folder: |_/home/me/work/My Enetrpise App______________________| |
| | | |
| | Build | |
| | Packaging | |
| | | |
| | Run | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| +----------------+ |
| [[ OK ]] [ Cancel ] |
+--------------------------------------------------------------------------------------------+
Components of this dialog are:
  1. Project Folder non-editable text field (P) - displays the project folder.

Build: Packaging

This panel applies to packaging the project for deployment.

Figure: General properties panel

+------------------------------------------------------------------------------------------+
| Project Properties - My Enterprise App |
+------------------------------------------------------------------------------------------+
| Categories: |
| +----------------+ |
| | Sources | EAR File: |_~/work/My Enterprise App/dist/My-Enterprise-App.ear_____| |
| | | |
| | Build | Exclude From EAR File: |_**/*.java,**/*.form________________________| |
| |///Packaging////| [ ] Compress EAR File |
| | | |
| | Run | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| +----------------+ |
| [[ OK ]] [ Cancel ] |
+------------------------------------------------------------------------------------------+

Components:

  1. EAR File non-editable text field (J): Shows the name of the ear created from application modules. Always enabled.
  2. Exclude from EAR File text field (E): Specifies filter defining files that should not be excluded from the EAR. Always enabled.
  3. Compress EAR File check box (C): Indicates that the EAR should compressed. Unchecked by default. Always enabled.

Run

Figure: Run properties panel

+--------------------------------------------------------------------------------------------+
| Project Properties - My Enterprise App |
+--------------------------------------------------------------------------------------------+
| Categories: |
| +----------------+ |
| | Sources | Server: |_Sun Java System Application Server 8________________v_| |
| | | J2EE Version: |_J2EE 1.4_______| |
| | Build | |
| | Packaging | Display Browser on Run: |
| | | |
| |/Run////////////| Web Application: |_MyWebApplication1________________________________v_| |
| | | Relative URL: |____________________________________________________| |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| +----------------+ |
| [[ OK ]] [ Cancel ] |
+--------------------------------------------------------------------------------------------+

Components:

  • Server combo box (S) - specifies the server instance the enterprise application is deployed to. The combo box contains all registered app server instances.
  • J2EE Version disabled combo box (J) - specifies the J2EE version. It is disabled and shows J2EE 1.4 value.
  • "Web Application" combo box (W) - contains a list of web applications included in the enterpise application. It also contains the "<none>" item at first position. When the enterprise application is run an internet browser is displayed and navigated to chosen web application and its relative URL. If the "<none>" item is selected, the "Relative URL" text field is disabled and the browser does not appear.
  • Relative URL editable text field (R) - specifies the relative URL of the main page to open in the browser.

Icons

Symbol Icon or folder badge
Description
[E]
<Enterprise Application Name> - Enterprise Application node
[J]
-
< Application Clients > - Application clients container node - note: won't be implemented in EA2
[A]
-
< name of application client project> - individual application client project node - note: won't be implemented in EA2
[M]
* Modules - container for all J2EE modules in the enterprise app; sorted alphanumerically
[e]
<name of EJB module project> - individual EJB module project node
[w]
**
<name of web application module project> - individual Web Application project node
[f]

<name of EJB module jar file> - individual EJB module jar file node
[v]

< name of web application module jar file> - individual war file node
[J]
* Application Clients - container for all application clients in the enterprise app; no contextual menu - note: won't be implemented in EA2
Resource Adapters - container for all resource adapters in the enterprise app; no contextual menu  - note: won't be implemented in EA2
Utility JARs - container for all utility jars in the enterprise app; no contextual menu
[j]
< name of app client > - individual app client node - note: won't be implemented in EA2
< name of resource adapter > - individual resource adapter node - note: won't be implemented in EA2
< name of utility jar > - individual Utility Jar node
[C]
* Configuration Files - container for the configuration files (application.xml, alternate dd)  in the enterprise app; does not contain the manifest file; no contextual menu
[x]
application.xml - Deployment descriptor (xml file)
<name of server-specific DD> - TODO: do we have to add a place in proj properties to turn on Alt DD?

Notes:

* folder badges
**
icon identical with the Web Module icon from the Web Application Module UI spec

Companion
Projects:
MySQL Database Server   GlassFish Community: an Open Source Application Server   Open Solaris  Open JDK: an Open SourceJDK   Mobile & Embedded Community     Sponsored by 
Sponsored by Sun Microsystems