Upgrade from 4.21 to 4.22

Windows migration

For Windows deployment migration, you need to decide whether you will want to use the new functionality related to the Watchlist Synchronization to the Edge Streams.

Not enabling the Watchlist Synchronization:
In you do not need this latest feature, simply run the standard SmartFace Platform installer. The wizard run re-creates all required services, updates binaries and executables and executes the database updates as well.

Enabling the Watchlist Synchronization:
If you would like to use the newest feature, please:

  • stop all the SmartFace servicess
  • stop the RabbitMQ service
  • uninstall the RabbitMQ application via Add or Remove Programs
  • run the SmartFace Prerequisities installer wizard and ensure the RabbitMQ is checked for installation. Please proceed with the installation.
  • please proceed with the SmartFace Platform and run the installer. The wizard run re-creates all required services, updates binaries and executables and executes the database updates as well
  • please proceed with the newest version of the SmartFace Station and run the installer. The installation wizard will guide you through the steps

Please apply steps to enable the Watchlist Synchronization feature.

Linux migration

For Linux deployment you need to update docker containers and execute database migration based on the provided Github code. Please see the detailed steps below:

When directly referencing image, update every path to match version above

version: "3.4"
        image: registry.gitlab.com/innovatrics/smartface/sf-base:v5_4.21.0
        container_name: SFBase
        command: --serviceName SFBase
        - 2406:2406
        restart: unless-stopped
        - RabbitMQ__Hostname
        - RabbitMQ__Username
Update container version.

When using pre-configured SmartFace deployment from our github, open .env file and update all versions:

Additional changes to the .env file

Add add new lines into the file

# MQTT RPC timeout

# MQTT config

# Edge stream processor operation modes
Updating the SmartFace Station setup

Changes to the .env.sfstation file are as follows:




  1. Add the file create-wl-stream-generation.sh into your docker-compose.yml’s directory.

  2. Changes to the docker-compose.yml file:

Additional environment variables are added to each service:

- RabbitMQ__VirtualHost
- RabbitMQ__UseSsl

The same environment variables are added to the Access Control service via the lines below:

- RabbitMq__VirtualHost=${RabbitMQ__VirtualHost}
- RabbitMq__UseSsl=${RabbitMQ__UseSsl}

License volume is added to the services sf-streamdatadbworker and sf-graphql-api using the lines below:

  - "./iengine.lic:/etc/innovatrics/iengine.lic"

The edge-stream-processor needs to have 2 additional environment variables:

- OperationMode__MatchingDataStrategy
- OperationMode__LivenessDataStrategy     

One additional service is added:

    image: ${REGISTRY}sf-edge-streams-state-synchronizer:${SF_VERSION}
    container_name: SFEdgeStreamsStateSynchronizer
    restart: unless-stopped
      - RabbitMQ__Hostname
      - RabbitMQ__Username
      - RabbitMQ__Password
      - RabbitMQ__Port
      - RabbitMQ__VirtualHost
      - RabbitMQ__UseSsl
      - RabbitMQ__StreamsPort
      - MQTT__Hostname
      - MQTT__Username
      - MQTT__Password
      - MQTT__Port
      - MQTT__UseSsl
      - ConnectionStrings__CoreDbContext
      - Database__DbEngine
      - AppSettings__Log_RollingFile_Enabled=false
      - AppSettings__Log_RabbitMq_Enabled
      - Rpc__TimeoutMs
      - "./iengine.lic:/etc/innovatrics/iengine.lic"
  1. Additional changes are to the RabbitMQ setup in the dependencies directory. Please open the docker-compose.yml file in the sf_dependencies directory and add new port line to the RabbitMQ:
- "5552:5552/tcp"

And a new environment variable:

RABBITMQ_SERVER_ADDITIONAL_ERL_ARGS: -rabbitmq_stream advertised_host rmq
  1. Also please update the sf_dependencies/etc_rmq/enabled_plugins file to match the content below:
Run upgrade scripts

Simply execute run.sh script shipped in our default deployment.

In case you have custom deployment where you cannot use our pre-build script, please do the chcall database upgrade manually. Please replace variables, such as $(getvalue ConnectionStrings__CoreDbContext), or $DB_ENGINE with your current configuration.

docker run --rm --name admin_migration --volume $(pwd)/iengine.lic:/etc/innovatrics/iengine.lic --network sf-network ${SF_ADMIN_IMAGE} \
        run-migration \
            -p 5 -c "$(getvalue ConnectionStrings__CoreDbContext)" -dbe $DB_ENGINE \
            --rmq-host "$(getvalue RabbitMQ__Hostname)" --rmq-user "$(getvalue RabbitMQ__Username)" --rmq-pass "$(getvalue RabbitMQ__Password)" \
            --rmq-virtual-host "$(getvalue RabbitMQ__VirtualHost)" --rmq-port "$(getvalue RabbitMQ__Port)" --rmq-use-ssl "$(getvalue RabbitMQ__UseSsl)"

In such case please also run the call below to create the s3 buckets correcly:

docker run --rm --name s3-bucket-create --network sf-network ${SF_ADMIN_IMAGE} \
    ensure-s3-bucket-exists --endpoint "$(getvalue S3Bucket__Endpoint)" --access-key "$(getvalue S3Bucket__AccessKey)" --secret-key  "$(getvalue S3Bucket__SecretKey)" --bucket-name "$(getvalue S3Bucket__BucketName)"