What is BuildInfo?

BuildInfo is a system that responsible to manage build version information of a game application. The term build in BuildInfo refers to a collection of file (or binary chunks of file for legacy code) of game that is used to download a game according to its current version and store every detail of the build version in the form of build manifest.

AccelByte BuildInfo Service

There are two main components in BuildInfo system as follows:

  1. BuildInfo Service: The main part of BuildInfo system service. It handles all functionalities related to the build process. All communication between buildinfo system and third-party services is managed by this service.
  2. BuildUtil (BuildInfo CLI): This component is a command-line tools that consume BuildInfo service. This program can be run manually or put in CI/CD tool for automation of game release.

The high-level features that BuildInfo system provides consists of:

  1. BuildInfo provides binary and upload management for game and DLC binary.
  2. Buildinfo provides release note management.
  3. BuildUtil (Buildinfo CLI) provides zsync control file generation that will be used for efficient downloads.
  4. Buildinfo supports DynamoDB and MongoDB databases.

About BuildUtil (BuildInfo CLI)

BuildUtil is used to upload game binaries to the cloud storage for further distribution. BuildUtil provides a meta information to be recorded by BuildInfo through BuildInfo service during the uploading session. Currently, there are two versions of BuildUtil that differs in file treatment.

About BuildInfo Service

BuildInfo Service is a part of BuildInfo system service which is responsible to manage all functionalities related to the build process. BuildInfo service is developed using Java and Spring as the framework. Databases supported by BuildInfo Service to store the file manifest (binary files) are MongoDB and DynamoDB. As for the object storage, BuildInfo uses Amazon Web Service (AWS) S3.

How to use Upload Feature using BuildUtil Service

Before using the upload feature from BuildUtil Service, make sure you already have the following requirements:

  1. BuildUtil Client Credential.
  2. Game Client Credential.
  3. IAM URL.

Once you have completed the requirements, you can start uploading your game using BuildUtil. There are two ways to upload a game using BuildUtil.

Upload Game Using Build Util First Option

  1. First you need to download our latest Build Util .exe and save the file in your directory.
  2. Then, open your terminal or command line to run the latest Build Util
  3. Input all the data needed:
    - IAM URL
    - Uploader’s client id (Build Util client ID)
    - Uploader’s client secret (generated when you create the Build Util Client and Client Secret)
    - Log level (optional)
  4. After you click Enter, you will go back to your base. In this process, you can start to upload a game using Build Util
  5. If you proceed, a new line will appear:
    Using config file: Here, you need to input the directory to the config file from the Build Util configuration in the previous steps.
  6. Here are the list of config files you input the directory to:
    - IAM_ROLE_CACHE_EXPIRATION [3600] (optional)
    - IAM_JWKS_REFRESH_INTERVAL [3600] (optional)
    - Type of app (GAME/DLC) [GAME]
      There are two types of game that is supported, GAME and DLC.
      The default value is GAME, but if you want DLC, type DLC in the provided field.
      If you want to use GAME, you can just leave it blank.
    - URL for the BuildInfo service
      Input the base URL of the service you are going to upload.
    - Namespace of the build
      Input the publisher’s namespace.
    - Absolute path to SDK config
      This line requires an absolute path to your SDK config.
      Make sure you already have a compatible file and a clear path to the desired file.

    Here is the preview of the Unity SDK:

    - Absolute directory of the build output
      Input the absolute path directory where your game resides.
   - Relative path to main executable
      Input a relative path to your game, it can be in a form of .exe, .msi, .sh
      or any other type of file. Relative path means that it does not require full path,
      but only the main path of the folder where the game resides. When you input
      the path, the Player client application can directly run the game.
      For example: other/otherexe.exe.

