SFDX Lens
The quickest way to set up trace flags for a chosen active Salesforce user in any connected org. Without leaving VSCode.
Commands / FeaturesAll features are accessible from the VS Code command palette using the shortcut Debug User
Lets the current user to pick a name from a list of Salesforce active users in the current connected org, then creates a Trace Flag for that user. In its variant, lets the current user to pick an Org name from a list of Connected Salesforce Orgs, then executes the same steps above on the chosen Org. This feature is even available from the 🔎 button icon in VSCode's status bar on the left side. Set up a trace flag and download the log:
Log Analysis
When invoked on an Apex Log, it opens a new page tab showing the log's timeline, divided in each part proportional to its duration. Every log section is clickable and upon clicking the corresponding code is displayed, up to the first 100000 characters for performance reasons. You can search the code for a particular string through a fixed search bar displayed on the right side of the page. Perform a log analysis:
Object fields analysis
This command allows Objects field inspection to gain metrics about field usage and a suggestion about which field can potentially be safely deleted. This functionality leverages both SOQL and tooling API to identify those fields and creates a graph using Chart.js to represent usage data. The delicate part: what is being measured?
e.g. Timeframe set to 12 months
Account created 3 years ago with customfield__c set and updated yesterday to the value 'ACME' -------> won't be counted despite having customfield__c set API UsagePlease be advised that this functionality uses API calls that counts towards your org limit. For each field inspected it uses 3 API calls so keep that in mind if you're short on those. SettingsThere are a few user settings you can play with (File > Preferences > Settings > Extensions > SFDX Lens): Number Of Apex Refences Number Of Months Number Of Records Number Of Validation Refences Requirements
Notes
Release Notes0.0.4Initial release 0.0.5Explicitly retargeted MAX_LIMIT_EXCEEDED error when setting up a trace flag in an org hitting the max debug log size limit 0.0.5Explicitly retargeted MAX_LIMIT_EXCEEDED error when setting up a trace flag in an org hitting the max debug log size limit 1.0.0Though in Beta, the SFDX Lens: Log Analysis command is released, giving the extension the ability to set up and inspect logs 2.0.0The SFDX Lens: Object fields analysis command is released, giving the extension the ability to gather and display field usage data IssuesYou can report issues here |