When the PowerServer project is built and deployed in the PowerBuilder IDE, the transaction-to-cache mappings configured in the Database Configuration window will be deployed and stored in PowerServer. You can manually change these settings in the PowerServer C# solution.
To manage the transaction-to-cache mappings in the ServerAPIs project:
-
Open the PowerServer C# solution > ServerAPIs project > AppConfig > Applications.json or Applications.[DBConnectionProfile].json file.
The Applications.json file contains the configuration of the "Default" DB connection profile. If you have another connection profile, the profile name is added in the middle of the file name. For example, Applications.Development.json file contains the configuration of the "Development" DB connection profile.
-
In the Applications.json (or Applications.[DBConnectionProfile].json) file, locate the "Applications" block > [application name] > "CloudTransactions". This is where the transaction-to-cache mapping(s) is stored.
In the following example, the "sqlca" transaction object is mapped to the "salesdemo" database cache. You can modify the existing mapping, or create a new mapping by making a copy of the existing one.
"Applications": { "pssales": { "CloudTransactions": { "sqlca": { "CacheName": "salesdemo" } }, ...
Note: The PowerServer C# solution will be updated every time when the PowerServer project is built and deployed in the PowerBuilder IDE. If you manually modify the settings in Applications.json, and want to keep these changes, you should NOT select the "Overwrite server settings (DB connection, Web API port, and license)" option in the project settings. For more information, refer to What settings will be deployed to the solution.