How-To: Setup dedicated appData and storeForwardData directories
Overview
Intelligence Hub can utilize two file directories: appData for configuration files and storeForwardData for temporarily files used with output Store and Forward.
By default these directories are stored side-by-side with the application code in the runtime folder. By setting up an Application Data Directory, managing upgrades for the HighByte Intelligence Hub becomes more streamlined.
Steps to Set up appData Directory
-
Manually create an appData folder Directory (example C:\HighByte\AppData\EnvName)
- Create a directory named ‘appData’. It is recommended that the directory should live independently of the code to avoid association within a specific version directory. For example, you might set it up as
C:\HighByte\AppData\EnvName
which would be alongside the code inC:\HighByte\HighByte-Intelligence-Hub-X.x
but in its own subdirectory.
- Create a directory named ‘appData’. It is recommended that the directory should live independently of the code to avoid association within a specific version directory. For example, you might set it up as
-
Configure appData Directory
-
Before starting the runtime, navigate to the
runtime
folder and find the file namedintelligencehub-settings.json.template
-
Rename this file to
intelligencehub-settings.json
-
Open this file in a text editor and edit the ‘appData’ setting as follows
-
json
"settings": { "directories" : { "appData" : "C:\\HighByte\\AppData\\EnvName", "storeForwardData" : null }, }
Note: On Windows, backslashes must be escaped using
\\
syntax.
-
-
Place Application Data in the appData Directory
-
If you are migrating, place the following Application Data files in the appData directory
- ‘Intelligencehub-cache.db’
- ‘Intelligencehub-configuration.json’
- ‘Intelligencehub-events.log’
- ‘Intelligencehub-remoteconfig.json’
- ‘Intelligencehub-certificatestore.pkcs12’
- ‘Intelligencehub-users.json’
- ‘Intelligencehub-state.db’
- ‘intelligencehub-state.dat’
- ‘intelligencehub-identityproviders.json’
- intelligencehub-writestore
.db
-
Note- Existing files are not moved to the ‘appDirectory’. The application will also become unaware of existing configuration files in the runtime directory. Either move the existing files into the appData directory or new files will be automatically generated if they do not exist.
Steps to Set up storeForwardData Directory
Store and Forward is an important functionality used to buffer data in the Intelligence Hub. It is a setting that can be used within the Hub to ensure there is no loss of data when events are coming into the Intelligence Hub faster than they can be written. Setting up a distinct directory for store and forward data can organize the buffered data efficiently.
It’s recommended to set the storeForwardData directory to a storage device, separate to the operating system.
-
Manually create a folder Directory for storeForwardData (example D:\HighByte\StoreForwardData\EnvName)
- Just like the ‘appData’ directory, create a separate directory to store the buffered data. It can be alongside your ‘appData’ directory or any accessible location.
-
Edit the storeForwardData Setting
- Open the ‘Intelligencehub-settings.json’ file in a text editor
- Edit the ‘storeForwardData’ setting in the “settings” section to point to your newly created ‘storeForwardData’ directory
-
json
"settings": { "directories" : { "appData" : "C:\\HighByte\\AppData\\EnvName", "storeForwardData" : "D:\\HighByte\\StoreForwardData\\EnvName" }, }
-
Verify the Configuration
- After making these changes, start the runtime and verify the store and forward data is being directed to the new directory. Ensure the directory is accessible and has adequate space to store the buffered data.