Organizing, filtering and searching logs

Organize and filter large amounts of logging data. Finding
and resolving issues in complex applications has never been easier.

Both the libraries and the Console have features to organize, filter and categorize your log entries. The libraries let you group and organize your log entries with sessions, a filter event and log levels. The Console on the other hand has strong filtering capabilities which let you concentrate on the important parts of your log, individual threads and processes.

Sessions

By default, the libraries have one session named Main. You can create additional session objects to group your log entries and enable or disable entire log categories. Each session has a name and a color to identify, filter and highlight the corresponding log entries in the Console.

// Create a new session for client 982
Session blue = SiAuto.Si.AddSession("Client #982");
blue.Color = System.Drawing.Color.LightBlue;
blue.LogMessage("Logged In");

...

// And another one for client 289
Session yellow = SiAuto.Si.AddSession("Client #289");
yellow.Color = System.Drawing.Color.LightYellow;
yellow.LogMessage("Logged In");
' Create a new session for client 982
Dim blue As Session = SiAuto.Si.AddSession("Client #982")
blue.Color = System.Drawing.Color.LightBlue
blue.LogMessage("Logged In")

...

' And another one for client 289
Dim yellow As Session = SiAuto.Si.AddSession("Client #289")
yellow.Color = System.Drawing.Color.LightYellow
yellow.LogMessage("Logged In")
// Create a new session for client 982
Session blue = SiAuto.si.addSession("Client #982");
blue.setColor(java.awt.Color.BLUE);
blue.logMessage("Logged In");

...

// And another one for client 289
Session yellow = SiAuto.si.addSession("Client #289");
yellow.setColor(java.awt.Color.YELLOW);
yellow.logMessage("Logged In");
{ Create a new session for client 982 }
Blue := Si.AddSession('Client #982');
Blue.Color := clBlue;
Blue.LogMessage('Logged In');

...

{ And another one for client 289 }
Yellow := Si.AddSession('Client #289');
Yellow.Color := clYellow;
Yellow.LogMessage('Logged In');

The resulting log in the SmartInspect Console looks like the following example. The first View displays all entries of your log and newly created session Views show the log entries of a specific session only.

SmartInspect Sessions

Views and Filters

You can create multiple Views with filters to view different parts of your log separately from each other. It is possible, for example, to have a View with all log entries and an additional View which shows errors only. Additionally, you can create Views that only contain log entries of a certain thread, process, session, host or application.

SmartInspect Views
  1. Multiple Views let you concentrate on the important parts of your log. You can analyze log entries, processes and threads independently from each other and closely monitor the behavior of your application.
  2. You can group and organize views in so called View Categories and specify if a View displays a tree structure with call stack information or a flat list of log entries.
  3. You can set filters to specify which log entries are visible in the View. Filters can be combined for maximum flexibility.

Log Levels

You can specify a log level for each log entry to group your log entries by their severity. It is possible to specify the active log level of the libraries and thus decide which groups of log entries are logged and discarded.

SiAuto.Si.Level = Level.Warning;
SiAuto.Main.LogError("Lost connection to client #982!"); // Is logged
SiAuto.Main.LogObject(Level.Verbose, "client", client); // Is discarded
SiAuto.Si.Level = Level.Warning
SiAuto.Main.LogError("Lost connection to client #982!") ' Is logged
SiAuto.Main.LogObject(Level.Verbose, "client", client) ' Is discarded
SiAuto.si.setLevel(Level.Warning);
SiAuto.main.logError("Lost connection to client #982!"); // Is logged
SiAuto.main.logObject(Level.Verbose, "client", client); // Is discarded
Si.Level := lvWarning;
SiMain.LogError('Lost connection to client #982!'); { Is logged }
SiMain.LogObject(Level.Verbose, 'client', client); { Is discarded }