🏁Installing Pharos Triton

Your journey into logging starts here! This article details how to set up the Pharos Triton tools so you can incorporate logging into your own code base.

1. Installing and Configuring Pharos

First, install the Pharos managed package, which includes the observability platform. There are several options:

Next, complete the basic configuration steps. Please refer to the Pharos guide here. The entire process shouldn't take more than 10 minutes of your time, depending on how quickly the package installs in your org.

Pharos Free Edition is indeed free. Completely. Now and forever. No hidden fees. This is our contribution to the Salesforce community and we will stand by it.

2. Deploy Pharos Triton

There are 2 delivery methods. We recommend option A for its simplicity.

  • Option A: Deploy via an unlocked managed package

  • Option B: Visit us at this Github repo. The code is available and free for all to use and modify as necessary. Feel free to utilize your favorite IDE or deployment tool to release the logger code in all environments as necessary. We recommend that the log util is deployed to production once it has been vetted through your development process. As your sandboxes are refreshed the log util will become available there as well.

If you've evaluated Pharos in the past and installed the Error Generator package, you may notice there is a Log.cls file included. This is actually a condensed version of Pharos Triton with some slight modifications. We recommend you use the official Triton version, however.

3. Platform Event Setup

Pharos Triton is based on platform events. In other words, every time logs are flushed, a platform event gets fired off.

In this section we will configure Pharos to raise platform events, thus enabling the use of the log util.

Let's get started by navigating to Pharos Admin → Advanced → Triton. Follow the steps in this quick tutorial to complete the configuration, and you're done!

Feel free to run a test at the end as well. You can come back to the results in the Logs tab in case the test takes a little while.

Why Platform Events?

Platform events are a great way to ensure reliable logging that will not get rolled back no matter what happens to the original transaction. Platform event operations also don't not count against DML limits, which is important in high volume processing situations. It is the de facto standard for logging on the Salesforce platform and is utilized by many other open source logging frameworks. For more information about platform events please refer to Salesforce developer documentation.

4. Configure Permissions

Pharos Triton comes with three permission sets to help manage access:

Triton End User

  • Purpose: For users who will be running automation that uses Triton logging

  • Access: Provides ability to execute processes that create logs

  • Includes: Access to Triton Apex classes needed for automation execution

  • When to use: Assign to:

    • Experience Cloud (Community) users

    • Users who run screen flows

    • End users executing automated processes

Triton Read

  • Purpose: For users who need to view and analyze logs

  • Access: Read-only access to log records and metadata

  • Includes:

    • Read access to Log Level custom metadata

    • Read access to all log fields (CPU time, heap size, SOQL queries, etc.)

  • When to use: Assign to developers, support staff, and business analysts who need to monitor and troubleshoot using logs

Triton Write

  • Purpose: For Triton and Pharos administrators

  • Access: Complete read/write access to all Triton and Pharos components

  • Includes:

    • Full CRUD access to log records

    • Ability to modify Log Level metadata

    • Complete administrative control

  • When to use: Assign to Triton administrators and Pharos platform administrators

Best Practice: Start with the most restrictive permission set (Triton End User for those running automation, Triton Read for those monitoring logs) and escalate to Triton Write only for dedicated administrators.

5. Start Logging!

This is where the fun begins. We recommend you identify which use cases you'd like to tackle first such as troubleshooting, tracing or profiling, or anything else. Once you have an idea of what you'd like to start with, head on over to Apex Logging Basics to get started.

Last updated