Discussion

4
Replies
3803
Views
nixc1 Member since 2016 4 posts
PEGA
Posted: January 27, 2017
Last activity: January 23, 2018

Reading Runtime Logs (HOW-TO)

The ability to read runtime logs can greatly benefit you while you are troubleshooting automation issues.

However, looking at thousands and thousands of lines can be a daunting task. Please see the below guide on how I approach reviewing runtime logs.

MAKING SENSE OF THE LOG MESSAGES:

The biggest thing to keep in mind is that not every single line in the log matters. In fact, there are only around 5 sets of lines that I look for when first reviewing a log. These are all the lines that contain any of the following text:

  • ExecutionLink
  • propagating From:
  • Control is matched.
  • Control is detached
  • General Information

ExecutionLink lines show you when an execution link has been processed ( these are the yellow lines in your automation ). The line will look something like this:

Info | {Time of execution} | {Thread #} | MTA | Automation | {Automation Name} | {Project Name} | Automation: {Automation Name} - ExecutionLink From: {someControlName.someMethodName} To: {someControlName.someMethodName} ID: {Just some ID}

propagating From: lines show you when a data link has been processed ( these are the blue lines in your automation. The line will look something like this:

Info | {Time of execution} | {Thread #} | MTA | Automation | {Automation Name} | {Project Name} | Automation: {Automation Name} propagating From: {someControlName.someValueProperty} To {someControlName.someValueProperty} Value: {The value that was passed}

Control is matched. lines show you when a control has been matched. The line will look something like this:

Info | {Time of execution} | {Thread #} | STA | Adapters | {Adapter Name} | {Control name}-{Some # I don't care about} | Control is matched. Target: HWND:{Some window handle}, ParentTarget: HWND:{Some window handle}

Control is detached lines show you when a control has been detached (unmatched). The line will look something like this:

Info | {Time of execution} | {Thread #} | STA | Adapters | {Adapter Name} | {Control name}-{Some # I don't care about} | ControlBase.Detach(destroyControl:True) - Control is detached

General Information lines show you when an exception has occurred. The line will look something like this:

Error | {Time of execution} | {Thread #} | MTA | Exception | | | {Exception message}., Verbose Message: General Information

HOW I REVIEW LOGS

Notepad++ is my text editor of choice but any editor should be sufficient for reading logs (file size may become a factor).

To start, I like to mark all of the lines I mentioned above and copy them into a new file. This helps remove a lot of the clutter that I normally won't care about. Plus, in the case when I need more information from the full log, I can always go back and view lines around specific areas I pinpointed in the filtered log.

This process, Notepad++, looks like this (other text editors may be similar):

  1. Select the 'Search' tab.
  2. Click 'Find'
  3. Select the 'Mark' tab.
  4. Select the 'Bookmark line' checkbox.
  5. Enter "ExecutionLink" in the 'Find what:' textbox.
  6. Click 'Mark All' --- NOTE: depending on file size this may take a while
  7. Enter "propagating From:" in the 'Find what:' textbox.
  8. Click 'Mark All' --- NOTE: depending on file size this may take a while
  9. Enter "Control is matched." in the 'Find what:' textbox.
  10. Click 'Mark All' --- NOTE: depending on file size this may take a while
  11. Enter "Control is detached" in the 'Find what:' textbox.
  12. Click 'Mark All' --- NOTE: depending on file size this may take a while
  13. Enter "General Information" in the 'Find what:' textbox.
  14. Click 'Mark All' --- NOTE: depending on file size this may take a while
  15. Close the 'Find' window.
  16. Select the 'Search' tab.
  17. Click 'Bookmark'
  18. Click 'Copy Bookmarked Lines' --- NOTE: depending on file size this may take a while
  19. Select the 'File' tab.
  20. Click 'New'
  21. Paste copied content into newly opened file.
  22. Celebrate!

Bonus: At this point you can style (color) words/phrases to make the log even easier to read.

  1. Highlight a word.
  2. Right-Click
  3. Select 'Style token'
  4. Select a style

Extra Information

  • Not all exception are 'bad'. Benign exceptions do exist.
  • Knowing when a problem happens helps you while reviewing logs.
  • At the top of the log you will see a line with the text "OpenSpan assembly version". This line shows you what version of the product the user is using.
  • If you search for the text "Extracted deployment project". This line shows you the name and version of the deployment package the user is using.
  • Often time developers add their own custom log messages in the solution. You should be aware of these messages and be sure to mark their patterns as well.

***Updated by moderator: Lochan to add FAQ Group Tag***

Robotic Process Automation Developer Knowledge Share
Share this page LinkedIn