Hi Girish, No, we need to keep "Remote Debugging with Eclipse".
I mean only replace the 2nd option, ie "Step 2: Connect to OFBiz with Eclipse as a Debugger" aka "debug OFBiz inside Eclipse" TIA Jacques Le 27/07/2021 à 15:49, Girish Vasmatkar a écrit :
Hi Jacques Do you mean to not have a section for "Remote Debugging with Eclipse" and just update the details on how to debug OFBiz inside Eclipse? Best, Girish On Tue, Jul 27, 2021 at 3:54 PM Jacques Le Roux < jacques.le.r...@les7arts.com> wrote:Hi Guys, In relation with https://markmail.org/message/had7iszdr7ixtyu3, I propose to replace "Step 2: Connect to OFBiz with Eclipse as a Debugger" at https://cwiki.apache.org/confluence/display/OFBIZ/Running%20and%20Debugging%20OFBiz%20in%20Eclipse by the needed steps (including importing only the main projects, ie ofbiz-framework and ofbiz-plugins[1]) to be able to debug OFBiz inside Eclipse. Actually we should rather clearly separate the 2 steps options. Seems that Steven got confused because of a possible relation between the 2 steps. Could one of you, Ingo or Girish, write or guide us? TIA [1] I tried and after installing Buildship I got submerged by (sub-?)projects corresponding to all the components. Actually I'm used to use only Step 1. Jacques Le 07/09/2020 à 11:44, Ingo Wolfmayr a écrit :Hi Girish, I missed you answer with the JVM arguments. It works now. Thanks alot!!!!Best regards, Ingo -----Ursprüngliche Nachricht----- Von: Girish Vasmatkar <girish.vasmat...@hotwaxsystems.com> Gesendet: Montag, 7. September 2020 11:19 An: ofbizuser <user@ofbiz.apache.org> Betreff: Re: Eclipse debug The buildship plug-in is not recognizing --debug-jvm argument. If youuse simple --debug then it correctly launches gradle with debug enabled.Ideally it should recognize it a valid argument and instruct gradleaccordingly.However, as I mentioned earlier, you can bypass it and provide thedetails to gradle yourself by providing JVM arguments directly and it works fine.You can have two separate Run configurations for normal ofbiz executionand debug execution. In the second configuration, you can specify JVM arguments and it will work fine.Best, Girish On Mon, Sep 7, 2020 at 12:14 PM Ingo Wolfmayr <ingo.wolfm...@wolfix.at> wrote:Hi Girish, my question was more in eclipse user direction: I use the buildship plugin for gradle and the most current version of eclipse. In previous ofbiz versions I opened the "run configuration", added a gradle task and added "ofbizDebug" as task. Then I created a debug task for the debug task. Worked for years. With the new version I would have to add "ofbiz" as task and"--debug-jvm"as argument. The only result I get is: Unrecognized option: --debug-jvm Maybe the plugin cannot handle these kind of arguments? As I asume I am not the only one using Eclipse so I was hoping someone solved that already :) Best regards Ingo -----Ursprüngliche Nachricht----- Von: Girish Vasmatkar <girish.vasmat...@hotwaxsystems.com> Gesendet: Freitag, 4. September 2020 12:45 An: ofbizuser <user@ofbiz.apache.org> Betreff: Re: Eclipse debug Hi Jacques - The documentation seems outdated as it still references an old custom ofbiz debug task - "ofbizDebug". It was removed from build.gradle since gradle supported the command line argument "--debug-jvm" that did exactly what "ofbizDebug" did. I'll update the page if everybody agrees. Best, Girish On Fri, Sep 4, 2020 at 3:27 PM Jacques Le Roux < jacques.le.r...@les7arts.com> wrote:Thanks Girish, That's indeed how most of us do it. BTW Ingo, we have some documentation in wiki: https://cwiki.apache.org/confluence/display/OFBIZ/Running+and+Debugg in g+OFBiz+in+Eclipse Please let me know if it's still up to date (I think so) and useful Thanks Jacques Le 04/09/2020 à 09:37, Girish Vasmatkar a écrit :Hi Ingo I see what you're trying to do. Apparently eclipse is not ownering--debug-jvm and passing it along to gradle for execution. Other command linearguments like --stacktrace, --debug work just fine but you need to setthem in Run Configuration-> GradleTask -> Project Settings -> AdvancedOptions -> Program Arguments. As I mentioned above, if you set --debug-jvm, it won't do anything.However you can try what gradle does under the hood when it receives*--debug-jvm* command line argument. Just pass below to the JVM directlyusing JVM argument -Under Run Configuration-> GradleTask -> Project Settings -> AdvancedOptions -> JVM Arguments*-agentlib:jdwp=transport=dt_socket,server=y,suspend=y,address=500 5* Not sure if you can see the image I pasted below inline instead ofadding it as an attachment. But setting the above line as JVM argument andconfigure the task as 'ofbiz' should get the job done. image.png On Thu, Sep 3, 2020 at 10:41 PM Ingo Wolfmayr <ingo.wolfm...@wolfix.at<mailto:ingo.wolfm...@wolfix.at>> wrote:Hello Girish, it works in command line. I want to setup a eclipse gradle taskunder "run configurations".Best regards, Ingo -----Ursprüngliche Nachricht----- Von: Girish Vasmatkar <girish.vasmat...@hotwaxsystems.com<mailto:girish.vasmat...@hotwaxsystems.com>>Gesendet: Donnerstag, 3. September 2020 16:50 An: ofbizuser <user@ofbiz.apache.org <mailto:user@ofbiz.apache.org Betreff: Re: Eclipse debug Hello *gradlew ofbiz --debug-jvm* should work. --debug-jvm is justsupplied as a parameter.Best, Girish On Thu, Sep 3, 2020 at 7:01 PM Ingo Wolfmayr <ingo.wolfm...@wolfix.at <mailto:ingo.wolfm...@wolfix.at>>wrote: > Hello, > > can anybody tell me how to add a Gradle Task for debugging ofbizin> eclipse: > > gradlew "ofbiz" --debug-jvm > > Where will I have to but the "--debug-jvm"? > > In former ofbiz versions it used to work with adding"debugOfbiz"as> gradle task. > > Thanks for any hint. > > Best regards, > Ingo > > > > >