Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

This is the official recommended way for debugging ofbiz. It's fine, personnaly (Jacques Le Roux) I use also the second method below : [Running Debugging (or debuggingrunning) OFBiz in Eclipse. It's really helpful when it comes to debug the framework java code. When someone has screwed up the framework java code (it rarely happens rarely but Adam is able to do it fromt time to time ;o) and you can't load OFBiz. Then you have no other way than it's an easy way to debug OFBiz using inside debugging. Though using the remote debuggind technique, you may also suspend the JVM through the command line options at start up. Effectively the JVM boots, stops and waits for a debugger to connect and then it continues so you can still use remote debugging. Just put suspend=y in the start options alongside the socket and ports settings (thanks Ray)

OFBiz in Eclipse|#debuggingInEclipse]

...

  • Select OFBiz project, right-click on it -> Run As -> Run ... (alike for Debug)
  • Select Java Application and click on New
  • Set Run configuration name to OFBiz
    • Main tab:
      • Project: OFBiz
      • Main class: org.ofbiz.base.start.Start
      • If you need it (to trace a framework bug in the 1st loaded class) you may use the "Stop in Main" Option
    • Arguments:
      • VM arguments: -Xms(minValue)M -Xmx(maxValue)M  (typically minValue = 128, maxValue = 512, more is better of course) -Duser.language=en  
        • In some case (Suse  SL 10.1 at least) it's better to not define any VM arguments but let the defaults values.
      • Working directory: Use default working directory
    • Classpath
      • Bootstrap Entries: JRE System Library
      • User Entries: ofbiz.jar from OFBiz project
        • Don't forget to remove the entry "ofbiz (default classpath)" else you may have a message "Can't find bundle for base name cache, locale ..."
    • Source tab
      • Click Add Projects... (buttons on the right)
      • Select the ofbiz project
    • Environment
      • Add environment variable LC_ALL=C (Optional, Linux only)
  • Click on Apply and Run (or Debug)

...