Important: if something bad happens (DRD doesn't launch, errors occur or smth else), please feel free to contact us: email@example.com. Also we kindly ask to attach all three log files to your bug report. Thanks!
Data Race Detector (DRD) is a tool for dynamic detection of data races in Java programs, implemented as a java agent. DRD works in same JVM with the target application and dynamically detects occuring and possible races. Results are logged to files, for each race additional information is printed: class+method+line number for both accesses, race type, at least one stacktrace.
How to use:
- Download the last DRD version and unzip it to some folder (we'll further refer to it as DRD_HOME_DIR)
- Go to DRD_HOME_DIR/config directory. Rename two files in it: config-example.xml to config.xml and hb-config-example.xml to hb-config.xml
Open config.xml. Find RaceDetection section and assure that rules inside it cover exactly your application and nothing more. Usually it's enough to have one rule based on unique prefix of your application packages. Also check that SyncInterception section is empty and defaultPolicy is "*":
Open drd.properties. Set "drd.config.dir" and "drd.log.dir" properties:
Locate exact place where java (javaw, ...) is actually executed to launch your application. Add (prepend) DRD java agent and settings to launch parameters the following:
That's it! If everything is fine, your application would start normally (most likely it work slower that usual). DRD results would be logged into three files in specified log directory.