In the below blog we will cover the steps to migrate your Helical Insight application from older version to version 4.1 GA. Before starting the migration, please take the backup of following files/folders.
- Helical Insight Repository (which contains all reports, dashboard, metadata and other work related files). Take the backup of entire Helical Insight repository folder except the folder called “System”.
Path in Windows: "..\hi\hi-repository" Path in Linux: "../hi/hi-repository"
- Take backup of the globalConnections.xml file. Any database connections that we create and save, those details are present in this file.
Path in Windows: "..\hi\hi-repository\System\Admin\globalConnections.xml" Path in Linux: "../hi/hi-repository/System/Admin/globalConnections.xml"
- User role management migration: Note:This step is applicable if you are migrating from versions before 4.1 (upto version 3.1 GA). If you are migrating from version 4.1, please skip these steps.
If you have implemented SSO then this step can be skipped. If SSO is not implemented then this step has to be followed. These steps are required if you are migrating from version 3.1. This is because the dbschema of user role mangement of version 4.1 is different from version 3.1. Here, we are taking backup of user role information from 3.1 mapping it to 4.1 and storing it over there.
Note: If you have migrated from Derby to some other database to store user role management and other information, please take backup of that accordingly.
a. Download this zip file “Derby-Data-Migration.zip”and extract it.
b. Copy the user role management data present in derby from your current 3.1 instance version of derby folder in the below path into folder “Derby_Data_Migration\derby_3.1”. This is the folder which has just been created as soon as you had extrcted the zip on Step a
c. Open command prompt in the current folder and run the “HelicalInsight4.1_DerbyMigration.jar” using the below command in command prompt
java -jar HelicalInsight4.1_DerbyMigration.jar
d. Once the process is done it will show the below text in the console prompt
THE PROCESS IS ENDED [Not actionable step-for understanding]
e. In the folder “Derby_Data_Migration\derby_4.1” now we have the backup of user role management which is compatible with version 4.1
- Take the backup of your license file, the name of the file is hdi.license file.
Path in Windows: "..\hi\apache-tomcat-7\webapps\hi-ee\hdi.licence" Path in Linux: "../hi/apache-tomcat-7/webapps/hi-ee/hdi.licence"
- Also take the backup of any external jars or Settings you have added, any white labelling files, any custom changes made.
NOTE: In your case the location may be different based on the Helical Insight Installation directory.
Please follow below mentioned steps to install Latest Helical Insight version and restore the backup just taken.
Step 1: Uninstall Helical Insight application. Learn here how to uninstall Helical Insight
Step 2: Get the Helical insight version 4.1 by registering and downloading on company website.
Step 3: Install Helical Insight application by following the blog.
Step 4: Now replace the globalConnections.xml file, hdi.license file, hi-repository folder, hi-ee database into their respective folders. Any other custom changes which are made that backup should also be taken and restored at its respective location.
Step 5: Go to the the path “..\hi\db\” . Take a backup of this folder and delete whatever is present in that folder. Copy the db folder from the path “Derby_Data_Migration\derby_4.1” and paste into 4.1 server db path …………\hi\db
Note: Helical Insight comes with derby database which stores cache and user role information. Not being a production ready database you might have migrated that to db like MySQL. Let’s say if Helical Insight database is migrated on the MySql then follow below steps for migrating that data:
Open the application-context.xml file in any text editor and configure the database (MySQL), which the Helical Insight Application (hi-ee) is going to store and retrieve the user credentials i.e the credentials of users who will use this application. The same database will also be used to enhance the application performance to store caching related information.
Location: {TOMCAT_HOME}\webapps\hi-ee\WEB-INF\classes\application-context.xml Example: "..\Helical Insight\hi\apache-tomcat-7\webapp\WEB-INF\classes\application-context.xml"
Now configure the Bean class of HikariDataSource for driver class name, jdbcURL, username and password.
For Example: If I have dumped my helical Insight database in the MySql then the bean class for the dataSource connection is
<bean class="com.zaxxer.hikari.HikariDataSource" destroy-method="close" id="dataSource"> <property name="driverClassName" value="com.mysql.jdbc.Driver" >="" <property="" <="" bean>="" <="" pre="">
Change the jdbcUrl, username and password of the database as per your configuration.
Now configure the hibernate Dialect for the Data Source, here we are using MySql so we have to provide MySql dialect. Replace the Derby dialect with Mysql dialect.
<prop key="hibernate.dialect">org.hibernate.dialect.MySQLDialect</prop>
Since we are using the MySql database, we have to add the Mysql Connector jar in the Helical Insight lib directory:
Location of the Helical Insight Lib directory: “C:\Program Files\Helical Insight\hi\apache-tomcat-7\webapp\WEB-INF\lib”
Download URL for the Mysql Connector:
Step 6: Add external jars/settings you have taken backup.
Step 7: Since Helical Insight 4.1GA comes with enhanced security, you will find a file defaults.properties at location ../hi/hi-repository/System/Admin. This file can be modified to set the security level for the custom columns, custom filter conditions, custom filter values, filter expressions and having clause.
You can refer to this blog to know about the security rules in detail.
If you are using custom columns/ custom filter conditions or values then you can set the rule to default in lines 68 and 70.
This is the security level that is available in versions older than 4.1 GA. This level of security has been exposed so that during migration from older versions, you can temporarily use “default” rule so that your older reports (where you might have used customcolumn filter expression etc) will continue to work and then start making changes in the report so that they are compatible to “strict-metadata” or other even higher security settings which we provide.
Step 8: Restart the Helical Insight application.
Note : If you were using custom SSO with older version, then below things you need to do after installing version 4.1. Follow the below steps only if you are using the default SSO provided by us and does not have any custom changes :
- With 4.1 default SSO JAR files are present with installer. You just need to uncomment the code in spring-security.xml file located at “….hi\apache-tomcat-7\webapps\hi-ee\WEB-INF\classes”.
- Uncomment below lines of code :
2.1 Uncomment (generally line no 252)
<custom-filter before="CAS_FILTER" ref="customAuthenticationFilter"/>
and comment/delete (generally line no 252)
.
<custom-filter before="CAS_FILTER" ref="authenticationProcessingFilter"/>
- 2 Uncomment below lines (generally line no 371 onwards)
<beans:bean id="customAuthenticationFilter" class="com.helicalinsight.admin.customauth.CustomAuthenticationFilter" parent="authenticationProcessingFilter"> <beans:property name="authenticationManager" ref="authenticationManager"> </beans:property> <beans:property name="authenticationFailureUrl" value="/login.html?error=1"/> <beans:property name="excludeUrls"> <beans:list> <beans:value>/j_spring_switch_user</beans:value> </beans:list> </beans:property> </beans:bean> <beans:bean id="customUserDetailService" class="com.helicalinsight.admin.customauth.CustomUserDetailService"> <beans:property name="roleService" ref="roleServiceImpl"/> <beans:property name="userService" ref="userDetailsService"/> <beans:property name="organizationService" ref="organizationServiceImpl"/> <beans:property name="profileService" ref="profileServiceImpl"/> <beans:property name="namesConfigurer" ref="applicationDefaultUserAndRoleNamesConfigurer"/> </beans:bean>
- After this save the configuration file.
- If you have modified the default role, organization, expirytimezone, encryption algorithm etc then modify the same in customAuthentication.properties file located at “..hi\apache-tomcat-7\webapps\hi-ee\WEB-INF\classes”.
- Restart the tomcat after making all above changes.