Manage Your Horizon Environemnt.(Part 2) – Updating your thinapp packages in horizon

New Package.ini Parameter, VersionID. made specifically for Horizon

Before thinapp 4.7.2 which i wrote about its release here. we use to upgrade the packages using AppSync or side-by-side updating mechanism. Now you don’t need to use any of these methods any more since the update will be based on a new parameter in the Package.ini file called VersionID.


To understand more about this we need to discuss how this VersionID actually works and what are the relationships that connects it to horizon.

So VersionID as obvious from the name is the version of the thinapp package that work in conjunction with another package identifier parameter in Package.ini file called AppID. So in case that you do an update for the thinapp package, AppID stays the same but VersionID Gets incremented. You place the updated package in a new folder on the ThinApp Repository in the Horizon environment. Horizon regularly scans the ThinApp Repository, and when Horizon encounters an application that has the same AppID as another, it compares the VersionID values and considers the application with the higher VersionID to be an update. keep in mind that AppID is one of the mandatory requirement of horizon that is one of the reasons why you require version 4.7 as a minimum for thinapp to be able to use the packages for horizon. so if you packaged your applications with a version thinapp that is prior to 4.7 then you need to recapture the application with thinapp 4.7 or later releases.

What About User Entitlement and application downloaded to the end-points?

This update mechanism in horizon preserve user entitlement to the applications and also change the location to the new path for the update thinapp Package for the shortcut in the end-point.


So now you have 3 Methods that you can do to upgrade your thinapp package.

1- Capture the new update in thinapp setup capture.

2- Edit Package.ini file and rebuild, this means a manual change in the VersionID.

3- VersionID Flag with relink command.

so i am going to discuss each one of these options

1- Capture the New Update using thinapp Setup Capture:

Setup Capture has a couple of new fields in the Manage with Horizon window to help you to mark a package as an update of another package already in Horizon.


After you select This package is an update of an existing base ThinApp package, you enter the original package location in the Base package location field. This is the location of the folder of old ThinApp executables, which can either be in place in Horizon, or copied elsewhere.

When you point to this prior package, ThinApp reads the AppID and assigns the same AppID to the updated package. In addition, ThinApp reads the VersionID of the original package and increments it by 1 to assign a new value of VersionID to the updated package.

2-  Edit Package.ini file and rebuild, this means a manual change in the VersionID.


When would you choose to edit Package.ini to update a ThinApp package for Horizon?

You might want to update a package by editing Package.ini if:

  • You do not have the application installer for recapture
  • You need to update the package to the new version of ThinApp, and you need to update more than the ThinApp runtime (which relink would handle). Rebuilding incorporates changes to the file system and registry which are in a new version of ThinApp. For example, the new version of ThinApp might have a new Package.ini parameter that you want to set; a rebuild is necessary to incorporate this kind of change from the new ThinApp version.

How do you update a ThinApp package for Horizon by editing Package.ini?

To mark the new package as an update, edit the following Horizon parameters in the [BuildOptions] section of Package.ini:

  • Set AppID to match the AppID of the prior version of the application. You cannot reuse a value of genid for AppID, or a new AppID will be generated for the updated package.
  • Increment VersionID to one higher integer than the prior package. If the prior package has no VersionID, its value is 1 by default, so give your updated package a value of 2 for VersionID.
  • Make sure the InventoryName matches the InventoryName of the prior version of the application. The InventoryName values for the prior and new packages must be identical.
After you rebuild the package, place the executables in a new folder on the ThinApp Repository in Horizon, exactly as for Setup Capture updates.

 3- VersionID Flag with relink command.

When would you choose relink -h to update a ThinApp package for Horizon?

Relink -h is a good candidate for updating an application if:

  • You already captured, built, and tested the package and are ready to enable the updated package for Horizon and then place it in the ThinApp Repository in the Horizon environment
  • You want to update only the ThinApp runtime for the package to incorporate bug fixes in the new ThinApp version
  • You only need to enable the package for Horizon
  • You do not have the project folder for an application

Relink is very fast; you do not need to recapture or rebuild the package. And you do not need the application project directory to run relink.

For example, if you have tweaked the project directory, including Package.ini, for a virtual application, rebuilt the package, and tested the package, your test environment was probably not Horizon. The final stage of updating the application is to enable it for Horizon. At that point, the easiest route is to use relink -h. You would not want to recapture or rebuild.

How do you use the relink command to update a ThinApp package that is in Horizon?

In brief, relink -h enables a package for Horizon and updates the ThinApp runtime at the same time. You need to either run relink on the old package to pick up the AppID, or else specify the same AppID as for the old package you are updating. You can increment VersionID to create a versioned update that you place in a new folder on the ThinApp Repository, or you can skip setting VersionID and replace the old package In the ThinApp Repository. Both methods use the same AppID, so entitlements and shortcuts are preserved from the old application in Horizon.


Leave a Reply

Your email address will not be published. Required fields are marked *