7. There other lines that require information beside the directories:
  - AppId (unique title) of the game
  - Version of the game
     The versioning needs to follow the game version in Admin Portal.
  - Version of BuildInfo endpoint (1 or 2) [2]
     Input the Buildinfo version, either version 1 or 2 depending on your needs.
     The default value is version 2.
  - Platform id for the game [win32 win64 windows linux darwin]
     Input the platform ID for the game to be uploaded into (e.g. windows/linux).
  - Preferred chunk size (OPTIONAL; integer (in bytes) [DEFAULT]
     The chunk size means the game binary to be uploaded in chunks.
     You can leave it blank as the default value is in bites.
  - ignoreconfig file absolute path (OPTIONAL)
     Simply input the path that you are going to ignore.
  - Log level (OPTIONAL)

Overall, the uploading steps in terminal or command line will look like this:

AccelByte BuildInfo Service

When you finish inputting the data, there will be summary where you can see the value you have input before.

AccelByte BuildInfo Service

Input “y” to proceed or “n” to cancel the process. In this example, we input “y” and the game begins uploading.

AccelByte BuildInfo Service
Game Upload Process

Your game will be successfully uploaded when you see the “Resultant BUILDID…”. Your uploaded game will be available in the Admin Portal in the Apps menu.

Upload Game Using Build Util Second Option

  1. First you need to download the latest  Build Util .exe and save the file in your directory.
  2. Then, open your terminal or command line to run the latest Build Util
  3. After that, a new line appears and you need to provide the information for:
    - IAM URL
    - Uploader’s client id
    - Uploader’s client secret
    - Log level (OPTIONAL)
  4. Set up the Game SDK configuration. Please see below for the example fo the Unity SDK configuration.

5. Then, Run upload command. Please use the note below for more information:

  • --url (-u):
    Base URL to the service. For example: ./build-util-v3.3.1-linux_amd64
  • --namespace (-n):
    The publisher namespace.
  • --appID (-a):
    The app id of the game to upload. The app id should be unique, one for each game.
  • --dir (-d):
    Absolute path of the directory containing file to be uploaded.
  • --entrypoint (-e):
    entrypoint/executable game relative path in build folder. Please note that this is relative against the game directory (--dir).
    For example, if the entrypoint is /home/dev/GameA/executable/Game.exe and the specified directory is /home/dev/GameA, then the entrypoint value should be executable/Game.exe.
  • --version (-v):
    Version of the game to upload. For example 1.0.0, 1.0-alpha, etc.
  • --platformId (-p):
    The target platform identifier where the uploaded game will run. Pick one of these value: [ win32, win64, windows, darwin, linux-ia32, linux-amd64, linux-generic ]. For example, you’re targeting the Windows 32-bit then pick the win32.
  • --sdkconfig (-f):
    Absolute path to the SDK config file.
  • --ignore (-g):
    Optional. Absolute path to the ignore file. If you’re going to ignore certain files, create ignore file with same pattern with git ignore file and save it somewhere. You can also just place the file named .ignoreconfig inside the directory of the game to be uploaded and just skip this flag. In that case, BuildUtil will automatically read your file.

Here is the syntax to upload command:
./build-util-v3.3.1-linux_amd64 upload -u <base_url> -n <publisher_namespace> -a <game_appid> -v <game_version> -e <entrypoint_file> -f <absolute_path_to_sdk_config> -d <absolute_path_to_game_directory> -p <game_ platformid>

For example:
./build-util-v3.3.1-linux_amd64 upload -u https://alpha.accelbyte.net -n accelbyte -a other123 -v 1.0 -e "otherexe.exe" -f "/home/taufiqi/Downloads/UnitySDKConfig.json" -d "/home/taufiqi/Documents/samplegame" -p win64

How to use BuildInfo Service System

Most of the BuildInfo Service System can be used by calling or consuming the endpoint that is provided by providing a specified parameter like the uploaded build. BuildInfo Service currently provides two versions that differson how BuildInfo keeps the build file into S3 bucket. In the first version, BuildInfo stores the binary file in a form of chunks with 1 MB in each file size while the second version, BuildInfo stores the binary file as a single file with its control file.

Service flow in BuildInfo start from:

  1. Start Build Upload
    In this endpoint, the user must specify the namespace, appId, version, and platformId to start a new build upload. This API will return a unique buildId that will be stored in the database to be used for computing deltas. This buildId will also be used to set the current buildId.
  2. Start File Upload
    This API will be used to upload file for a given namespace, buildId, filePath, and checksum. The return value for this API are UUID to identify the file and a pre-signed S3 URL to save the binary file.
  3. Commit File Upload
    This API will be used to commit a new file upload for a given buildId and call after the file that has been uploaded to S3. There are some checksum comparisons to see if the file has changed.
  4. Commit Build Upload
    This API will be called if a build uploading process has been completed and ready to be committed.

Contact us at support@accelbyte.io if you'd like to know further how this service runs with your game.