DEV22: Youve got a problem, heres how to find it - PowerPoint PPT Presentation

1 / 30
About This Presentation
Title:

DEV22: Youve got a problem, heres how to find it

Description:

DEV-22: You've got a problem, here's how to find it ... Log File Archaeology with LogRead. Log files (can) produce a lot of data. Not always easy to read ... – PowerPoint PPT presentation

Number of Views:84
Avg rating:3.0/5.0
Slides: 31
Provided by: peter623
Category:

less

Transcript and Presenter's Notes

Title: DEV22: Youve got a problem, heres how to find it


1
DEV-22 Youve got a problem, heres how to find
it
  • Troubleshooting and debugging your application

Tomas Kucera
Principal Solution Engineer
2
Session Goals
  • Learn how to troubleshoot situations that you
    might find yourself in
  • See tools and techniques used for addressing
    those situations
  • Debugger
  • Logging infrastructure

3
Agenda
  • Diagnosis
  • Bugs
  • Memory leaks
  • Performance
  • The Debugger
  • Other tools
  • Logging framework
  • Profiler
  • Compiler

4
Diagnosis
You know youve got problems when
  • Your application
  • Doesnt do what its supposed to
  • Does things it shouldnt
  • Runs slower and slower over time
  • Queries and reports take a long time
  • Good performance with thick client, not with thin
    client
  • Performance gets worse with more users

5
Diagnosis
Know your enemy
  • Bugs
  • Incomplete, incorrect code
  • Inefficient resource usage
  • Memory leaks
  • Performance
  • Query optimization
  • Roundtrip optimization
  • Network traffic
  • Scalability

6
Agenda
  • Diagnosis
  • Bugs
  • Memory leaks
  • Performance
  • The Debugger
  • Other tools
  • Logging framework
  • Compiler

7
The Debugger
  • Java graphical interface
  • Supports local and remote debugging
  • Supported on all platforms that support Java
  • First official release OpenEdge 10.0A
  • First integrated into OpenEdge Architect in 10.1A

8
Debugger NOT enabled by default
Attachable debugger a potential security risk
  • Environment
  • AppServer

9
Debugger Variants
  • OpenEdge Debugger Perspective
  • First release 10.1A
  • Re-tooled in 10.1B
  • Eclipse Debug Framework integration
  • GUI Debugger
  • Launched from running ABL code, or
  • Attach to running AVM session

10
The OpenEdge Debugger Perspective
  • Use editor actions during debugging
  • Persists breakpoints and settings
  • Multiple concurrent debug sessions
  • Uses source, not compiler listings
  • Can add missing source code
  • Simplified inspection of complex objects

11
The GUI Debugger
  • AppBuilder or Procedure Editor
  • Compile ? Debug
  • Can step into AppServer code from Client session
  • Programmatically
  • DEBUGGER system handle
  • Initiate debugging in AppServer or WebSpeed code
  • MESSAGE statement

DEBUGGERINITIATE().DEBUGGERSET-BREAK().
-debugalert
12
Demo OE Architect Debugger
13
Agenda
  • Diagnosis
  • Bugs
  • Memory leaks
  • Performance
  • The Debugger
  • Other tools
  • Logging framework
  • Profiler
  • Compiler

14
Logging Infrastructure
  • Why log?
  • Report standard run-time activity
  • Log diagnostic data for troubleshooting
  • Data written to log file
  • Control content using log types and levels
  • Unified log file format
  • Log file management (size, number)
  • Available for all ABL clients

15
Logging Set-up
  • LOG-MANAGER handle
  • Run-time GUI or Character client
  • AppServer or WebSpeed agent
  • Progress Explorer
  • AppServer, AIA, WebSpeed, Unified Broker,
    NameServer
  • Separate broker and server logs
  • Startup parameters
  • GUI or Character client

16
Log Entry Types
  • 4GL Interpreter
  • 4GLTrace
  • 4GLTrans
  • DB.Connects
  • DynObjects.
  • FileId
  • QryInfo
  • SAX
  • ProEvents.
  • Client
  • 4GLMessages

-logentrytypes DynObjects.DB,QryInfo
17
Logging Levels
  • 0 None
  • 1 Errors
  • 2 Basic
  • 3 Verbose
  • 4 Extended

-logginglevel 2
18
Log File Management
  • Specify log file name
  • Specify size of log file
  • Specify number of files to keep
  • Rolled-over log file names

-clientlog myLog.log
-logthreshold 536870912
Size in BYTES
-numlogfiles 8
filename..extension
-rw-rw-r-- pjudge 536870912 Mar30
myLog.000001.log -rw-rw-r-- pjudge 536870912 Apr
1 myLog.000002.log -rw-rw-r-- pjudge 2451
Apr 2 myLog.log
19
Log File Archaeology with LogRead
  • Log files (can) produce a lot of data
  • Not always easy to read
  • LogRead is a GUI utility for log files
  • View, manipulate, filter, sort, merge translate
  • Written in ABL
  • Extensible Add custom log handlers
  • Not officially supported
  • Available on PSDN
  • On-line Help

20
What can LogRead do?
  • Loads log files from many sources versions
  • Merge multiple logs
  • Filtering of noise from logs
  • Localization
  • Date formats, code pages
  • Translation of PROMSGS
  • Sorting and searching
  • Timestamp adjustment

21
Demo Logging LogRead
22
Other tools
  • ProSpy Plus
  • Execution logs
  • Profiler
  • Execution timings
  • Compiler
  • COMPILER XREF option
  • Other 3rd party

23
ProSpy Plus
  • Traces actual ABL program execution
  • Uses SESSIONEXECUTION-LOG
  • Logs from the RUN perspective
  • Only trace pertinent parts
  • Turn tracing on and off at will
  • Results displayed in treeview
  • Allows drill-down
  • Shows event types, names, locations

24
Profiler
  • Profile and analyze performance data
  • Data gathered using PROFILER system handle
  • Profiler is a GUI Tool
  • Shows procedure, function timings
  • Temp-table based
  • Drill-down through execution stack
  • Allows side-by-side comparisons
  • Export data to external programs

25
Other tools
  • The Compiler as diagnostic tool
  • INDEX-INFORMATION query attribute
  • COMPILE XREF statement
  • Network analysis
  • Packet sniffing

Now with XML
26
Demo ProSpy, Profiler, etc
27
In Summary
  • Saw different kinds of problems you might
    encounter
  • Looked at various tools used to solve those
    problems
  • Debugger
  • Logging framework
  • Profiler
  • ProSpy Plus

28
For More Information, go to
  • PSDN
  • Profiler
  • http//www.psdn.com/library/entry.jspa?categoryID
    41externalID280
  • ProSpy Plus
  • http//www.psdn.com/library/entry.jspa?categoryID
    83externalID388
  • LogRead 1.0 Tool Overview (English Spanish)  
  • http//www.psdn.com/library/entry.jspa?categoryID
    62externalID1841
  • Log Read Utility
  • http//www.psdn.com/library/entry.jspa?categoryID
    41externalID349
  • Documentation
  • OpenEdge Development Debugging and
    Troubleshooting
  • OpenEdge Deployment Startup Command and
    Parameter Reference

29
Questions?
30
Thank you foryour time
31
(No Transcript)
Write a Comment
User Comments (0)
About PowerShow.com