Enable debug logging
Instructions on how to enable 'debug' logging on a production device
Introduction
By default, the connector has tracing set to 'info', which limits logging output to it's bare minimum.
For unexpected issues in production, the debug flags have been compiled in the connector, but they are not activeated by default.
This page describes how to enable debug logs for OSX and Windows.
Mac OSX
The debug level can be modified throught the launchagent on OSX.
The possible values are: info|warn|debug
Update log level
Go to the directory of the launch-agents:
cd ~/Library/LaunchAgents/
A connector .plist file can be found (depending on the partner, the naming is different):
Default Trust1Connector launch-agent:
com.t1t.t1c.api.plist
The file has a parameter declaring the log level:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Label</key>
<string>com.t1t.t1c.acc.api</string>
<key>Program</key>
<string>/Users/michallispashidis/Library/Application Support/Trust1Team/Trust1Connector-Acceptance/t1c-acc-api</string>
<key>ProgramArguments</key>
<array>
<string>/Users/michallispashidis/Library/Application Support/Trust1Team/Trust1Connector-Acceptance</string>
<string>-f</string>
...
<string>-x</string>
<string>51883</string>
<string>--log</string>
<string>none,t1c_rust_api=info</string>
<string>--env</string>
<string>prod</string>
</array>
<key>RunAtLoad</key>
<true/>
</dict>
</plist>
The following line can be modified for example to 'debug' log level:
for example:
<string>none,t1c_rust_api=info</string>update to 'debug' level
<string>none,t1c_rust_api=debug</string>Restart the Connector service
After modifying the launch-agent, the service must be restarted. To do so, you need to use launchctl:
Stop the service:
launchctl unload com.t1t.t1c.api.plist
Start the service:
launchctl load com.t1t.t1c.api.plist
The activity monitor can be used to verify if the processes are started correctly:

Verify logging output
Go to the logs-folder where the connector is installed (depends on the partner configuration), by default:
cd ~/Library/Application\ Support/Trust1Team/Trust1Connector/logs
Open the log file and notice the debug logging appears.
Last updated
