Project: AspectJ
Bug 72154 Support for simple dump file
Reported: 2004-08-18 06:00:35 | Status: resolved fixed

When the compiler terminates abnormally (exception) or behaves unexpectedly (warning/error/abort) a simple dump of the compiler state should be produced to aid problem diagnosis. The content and conditions under which the dump is produced should be configurable by the user but the facility should be enabled by default for exceptions. Consequently its inclusion should have negligible impact on compiler performance and footprint. The file should be attached to bug reports to give a complete and objective description of the users environment and support problem resolution where a testcase cannot be provided. One approach is to write a uniquely name file (using date & time) in the current directory e.g ajcore.20040818.105200.txt which should be human readable (it can be zipped if large) to allow the user to potentially diagnose their own problems or remove potentially sensitive data before submission. It should contain basic information such as AspectJ version, system properties and command line as well as failure information such as _full_ exception stack trace, compiler messages and internal compiler state.

Files changed in fix:
org.aspectj.ajdt.core/src/org/aspectj/ajdt/ajc/AjdtCommand.java org.aspectj.ajdt.core/src/org/aspectj/ajdt/ajc/BuildArgParser.java org.aspectj.ajdt.core/src/org/aspectj/ajdt/internal/core/builder/AjBuildManager.java org.aspectj.ajdt.core/src/org/aspectj/tools/ajc/Main.java org.aspectj.ajdt.core/testdata/DumpTestCase/src/HelloWorld.java org.aspectj.ajdt.core/testsrc/org/aspectj/ajdt/internal/compiler/batch/AjdtBatchTests.java org.aspectj.ajdt.core/testsrc/org/aspectj/ajdt/internal/compiler/batch/CompilerDumpTestCase.java weaver/src/org/aspectj/weaver/Dump.java weaver/src/org/aspectj/weaver/World.java weaver/testsrc/org/aspectj/weaver/BcweaverTests.java weaver/testsrc/org/aspectj/weaver/DumpTestCase.java