Post date: Dec 7, 2016 7:59:11 AM
Note: In this article, we are setting up the local deployment in D drive as "D:/TrinitiApps28", If you wish to change that, then you need to use your intended path in all places where ever we used "D:/TrinitiApps28".
For Tomcat Environment:
1. Download Triniti Apps Deployment tar file, from below ftp site and unzip it to D:drive.
Example : TrinitiApps28_Exclude_06-Dec-16.tar.gz
open ftp site using below link ftp://192.168.0.49/Triniti_Deployment_Excluded/ and click on tar file it starts download.
2. Install JDK and Tomcat. Do required configurations like adding JAVA_HOME,CATALINA_HOME path in environmental variables.
3. Add host entry for local deployment.
Open “Run” using WINDOWS+R keys press. Search for drivers. Navigate to hosts file and add entry as below:
127.0.0.1 <username>
Example: 127.0.0.1 yourusername
4. Go to $CATLINA HOME/conf and open server.xml file, And add all below contexts after Valve tag inside Host tag:
<Context crossContext="true" debug="0" docBase="D:/TrinitiApps28/tabimpl" path="/tabimpl" reloadable="true"/>
<Context crossContext="true" debug="0" docBase="D:/TrinitiApps28/infrastructure/tas" path="/tas" reloadable="true"/>
<Context crossContext="true" debug="0" docBase="D:/TrinitiApps28/infrastructure/fdt" path="/fdt" reloadable="true"/>
<Context crossContext="true" debug="0" docBase="D:/TrinitiApps28/infrastructure/tab" path="/tab" reloadable="true"/>
<Context crossContext="true" debug="0" docBase="D:/TrinitiApps28/infrastructure/viewer" path="/viewer" reloadable="true"/>
<Context crossContext="true" debug="0" docBase="D:/TrinitiApps28/ETK3" path="/etk" reloadable="true"/>
<Context crossContext="true" debug="0" docBase="D:/TrinitiApps28/scheduler" path="/scheduler" reloadable="true"/>
<Context crossContext="true" debug="0" docBase="D:/TrinitiApps28\pda" path="pda" reloadable="true"/>
<Context crossContext="true" debug="0" docBase="D:/TrinitiApps28\Tri2" path="tri2v2" reloadable="true"/>
<Context crossContext="true" debug="0" docBase="D:/TrinitiApps28\TTT\TTTServer" path="/TTTServer" reloadable="true"/>
<Context crossContext="true" debug="0" docBase="D:/TrinitiApps28\TTT\ttt1.0" path="/ttt1.0" reloadable="true"/>
</Host>
5. Go to $CATLINA HOME/conf and open catalina.properties file and update common.loader value as below:
common.loader=${catalina.base}/lib,${catalina.base}/lib/*.jar,${catalina.home}/lib,${catalina.home}/lib/*.jar,D:/TrinitiApps28/common/googleapi/*.jar,D:/TrinitiApps28/common/*.jar
6. Goto-> D:\TrinitiApps28\ETK3\WEB-INF\classes and open actualpath.properties file and update jdk.home property:
Provide your jdk.home path to jdk.home as below:
jdk.home=C:/Program Files/Java/jdk1.7.0_75
7. Run Triniti Cloner as shown in below wink video:
8. Update the initial, optimal and maximum connections in your local to 1,2, 4:
i) Download attached program "ChangeConnectionPoolInDeployment.java".
ii) change the deployment path in program before running, and add required(which are not listed) connections xmls file path.
iii) Compile the program and run it.
Other way of updating connections when server is already up. Just for Information:
a. Open connections administration jsp page using url: <YOUR_LOCAL_HOST>:<YOUR_PORT>/tabimpl/jsp/applicationjsp/connectionsadministration.jsp.
Provide proper host and port details in the above url.
b. Go to "Update All Connections" option, and provide 1,2,4 for Initial, Optimal and Maximum connections. Choose all contexts for "Update in" option.
c. Click on "Update All"
9. Restart Tomcat.
10. Access your local instance using url: http://username:8080/tabimpl/logon.html
For Glassfish Environment:
1. Download Triniti Apps Deployment tar file, from below ftp site and unzip it to D:drive.
Example : TrinitiApps28_Exclude_06-Dec-16.tar.gz
open ftp site using below link ftp://192.168.0.49/Triniti_Deployment_Excluded/ and click on tar file it starts download.
2. Install JDK and GLassFish. Do required configurations like adding JAVA_HOME path in environmental variables.
Steps to download and install GlassFish Server :
Open https://glassfish.java.net/download.html url and download glassfish-4.1.1.zip under Java EE 7 Full Platform. JDK 8 u60 or above is recommended for GlassFish 4.1.1.
Unzip the downloaded file to the path where you would like to install glassfish.
Go the glassfish4/bin/ and open command prompt in that location.
Run asadmin file. For linux: sh asadmin. For Windows: asadmin.bat
To start server use command start-domain and to stop server use stop-domain.
3.Steps to Configure Triniti Applications on GlassFish Server :
First of all go to your glassfish server location and navigate to the /glassfish4/glassfish/domains/domain1/config/domain.xml.
Open domain.xml file and edit the port number to your respective instance’s port number in the below tag and save the file. For ex : port=”8080” to port=”9999”.
<network-listener protocol="http-listener-1" port="9999" name="http-listener-1" thread-pool="http-thread-pool" transport="tcp"></network-listener>.
3) Add below <system-property-name> tag in <config name="server-config"> tag to declare TRINITI_HOME as constant to use it for Deployment path at all places in
domain.xml and change the value.
For ex : value=”home/TrinitiApps28”
<system-property name="TRINITI_HOME" value="/D:/TrinitiApps28"></system-property>.
For reference screenshot is attached. Add the tag to the highlighted portion in the screenshot :
4) Also add the below changes to the domain.xml file in <applications> tag to add the context name.If <applications> tag is not there then add it after
</system-applications> tag.
<applications>
<application context-root="/tas" object-type="user" name="tas" directory-deployed="true" location="file:${TRINITI_HOME}/infrastructure/tas/">
<property name="appLocation" value="file:${TRINITI_HOME}/infrastructure/tas/"></property>
<property name="preserveAppScopedResources" value="false"></property>
<property name="defaultAppName" value="tas"></property>
<module name="tas">
<engine sniffer="webservices"></engine>
<engine sniffer="security"></engine>
<engine sniffer="web"></engine>
</module>
</application>
</applications>
Copy paste only inner <application> tag and change the context name to your respective context name like tas,tab,tabimpl,fdt,viewer,etc to add more contexts.
5) Also need to increase maxpermsize to 1024m in <jvm-options> tag.
Search for the “<jvm-options>-XX:MaxPermSize” and change the size.
For ex : <jvm-options>-XX:MaxPermSize=1024m</jvm-options>.
Search for the “<jvm-options>-Xmx” and change the size to 4096m.
For ex : <jvm-options>-Xmx4096m</jvm-options>.
6) Add application reference in <servers>(inside <server>) in domain.xml.
<application-ref ref="tas" virtual-servers="server"></application-ref>
And change the ref to your context name.
For ex : ref=”tas” or ref=”tab” ,etc.
7) Now go the below path /glassfish4/glassfish/domains/domain1/docroot/
Open index.html file and search for “go to the Administration Console”.
Change the url from localhost to respective url.
For ex : localhost to hltappsd.global.triniti.com.
8) Place all the jars from /TrinitiApps28/common/ and jars from /TrinitiApps28/common/ googleapi/ to /glassfish4/glassfish/domains/domain1/lib/.
9) Check web.xml file in all contexts where all the <servlet> tags has to be first and all the <servlet-mapping> tag after that. Tags must be in following sequence :
The content of element type "web-app" must match "(icon?,display-name?,description?,distributable?,context-param*,filter*,filter-mapping*,listener*,servlet*,servlet-mapping*,session-config?,mime-mapping*,welcome-file-list?,error-page*,taglib*,resource-env-ref*,resource-ref*,security-constraint*,login-config?,security-role*,env-entry*,ejb-ref*,ejb-local-ref*)".
4.Add host entry for local deployment.
Open “Run” using WINDOWS+R keys press. Search for drivers. Navigate to hosts file and add entry as below:
127.0.0.1 <username>
Example: 127.0.0.1 yourusername
5. Goto-> D:\TrinitiApps28\ETK3\WEB-INF\classes and open actualpath.properties file and update jdk.home property:
Provide your jdk.home path to jdk.home as below:
jdk.home=C:/Program Files/Java/jdk1.7.0_75
6. Run Triniti Cloner as shown in below wink video:
7.Update the initial, optimal and maximum connections in your local to 1,2, 4:
i) Download attached program "ChangeConnectionPoolInDeployment.java".
ii) change the deployment path in program before running, and add required(which are not listed) connections xmls file path.
iii) Compile the program and run it.
8. Restart Glassfish.
9.Access your local instance using url: http://username:8080/tabimpl/logon.html