Upgrade from 1.19.0 to 1.20.0

gvencode Options Have Changed

The gvencode option -p healthPort is now -h healthAddress which requires a string containing IPAddress:Port. Make sure you adjust any templates that call gvencode.

Nomad Upgraded

We upgraded the version of Nomad used in the Genvid SDK, which might require some adjustments to your code.

Most importantly, IPv6 addresses will be preferred by default for jobs started by Nomad on Windows. We added IPv6 support on the backend because of this change. You might need to adjust your Nomad templates to detect IPv6 addresses (For example, ::1) and wrap them properly.

If you based your setup on one of the Genvid SDK samples, make sure you replace config.ts in your setup with /samples/tutorial/web/utils/config.ts which correctly wraps IPv6 addresses.

Note

The updated config.ts file is the same for all the Genvid SDK demos.

New JavaScript API Modules

The Genvid SDK now supports importing our JavaScript modules as NPM packages. To do so, first install both the genvid and genvidMath packages:

npm install -s path/to/genvid.tgz
npm install -s path/to/genvid-math.tgz

Then you can import them normally:

import { createGenvidClient, IGenvidClient } from 'genvid';
import * as genvidMath from 'genvid-math';

Note

If you plan on dockerizing your web app, you must copy the tgz file in your Docker before importing it.

See either the Web sample or Load Tester sample for examples of importing Genvid modules as NPM packages and dockerizing them.

When referencing scripts from a <scrip src=”…”/> tag, we recommend you reference the genvid.umd.js and genvid-math.umd.js files. The “genvid” lib is exposed as the global variable genvid and the “genvid-math” lib as genvidMath.

We advise against including the Genvid TypeScript definition files directly in your source code. The Genvid SDK includes them in the /api/web/legacy_types/ folder if you need them to simplify your upgrade.

See the DirectX Cube Sample Integration and Unreal Engine samples for working examples of this method.

See the Website Integration section for more detailed information.

DockerTool No Longer Sets DOCKER_MACHINE_NAME to default

DockerTool no longer sets the environment variable DOCKER_MACHINE_NAME to default if it isn’t already set. The client uses its default settings to connect to a Docker host, which it can get from other environment variables. This should allow DockerTool to work with a local Docker that doesn’t use Docker Machine, such as Docker for Windows.

Known Issue: Terraform Command Crashing After Upgrade

In some cases, running a Terraform command from the Bastion UI on an existing cluster can cause the Terraform command to crash. If you encounter this issue:

  1. Go to .genvid/terraform/workdir/YOUR_CLUSTER_NAME/tf/.terraform/ (under your user folder).
  2. Delete all the modules and files in the folder.
  3. Re-import the module from the command page.

Afterwards, your Terraform command should run correctly.

Known Issue: Error When Trying To Destroy Or Plan Apply an Existing Cluster After Upgrade

After an upgrade of the Genvid SDK, the [PLAN APPLY] and [PLAN DESTROY] terraform commands will fail with the following message:

Error: Error loading modules: module vpc: not found, may need to run ‘terraform init’

To fix this simply re-import the module:

  1. Open Bastion-UI
  2. Click on Terraform
  3. Click on the link with your cluster name on the left navigation bar
  4. Click re-import module
  5. Click [PLAN DESTROY] or [PLAN APPLY]
  6. Should work!

Local Cluster No Longer Configured During Bastion Setup

The genvid-bastion install command no longer automatically sets up a local cluster. Before running other genvid-sdk commands, you can create a local cluster by running:

genvid-sdk setup

This is required even if you are upgrading a local cluster you set up previously.

After setting up your local cluster, configure it by running:

genvid-sdk load-config-sdk

C Sharp Wrapper Now Detects Failure Statuses

You can use the function statusFailed(status) to validate if a returned status from any Genvid SDK function is considered a failure. This function filters out warnings which aren’t errors.

To update, copy the new C Sharp wrapper DLL over your current one.

For the Unity sample and prefab, rebuild the Genvid SDK Unity Package with the new C Sharp wrapper and re-install it in your project.