views:

218

answers:

4

Using Delphi 7, I wonder if there is a free component which will collect diagnostic information as my application runs at a remote site and will help me to debug error reports.

Maybe it records each menu item selected, control clicked, text input, etc? Maybe it just dumps the stack on a crash. Maybe it does something else ...

I don't mind adding code (e.g at the start and end of each procedure), as that might generate more useful info than a fully automatic system.

I am not sure if the solution ought to "phone home" or if it is enough to produce a text file which can be emailed to me.

Any suggestions?

+7  A: 

with the crash debuging have a look at MadExcept
http://www.madshi.net/madExceptDescription.htm

madExcept was built to help you locating crashes in your software. Whenever there's a crash/exception in your program, madExcept will automatically catch it, analyze it, collect lots of useful information, and give the end user the possibility to send you a full bug report.

free for non-commercial usage, inexpensive for commercial usage

or JclDebug from the JEDI Code Library

http://www.delphi-jedi.org/

A Blog Posting about it can be found here http://www.gnegg.ch/2002/12/jcldebug/

EDIT: This seems to be a very good example on how to use JCLDebug http://robstechcorner.blogspot.com/2009/04/finding-hard-to-reproduce-errors.html

Christopher Chase
+4  A: 

Have you looked at the open-source JclDebug from Project Jedi? Here's a nice succinct write-up on JclDebug.

Imagine you could get a detailed error-report containing a full callstack of where the error occured combined with information about file and line-number. This report could be generated directly on the users computer and be sent to you via email or directly via the internet, using a custom procedure - even directly creating entries in the bugtracking-tool you are using.

This and more is made possible by the Project JEDI - more accuratly, the JCL-Subproject with its JclDebug-Framework. When you have completed the installation of the package, a new Menu Option called "Inser JCL Debug Data" will be added to the Project-Menu of your Delphi-IDE.

Mick
+2  A: 

I use EurekaLog http://www.eurekalog.com

It does the call stack, memory contents, other apps running, a good description of the machine, OS, patches, etc.., It can (with user permission, and if configured to to so) take a screenshot, ask the user for input (what were you doing when it crashed?), etc.. It can send the dump via e-mail, post to http, post directly to bug trackers like Mantis and FogBugz, or just leave it on the system. It's great, and well supported.

Also, here's a link to a similar question http://stackoverflow.com/questions/1931833/compare-delphi-exception-handlers

Chris Thornton
Thanks, sounds great (especially the link) +1
Mawg
+1 for EurekaLog! It helped me fix bugs in minutes when I'd never a clue where to start.
stg
+2  A: 

There is a great delphi porting of the most known opensource logging framework written in java, Log4J: it is called Log4Delphi.

http://log4delphi.sourceforge.net

I downloaded it, extended and used with my projects with success.

Best features: opensource, Apache license, very well documented, simple to extend it, power design: with the concept of appender, you could build up your custom appender and use it to send logging data from remote customer computer to your head quarter using UDP protocol.

Try it, and let me know :-)

PS: the project seems to be discontinued, but it is mature and I'd used it without memory overload and cpu overhead problems.

This sounds great, thanks (+1). Are your extensions only useful to you, or something that you might post for everyone?
Mawg
My extensions are modelled to fit our business data structure, but I'd added also an UDP appender (made with indy) with encryption features to send sensitive logging data across internet. If you are more interested to sources, let me know.