With respect the Execution Order Limits tab, I set the Profiling logging level to finest and captured a log.
The Execution Overview Limits did populate for me:
Note that the values displayed are being extracted from the LIMIT_USAGE_FOR_NS logging messages (which appear at the Finest Profiling logging level.)
If for some reason the LIMIT_USAGE_FOR_NS entries are missing from your log then the limits tab won't be populated. This may occur if the maximum debug log size is reached and the entries are truncated out of the log.
For the Execution Order Save Order tab...
I believe each line represents a distinct sObject type. E.g. Account, Contact, Opportunity, custom sObjects, ...
Each column is for a CODE_UNIT_STARTED log event. If you click in the coloured cell and then on "Select line in Log Panel" it will take you to the corresponding Execution Log CODE_UNIT_STARTED event. This will tell you the applicable ID (Trigger ID), if it is a before/after insert/update trigger etc...
The colours will depend on the type of event. Looking at the source code for my first event I can see it has the CSS class .BEFORE_TRIGGER_NODE
, which is red. You can see all the events and corresponding colours in https://na2.salesforce.com/sCSS/32.0/sprites/1415904510000/Theme3/default/gc/CSI.css
After pulling it apart I also found the official documentation on the colours - Execution Overview: Save Order, Limits, Timeline, and Executed Units
Color Type
- Red Before trigger
- Orange After trigger
- Green Validation rule
- Blue Assignment rule
- Purple Workflow rule
Finding the best way to analyse a limit problem really depends on what limit you are hitting. The managed packages will probably have separate limits and you will see this next to the LIMIT_USAGE_FOR_NS log messages.
If you are hitting the limits in your code you may want to check the values using the Limits calls in Apex.
E.g.
System.debug(LoggingLevel.Debug, 'someMethod() - Current Query Rows: ' + Limits.getQueryRows() + '/' + Limits.getLimitQueryRows());
System.assert(Limits.getQueries() < Limits.getLimitQueries(), 'Reached Query Limit...');
You need to deserialize into the proper type. In this case, that's the top level class (WeatherLocation
). I stripped out some irrelevant attributes from your payload and it came through clean. Here's the Execute Anonymous
script I used to demonstrate:
public with sharing class WeatherLocation
{
final Location location;
}
public class Location
{
public final String country_iso3166, zip, magic, country;
public final String wmo, state_name, latitude, state;
public final String longitude, city, elevation, full;
}
String payload = '{"location":{"type":"INTLCITY","country":"SP","country_iso3166":"ES","country_name":"Spain","state":"SE","city":"Sevilla","tz_short":"CEST","tz_long":"Europe/Madrid","lat":"37.38000107","lon":"-5.98000002","zip":"00000","magic":"2","wmo":"WLEEC","l":"/q/zmw:00000.2.WLEEC","requesturl":"global/stations/WLEEC.html","wuiurl":"https://www.wunderground.com/global/stations/WLEEC.html"}}';
WeatherLocation instance = (WeatherLocation)JSON.deserialize(payload, WeatherLocation.class);
system.debug(instance);
Best Answer
To use the Developer Console at all, you need the View All Data permission.
To run queries, you need to have the API Enabled permission.
To modify classes and triggers or run anonymous code, you need to have Modify All Data, Author Apex, and View Setup and Configuration.
To change Visualforce pages, components, Lightning, etc, you need the Customize Application permission.
You can read more about the permissions here: Using the Developer Console. Thanks to @sam_s for the link to the documentation.