HCL ZIETrans allows you to transform your user experience by extending 3270 and 5250 terminal applications to the web, portlet, rich client, or as standard SOAP or RESTful web services. By default, all HCL ZIETrans Web applications are stored in one enterprise archive file.

HCL ZIETrans Toolkit is an HCL ZIE component that enables you to develop new applications and allows previewing and saving each change. We can streamline the HCL ZIETrans application in such a way that it becomes easier to use the host applications whose data and functions it presents. The supported servers for multiple HCL ZIETrans applications in an ear are ‘WebSphere Application Server’ and ‘WebSphere Liberty’.

This blog describes the ways to manage the HCL ZIETrans web applications that have multiple .ear and multiple .war in the projects, using HCL ZIETrans Toolkit and the best practices.

When you export your applications as HCL ZIETrans EAR file and deploy them on WebSphere Application Server, the .ear file contains a Web archive (.war) file with the resources to run each application. An EAR may also combine multiple web projects (WAR), Enterprise JavaBeans projects (JAR), standard JARs, etc. into a single application.

Each individual .ear consumes around 25MB (minimum) of disk space during runtime. So, if you have multiple HCL ZIETrans projects you may end up having multiple HCL ZIETrans EAR of varying size depending on the complexity of the application. Based on different deployment or development scenarios may lead to developers/administrators opting for single EAR or multiple EAR’s deployment solutions.

The below table illustrates salient points of the ‘Individual’ Vs ‘Multiple wars in single’ EAR deployment method, based on these customers can decide their HCL ZIETrans application deployment architecture.

Table 1: Individual Vs Multiple wars in one EAR deployment

Ways to organize the HCL ZIETrans Web Applications:

Associating multiple .war or HCL ZIETrans projects with one .ear and de-associating can be achieved using deployment descriptor application.xml present in the META-INF folder of the EAR.

The sections below demonstrate

  • Creating individual .ear for each project on HCL ZIETrans Toolkit
  • Adding multiple .war to one .ear in application.xml
  • Removing .war from .ear in application.xml and deploying the same.

Creating individual .ear for each project

  1. Go to File->New-> ZIETrans Project. On the Create a Project console, specify a name for the
    Enterprise application project (.ear) to be created as shown.
  2. Click Next and specify connection settings. Click Finish.
A screenshot of a social media postDescription automatically generated

Figure 1: Create a project

 

The created project and EAR in the Navigator are displayed.

Figure 2: Created project

By default, all HCL ZIETrans Web applications are associated with existing enterprise archive file. Hence the next project will have a .ear name same as above ZIETrans_testOne_EAR. We could continue using it.

Or we can provide a different.ear name in step 1: ‘Create project’ dialog which will create separate .ear for the individual project.

Figure 3: .ear for the individual project

After creating individual ears and deploying it on server:


Figure 4: Individual ears deployed on server

 

Adding multiple .war to one .ear in application.xml

Initially, there are 4 projects in the workspace. Where, the project “testFour” is imported as folder into the workspace.

Figure 5: projects in the workspace

  1. Take project ear to which you want to add .war file to, for instance, ZIETrans_testThree_EAR. Expand the META-INF folder to find application.xml and double click to open the editor.

Figure 6: Deployment Descriptor Editor

As we see in ZIETrans_testThree_EAR, “testThree.war” is already present in the Overview section. Let’s add 2 others .war to it. for instance, testFour and testOne.

2. So to add .war, click on Add button shown on the right side of the Overview. Add Item window appeares. Click on Module and click OK.

Figure 7: Add Item window

3. The next window shows the available modules/projects in the workspace. Add these modules one by one. Select the module and click Finish. Save the application.xml.

Figure 8: Add modules

The Overview window is displayed as below:

Figure 9: Overview window

4. Deploy the ear on the server and the server.

Figure 10: Deploy the ear on the server

Removing .war from .ear in application.xml

  1. Select project ear from which we want to remove .war file from, for instance, ZIETrans_testThree_EAR. Expand the META-INF folder to find application.xml. Double click to open the editor.

Figure 11: Remove .war file

2. Let us remove testOne.war from the ZIETrans_testThree_EAR. Click on testOne.war in the Overview section and click on Remove button shown on the right side. Save the application.xml.

The Overview section after removing appears as shown below:

3. Deploying the ear on the server. Restart the server.

Figure 12: Deploy the ear on the server

Contact us

For further information on Organizing Web Applications in HCL ZIETrans, automation capabilities and Lab services offerings, please write to:

ZIO@hcl.com

Akshata Betageri

Developer, Lab Services

Comment wrap
Further Reading
article-img
Mainframes | July 8, 2022
Accessing ZIETrans administrative console on Liberty server
Using ZIETrans administrative interface, it is possible to manage connections and perform problem determination for ZIETrans Web applications.
article-img
Mainframes | December 7, 2021
Using ZIETrans EJB
Read the blog for more details about EJB (Enterprise java bean) server-side software that helps to summarize the business logic of a particular application.
article-img
Mainframes | December 7, 2021
Enabling CSRF and XSS protections in ZIETrans
Read the blog to know more about Cross-Site Request Forgery(CSRF) how we can protect against CSRF and XSS in ZIETrans.
Close
Filters result by
Sort:
|