remote debugging

classic Classic list List threaded Threaded
19 messages Options
Reply | Threaded
Open this post in threaded view
|

remote debugging

Vijay Srinivasaraghavan
How do I attach remote debugger to running Flink cluster from IntelliJ? Appreciate if anyone could share the steps?
RegardsVijay
Reply | Threaded
Open this post in threaded view
|

Re: remote debugging

stefanobaghino
I had to do it a couple of times. Wonderful experience to understand the
inner workings of Flink and explore it while running.
I don't know if there's a preferred way to do this but this is how I did it:

Edit the run configurations in IntelliJ, click the + icon in the upper left
corner, choose the "Remote" preset.
Under the "Settings" pane, fill in the remote host where you'll run Flink.
Copy the "Command line arguments for running remote JVM".
Go to the machine running Flink, choose the launch script you need to
"hijack" and append the copied arguments after the "java" command. Make
sure to set "suspend=y" if you want to make sure Flink doesn't start
without your debugger attached.

Now simply run Flink with the script you tampered with and run the
debugger. Please note that if you set "suspend=y" Flink won't start until
the debugger is attached to the process. Also beware that if the machine
running Flink is far away from the remote debugger you may suffer from
increased latency when debugging.

Hope I've been helpful, happy hacking. :)

On Mon, May 16, 2016 at 6:43 PM, Vijay Srinivasaraghavan <
[hidden email]> wrote:

> How do I attach remote debugger to running Flink cluster from IntelliJ?
> Appreciate if anyone could share the steps?
> RegardsVijay




--
BR,
Stefano Baghino

Software Engineer @ Radicalbit
Reply | Threaded
Open this post in threaded view
|

Re: remote debugging

Vijay Srinivasaraghavan
Awesome, thanks Stefano!!

    On Monday, May 16, 2016 9:57 AM, Stefano Baghino <[hidden email]> wrote:
 

 I had to do it a couple of times. Wonderful experience to understand the
inner workings of Flink and explore it while running.
I don't know if there's a preferred way to do this but this is how I did it:

Edit the run configurations in IntelliJ, click the + icon in the upper left
corner, choose the "Remote" preset.
Under the "Settings" pane, fill in the remote host where you'll run Flink.
Copy the "Command line arguments for running remote JVM".
Go to the machine running Flink, choose the launch script you need to
"hijack" and append the copied arguments after the "java" command. Make
sure to set "suspend=y" if you want to make sure Flink doesn't start
without your debugger attached.

Now simply run Flink with the script you tampered with and run the
debugger. Please note that if you set "suspend=y" Flink won't start until
the debugger is attached to the process. Also beware that if the machine
running Flink is far away from the remote debugger you may suffer from
increased latency when debugging.

Hope I've been helpful, happy hacking. :)

On Mon, May 16, 2016 at 6:43 PM, Vijay Srinivasaraghavan <
[hidden email]> wrote:

> How do I attach remote debugger to running Flink cluster from IntelliJ?
> Appreciate if anyone could share the steps?
> RegardsVijay




--
BR,
Stefano Baghino

Software Engineer @ Radicalbit


   
Reply | Threaded
Open this post in threaded view
|

Re: remote debugging

Stephan Ewen
Hey Stefano!

I think that question is bound to come up again. I created a page in the
Flink Wiki to document this.

If you have a few moments, would be great if you could add your description
there:
https://cwiki.apache.org/confluence/display/FLINK/Remote+Debugging+of+Flink+Clusters
(it is linked from the front page
https://cwiki.apache.org/confluence/display/FLINK/Apache+Flink+Home )

Greetings,
Stephan


On Tue, May 17, 2016 at 4:26 AM, Vijay Srinivasaraghavan <
[hidden email]> wrote:

> Awesome, thanks Stefano!!
>
>     On Monday, May 16, 2016 9:57 AM, Stefano Baghino <
> [hidden email]> wrote:
>
>
>  I had to do it a couple of times. Wonderful experience to understand the
> inner workings of Flink and explore it while running.
> I don't know if there's a preferred way to do this but this is how I did
> it:
>
> Edit the run configurations in IntelliJ, click the + icon in the upper left
> corner, choose the "Remote" preset.
> Under the "Settings" pane, fill in the remote host where you'll run Flink.
> Copy the "Command line arguments for running remote JVM".
> Go to the machine running Flink, choose the launch script you need to
> "hijack" and append the copied arguments after the "java" command. Make
> sure to set "suspend=y" if you want to make sure Flink doesn't start
> without your debugger attached.
>
> Now simply run Flink with the script you tampered with and run the
> debugger. Please note that if you set "suspend=y" Flink won't start until
> the debugger is attached to the process. Also beware that if the machine
> running Flink is far away from the remote debugger you may suffer from
> increased latency when debugging.
>
> Hope I've been helpful, happy hacking. :)
>
> On Mon, May 16, 2016 at 6:43 PM, Vijay Srinivasaraghavan <
> [hidden email]> wrote:
>
> > How do I attach remote debugger to running Flink cluster from IntelliJ?
> > Appreciate if anyone could share the steps?
> > RegardsVijay
>
>
>
>
> --
> BR,
> Stefano Baghino
>
> Software Engineer @ Radicalbit
>
>
>
>
Reply | Threaded
Open this post in threaded view
|

Re: remote debugging

stefanobaghino
+1, great idea, I should've had it myself. :)

I'll do it today, thanks for creating the page.

On Tue, May 17, 2016 at 11:24 AM, Stephan Ewen <[hidden email]> wrote:

> Hey Stefano!
>
> I think that question is bound to come up again. I created a page in the
> Flink Wiki to document this.
>
> If you have a few moments, would be great if you could add your description
> there:
>
> https://cwiki.apache.org/confluence/display/FLINK/Remote+Debugging+of+Flink+Clusters
> (it is linked from the front page
> https://cwiki.apache.org/confluence/display/FLINK/Apache+Flink+Home )
>
> Greetings,
> Stephan
>
>
> On Tue, May 17, 2016 at 4:26 AM, Vijay Srinivasaraghavan <
> [hidden email]> wrote:
>
> > Awesome, thanks Stefano!!
> >
> >     On Monday, May 16, 2016 9:57 AM, Stefano Baghino <
> > [hidden email]> wrote:
> >
> >
> >  I had to do it a couple of times. Wonderful experience to understand the
> > inner workings of Flink and explore it while running.
> > I don't know if there's a preferred way to do this but this is how I did
> > it:
> >
> > Edit the run configurations in IntelliJ, click the + icon in the upper
> left
> > corner, choose the "Remote" preset.
> > Under the "Settings" pane, fill in the remote host where you'll run
> Flink.
> > Copy the "Command line arguments for running remote JVM".
> > Go to the machine running Flink, choose the launch script you need to
> > "hijack" and append the copied arguments after the "java" command. Make
> > sure to set "suspend=y" if you want to make sure Flink doesn't start
> > without your debugger attached.
> >
> > Now simply run Flink with the script you tampered with and run the
> > debugger. Please note that if you set "suspend=y" Flink won't start until
> > the debugger is attached to the process. Also beware that if the machine
> > running Flink is far away from the remote debugger you may suffer from
> > increased latency when debugging.
> >
> > Hope I've been helpful, happy hacking. :)
> >
> > On Mon, May 16, 2016 at 6:43 PM, Vijay Srinivasaraghavan <
> > [hidden email]> wrote:
> >
> > > How do I attach remote debugger to running Flink cluster from IntelliJ?
> > > Appreciate if anyone could share the steps?
> > > RegardsVijay
> >
> >
> >
> >
> > --
> > BR,
> > Stefano Baghino
> >
> > Software Engineer @ Radicalbit
> >
> >
> >
> >
>



--
BR,
Stefano Baghino

Software Engineer @ Radicalbit
Reply | Threaded
Open this post in threaded view
|

Re: remote debugging

Stephan Ewen
Super, thanks!

On Tue, May 17, 2016 at 11:32 AM, Stefano Baghino <
[hidden email]> wrote:

> +1, great idea, I should've had it myself. :)
>
> I'll do it today, thanks for creating the page.
>
> On Tue, May 17, 2016 at 11:24 AM, Stephan Ewen <[hidden email]> wrote:
>
> > Hey Stefano!
> >
> > I think that question is bound to come up again. I created a page in the
> > Flink Wiki to document this.
> >
> > If you have a few moments, would be great if you could add your
> description
> > there:
> >
> >
> https://cwiki.apache.org/confluence/display/FLINK/Remote+Debugging+of+Flink+Clusters
> > (it is linked from the front page
> > https://cwiki.apache.org/confluence/display/FLINK/Apache+Flink+Home )
> >
> > Greetings,
> > Stephan
> >
> >
> > On Tue, May 17, 2016 at 4:26 AM, Vijay Srinivasaraghavan <
> > [hidden email]> wrote:
> >
> > > Awesome, thanks Stefano!!
> > >
> > >     On Monday, May 16, 2016 9:57 AM, Stefano Baghino <
> > > [hidden email]> wrote:
> > >
> > >
> > >  I had to do it a couple of times. Wonderful experience to understand
> the
> > > inner workings of Flink and explore it while running.
> > > I don't know if there's a preferred way to do this but this is how I
> did
> > > it:
> > >
> > > Edit the run configurations in IntelliJ, click the + icon in the upper
> > left
> > > corner, choose the "Remote" preset.
> > > Under the "Settings" pane, fill in the remote host where you'll run
> > Flink.
> > > Copy the "Command line arguments for running remote JVM".
> > > Go to the machine running Flink, choose the launch script you need to
> > > "hijack" and append the copied arguments after the "java" command. Make
> > > sure to set "suspend=y" if you want to make sure Flink doesn't start
> > > without your debugger attached.
> > >
> > > Now simply run Flink with the script you tampered with and run the
> > > debugger. Please note that if you set "suspend=y" Flink won't start
> until
> > > the debugger is attached to the process. Also beware that if the
> machine
> > > running Flink is far away from the remote debugger you may suffer from
> > > increased latency when debugging.
> > >
> > > Hope I've been helpful, happy hacking. :)
> > >
> > > On Mon, May 16, 2016 at 6:43 PM, Vijay Srinivasaraghavan <
> > > [hidden email]> wrote:
> > >
> > > > How do I attach remote debugger to running Flink cluster from
> IntelliJ?
> > > > Appreciate if anyone could share the steps?
> > > > RegardsVijay
> > >
> > >
> > >
> > >
> > > --
> > > BR,
> > > Stefano Baghino
> > >
> > > Software Engineer @ Radicalbit
> > >
> > >
> > >
> > >
> >
>
>
>
> --
> BR,
> Stefano Baghino
>
> Software Engineer @ Radicalbit
>
Reply | Threaded
Open this post in threaded view
|

Re: remote debugging

stefanobaghino
It's there, I've left the Eclipse paragraph empty, unfortunately I have no
experience with remote debugging using it.

On Tue, May 17, 2016 at 12:29 PM, Stephan Ewen <[hidden email]> wrote:

> Super, thanks!
>
> On Tue, May 17, 2016 at 11:32 AM, Stefano Baghino <
> [hidden email]> wrote:
>
> > +1, great idea, I should've had it myself. :)
> >
> > I'll do it today, thanks for creating the page.
> >
> > On Tue, May 17, 2016 at 11:24 AM, Stephan Ewen <[hidden email]> wrote:
> >
> > > Hey Stefano!
> > >
> > > I think that question is bound to come up again. I created a page in
> the
> > > Flink Wiki to document this.
> > >
> > > If you have a few moments, would be great if you could add your
> > description
> > > there:
> > >
> > >
> >
> https://cwiki.apache.org/confluence/display/FLINK/Remote+Debugging+of+Flink+Clusters
> > > (it is linked from the front page
> > > https://cwiki.apache.org/confluence/display/FLINK/Apache+Flink+Home )
> > >
> > > Greetings,
> > > Stephan
> > >
> > >
> > > On Tue, May 17, 2016 at 4:26 AM, Vijay Srinivasaraghavan <
> > > [hidden email]> wrote:
> > >
> > > > Awesome, thanks Stefano!!
> > > >
> > > >     On Monday, May 16, 2016 9:57 AM, Stefano Baghino <
> > > > [hidden email]> wrote:
> > > >
> > > >
> > > >  I had to do it a couple of times. Wonderful experience to understand
> > the
> > > > inner workings of Flink and explore it while running.
> > > > I don't know if there's a preferred way to do this but this is how I
> > did
> > > > it:
> > > >
> > > > Edit the run configurations in IntelliJ, click the + icon in the
> upper
> > > left
> > > > corner, choose the "Remote" preset.
> > > > Under the "Settings" pane, fill in the remote host where you'll run
> > > Flink.
> > > > Copy the "Command line arguments for running remote JVM".
> > > > Go to the machine running Flink, choose the launch script you need to
> > > > "hijack" and append the copied arguments after the "java" command.
> Make
> > > > sure to set "suspend=y" if you want to make sure Flink doesn't start
> > > > without your debugger attached.
> > > >
> > > > Now simply run Flink with the script you tampered with and run the
> > > > debugger. Please note that if you set "suspend=y" Flink won't start
> > until
> > > > the debugger is attached to the process. Also beware that if the
> > machine
> > > > running Flink is far away from the remote debugger you may suffer
> from
> > > > increased latency when debugging.
> > > >
> > > > Hope I've been helpful, happy hacking. :)
> > > >
> > > > On Mon, May 16, 2016 at 6:43 PM, Vijay Srinivasaraghavan <
> > > > [hidden email]> wrote:
> > > >
> > > > > How do I attach remote debugger to running Flink cluster from
> > IntelliJ?
> > > > > Appreciate if anyone could share the steps?
> > > > > RegardsVijay
> > > >
> > > >
> > > >
> > > >
> > > > --
> > > > BR,
> > > > Stefano Baghino
> > > >
> > > > Software Engineer @ Radicalbit
> > > >
> > > >
> > > >
> > > >
> > >
> >
> >
> >
> > --
> > BR,
> > Stefano Baghino
> >
> > Software Engineer @ Radicalbit
> >
>



--
BR,
Stefano Baghino

Software Engineer @ Radicalbit
mxm
Reply | Threaded
Open this post in threaded view
|

Re: remote debugging

mxm
Thanks for documenting, Stefano! I remember, this came in very handy
when debugging the Yarn integration and tests.

On Tue, May 17, 2016 at 12:32 PM, Stefano Baghino
<[hidden email]> wrote:

>
> It's there, I've left the Eclipse paragraph empty, unfortunately I have no
> experience with remote debugging using it.
>
> On Tue, May 17, 2016 at 12:29 PM, Stephan Ewen <[hidden email]> wrote:
>
> > Super, thanks!
> >
> > On Tue, May 17, 2016 at 11:32 AM, Stefano Baghino <
> > [hidden email]> wrote:
> >
> > > +1, great idea, I should've had it myself. :)
> > >
> > > I'll do it today, thanks for creating the page.
> > >
> > > On Tue, May 17, 2016 at 11:24 AM, Stephan Ewen <[hidden email]> wrote:
> > >
> > > > Hey Stefano!
> > > >
> > > > I think that question is bound to come up again. I created a page in
> > the
> > > > Flink Wiki to document this.
> > > >
> > > > If you have a few moments, would be great if you could add your
> > > description
> > > > there:
> > > >
> > > >
> > >
> > https://cwiki.apache.org/confluence/display/FLINK/Remote+Debugging+of+Flink+Clusters
> > > > (it is linked from the front page
> > > > https://cwiki.apache.org/confluence/display/FLINK/Apache+Flink+Home )
> > > >
> > > > Greetings,
> > > > Stephan
> > > >
> > > >
> > > > On Tue, May 17, 2016 at 4:26 AM, Vijay Srinivasaraghavan <
> > > > [hidden email]> wrote:
> > > >
> > > > > Awesome, thanks Stefano!!
> > > > >
> > > > >     On Monday, May 16, 2016 9:57 AM, Stefano Baghino <
> > > > > [hidden email]> wrote:
> > > > >
> > > > >
> > > > >  I had to do it a couple of times. Wonderful experience to understand
> > > the
> > > > > inner workings of Flink and explore it while running.
> > > > > I don't know if there's a preferred way to do this but this is how I
> > > did
> > > > > it:
> > > > >
> > > > > Edit the run configurations in IntelliJ, click the + icon in the
> > upper
> > > > left
> > > > > corner, choose the "Remote" preset.
> > > > > Under the "Settings" pane, fill in the remote host where you'll run
> > > > Flink.
> > > > > Copy the "Command line arguments for running remote JVM".
> > > > > Go to the machine running Flink, choose the launch script you need to
> > > > > "hijack" and append the copied arguments after the "java" command.
> > Make
> > > > > sure to set "suspend=y" if you want to make sure Flink doesn't start
> > > > > without your debugger attached.
> > > > >
> > > > > Now simply run Flink with the script you tampered with and run the
> > > > > debugger. Please note that if you set "suspend=y" Flink won't start
> > > until
> > > > > the debugger is attached to the process. Also beware that if the
> > > machine
> > > > > running Flink is far away from the remote debugger you may suffer
> > from
> > > > > increased latency when debugging.
> > > > >
> > > > > Hope I've been helpful, happy hacking. :)
> > > > >
> > > > > On Mon, May 16, 2016 at 6:43 PM, Vijay Srinivasaraghavan <
> > > > > [hidden email]> wrote:
> > > > >
> > > > > > How do I attach remote debugger to running Flink cluster from
> > > IntelliJ?
> > > > > > Appreciate if anyone could share the steps?
> > > > > > RegardsVijay
> > > > >
> > > > >
> > > > >
> > > > >
> > > > > --
> > > > > BR,
> > > > > Stefano Baghino
> > > > >
> > > > > Software Engineer @ Radicalbit
> > > > >
> > > > >
> > > > >
> > > > >
> > > >
> > >
> > >
> > >
> > > --
> > > BR,
> > > Stefano Baghino
> > >
> > > Software Engineer @ Radicalbit
> > >
> >
>
>
>
> --
> BR,
> Stefano Baghino
>
> Software Engineer @ Radicalbit
Reply | Threaded
Open this post in threaded view
|

Re: remote debugging

Greg Hogan
In reply to this post by Stephan Ewen
I also just modify the startup scripts but would it be better to have
variants of env.java.opts specific to the JobManager, TaskManager, client,
etc.?

On Tue, May 17, 2016 at 5:24 AM, Stephan Ewen <[hidden email]> wrote:

> Hey Stefano!
>
> I think that question is bound to come up again. I created a page in the
> Flink Wiki to document this.
>
> If you have a few moments, would be great if you could add your description
> there:
>
> https://cwiki.apache.org/confluence/display/FLINK/Remote+Debugging+of+Flink+Clusters
> (it is linked from the front page
> https://cwiki.apache.org/confluence/display/FLINK/Apache+Flink+Home )
>
> Greetings,
> Stephan
>
>
> On Tue, May 17, 2016 at 4:26 AM, Vijay Srinivasaraghavan <
> [hidden email]> wrote:
>
> > Awesome, thanks Stefano!!
> >
> >     On Monday, May 16, 2016 9:57 AM, Stefano Baghino <
> > [hidden email]> wrote:
> >
> >
> >  I had to do it a couple of times. Wonderful experience to understand the
> > inner workings of Flink and explore it while running.
> > I don't know if there's a preferred way to do this but this is how I did
> > it:
> >
> > Edit the run configurations in IntelliJ, click the + icon in the upper
> left
> > corner, choose the "Remote" preset.
> > Under the "Settings" pane, fill in the remote host where you'll run
> Flink.
> > Copy the "Command line arguments for running remote JVM".
> > Go to the machine running Flink, choose the launch script you need to
> > "hijack" and append the copied arguments after the "java" command. Make
> > sure to set "suspend=y" if you want to make sure Flink doesn't start
> > without your debugger attached.
> >
> > Now simply run Flink with the script you tampered with and run the
> > debugger. Please note that if you set "suspend=y" Flink won't start until
> > the debugger is attached to the process. Also beware that if the machine
> > running Flink is far away from the remote debugger you may suffer from
> > increased latency when debugging.
> >
> > Hope I've been helpful, happy hacking. :)
> >
> > On Mon, May 16, 2016 at 6:43 PM, Vijay Srinivasaraghavan <
> > [hidden email]> wrote:
> >
> > > How do I attach remote debugger to running Flink cluster from IntelliJ?
> > > Appreciate if anyone could share the steps?
> > > RegardsVijay
> >
> >
> >
> >
> > --
> > BR,
> > Stefano Baghino
> >
> > Software Engineer @ Radicalbit
> >
> >
> >
> >
>
Reply | Threaded
Open this post in threaded view
|

Re: remote debugging

stefanobaghino
That would be pretty neat, in fact by modifying bin/flink-daemon.sh you'd
end up having all managers listening for a remote debugger and it would be
a problem if you want the JVM to suspend on start.

On Tue, May 17, 2016 at 2:22 PM, Greg Hogan <[hidden email]> wrote:

> I also just modify the startup scripts but would it be better to have
> variants of env.java.opts specific to the JobManager, TaskManager, client,
> etc.?
>
> On Tue, May 17, 2016 at 5:24 AM, Stephan Ewen <[hidden email]> wrote:
>
> > Hey Stefano!
> >
> > I think that question is bound to come up again. I created a page in the
> > Flink Wiki to document this.
> >
> > If you have a few moments, would be great if you could add your
> description
> > there:
> >
> >
> https://cwiki.apache.org/confluence/display/FLINK/Remote+Debugging+of+Flink+Clusters
> > (it is linked from the front page
> > https://cwiki.apache.org/confluence/display/FLINK/Apache+Flink+Home )
> >
> > Greetings,
> > Stephan
> >
> >
> > On Tue, May 17, 2016 at 4:26 AM, Vijay Srinivasaraghavan <
> > [hidden email]> wrote:
> >
> > > Awesome, thanks Stefano!!
> > >
> > >     On Monday, May 16, 2016 9:57 AM, Stefano Baghino <
> > > [hidden email]> wrote:
> > >
> > >
> > >  I had to do it a couple of times. Wonderful experience to understand
> the
> > > inner workings of Flink and explore it while running.
> > > I don't know if there's a preferred way to do this but this is how I
> did
> > > it:
> > >
> > > Edit the run configurations in IntelliJ, click the + icon in the upper
> > left
> > > corner, choose the "Remote" preset.
> > > Under the "Settings" pane, fill in the remote host where you'll run
> > Flink.
> > > Copy the "Command line arguments for running remote JVM".
> > > Go to the machine running Flink, choose the launch script you need to
> > > "hijack" and append the copied arguments after the "java" command. Make
> > > sure to set "suspend=y" if you want to make sure Flink doesn't start
> > > without your debugger attached.
> > >
> > > Now simply run Flink with the script you tampered with and run the
> > > debugger. Please note that if you set "suspend=y" Flink won't start
> until
> > > the debugger is attached to the process. Also beware that if the
> machine
> > > running Flink is far away from the remote debugger you may suffer from
> > > increased latency when debugging.
> > >
> > > Hope I've been helpful, happy hacking. :)
> > >
> > > On Mon, May 16, 2016 at 6:43 PM, Vijay Srinivasaraghavan <
> > > [hidden email]> wrote:
> > >
> > > > How do I attach remote debugger to running Flink cluster from
> IntelliJ?
> > > > Appreciate if anyone could share the steps?
> > > > RegardsVijay
> > >
> > >
> > >
> > >
> > > --
> > > BR,
> > > Stefano Baghino
> > >
> > > Software Engineer @ Radicalbit
> > >
> > >
> > >
> > >
> >
>



--
BR,
Stefano Baghino

Software Engineer @ Radicalbit
Reply | Threaded
Open this post in threaded view
|

Re: remote debugging

Flavio Pompermaier
In reply to this post by Stephan Ewen
Hi to all,

for debugging Flink from Eclipse this is what you have to do:

   1. go to 'Run' -> 'Debug configurations...'
   2. Create a new 'Remote Java Application'
   3. In the 'Connect' tab choose:
      1. the project to debug
      2. Connection type 'Standard (Socket Attach)'
      3. Connection properties *target.host.name-or-ip*/*5005* (change
*target.host.name-or-ip
      properly...)*
      4. (Optional) If you see the error 'Multiple launchers available'
      because you have bot Eclipse and scala debuggers click on Select one and
      select the right one (e.g. Eclipse JDT Launcher)

Unofrtunately remote debugging is not possible with Flink UDF (or at least
I didn't manage to debug it from Eclipse).

Best,
Flavio

On Tue, May 17, 2016 at 11:24 AM, Stephan Ewen <[hidden email]> wrote:

> Hey Stefano!
>
> I think that question is bound to come up again. I created a page in the
> Flink Wiki to document this.
>
> If you have a few moments, would be great if you could add your description
> there:
>
> https://cwiki.apache.org/confluence/display/FLINK/Remote+Debugging+of+Flink+Clusters
> (it is linked from the front page
> https://cwiki.apache.org/confluence/display/FLINK/Apache+Flink+Home )
>
> Greetings,
> Stephan
>
>
> On Tue, May 17, 2016 at 4:26 AM, Vijay Srinivasaraghavan <
> [hidden email]> wrote:
>
> > Awesome, thanks Stefano!!
> >
> >     On Monday, May 16, 2016 9:57 AM, Stefano Baghino <
> > [hidden email]> wrote:
> >
> >
> >  I had to do it a couple of times. Wonderful experience to understand the
> > inner workings of Flink and explore it while running.
> > I don't know if there's a preferred way to do this but this is how I did
> > it:
> >
> > Edit the run configurations in IntelliJ, click the + icon in the upper
> left
> > corner, choose the "Remote" preset.
> > Under the "Settings" pane, fill in the remote host where you'll run
> Flink.
> > Copy the "Command line arguments for running remote JVM".
> > Go to the machine running Flink, choose the launch script you need to
> > "hijack" and append the copied arguments after the "java" command. Make
> > sure to set "suspend=y" if you want to make sure Flink doesn't start
> > without your debugger attached.
> >
> > Now simply run Flink with the script you tampered with and run the
> > debugger. Please note that if you set "suspend=y" Flink won't start until
> > the debugger is attached to the process. Also beware that if the machine
> > running Flink is far away from the remote debugger you may suffer from
> > increased latency when debugging.
> >
> > Hope I've been helpful, happy hacking. :)
> >
> > On Mon, May 16, 2016 at 6:43 PM, Vijay Srinivasaraghavan <
> > [hidden email]> wrote:
> >
> > > How do I attach remote debugger to running Flink cluster from IntelliJ?
> > > Appreciate if anyone could share the steps?
> > > RegardsVijay
> >
> >
> >
> >
> > --
> > BR,
> > Stefano Baghino
> >
> > Software Engineer @ Radicalbit
> >
> >
> >
> >
>
Reply | Threaded
Open this post in threaded view
|

Re: remote debugging

stefanobaghino
Thanks Flavio,

perhaps it would be a nice addition to the Wiki page, would you care to
contribute your suggestion? :)

On Tue, May 17, 2016 at 3:22 PM, Flavio Pompermaier <[hidden email]>
wrote:

> Hi to all,
>
> for debugging Flink from Eclipse this is what you have to do:
>
>    1. go to 'Run' -> 'Debug configurations...'
>    2. Create a new 'Remote Java Application'
>    3. In the 'Connect' tab choose:
>       1. the project to debug
>       2. Connection type 'Standard (Socket Attach)'
>       3. Connection properties *target.host.name-or-ip*/*5005* (change
> *target.host.name-or-ip
>       properly...)*
>       4. (Optional) If you see the error 'Multiple launchers available'
>       because you have bot Eclipse and scala debuggers click on Select one
> and
>       select the right one (e.g. Eclipse JDT Launcher)
>
> Unofrtunately remote debugging is not possible with Flink UDF (or at least
> I didn't manage to debug it from Eclipse).
>
> Best,
> Flavio
>
> On Tue, May 17, 2016 at 11:24 AM, Stephan Ewen <[hidden email]> wrote:
>
> > Hey Stefano!
> >
> > I think that question is bound to come up again. I created a page in the
> > Flink Wiki to document this.
> >
> > If you have a few moments, would be great if you could add your
> description
> > there:
> >
> >
> https://cwiki.apache.org/confluence/display/FLINK/Remote+Debugging+of+Flink+Clusters
> > (it is linked from the front page
> > https://cwiki.apache.org/confluence/display/FLINK/Apache+Flink+Home )
> >
> > Greetings,
> > Stephan
> >
> >
> > On Tue, May 17, 2016 at 4:26 AM, Vijay Srinivasaraghavan <
> > [hidden email]> wrote:
> >
> > > Awesome, thanks Stefano!!
> > >
> > >     On Monday, May 16, 2016 9:57 AM, Stefano Baghino <
> > > [hidden email]> wrote:
> > >
> > >
> > >  I had to do it a couple of times. Wonderful experience to understand
> the
> > > inner workings of Flink and explore it while running.
> > > I don't know if there's a preferred way to do this but this is how I
> did
> > > it:
> > >
> > > Edit the run configurations in IntelliJ, click the + icon in the upper
> > left
> > > corner, choose the "Remote" preset.
> > > Under the "Settings" pane, fill in the remote host where you'll run
> > Flink.
> > > Copy the "Command line arguments for running remote JVM".
> > > Go to the machine running Flink, choose the launch script you need to
> > > "hijack" and append the copied arguments after the "java" command. Make
> > > sure to set "suspend=y" if you want to make sure Flink doesn't start
> > > without your debugger attached.
> > >
> > > Now simply run Flink with the script you tampered with and run the
> > > debugger. Please note that if you set "suspend=y" Flink won't start
> until
> > > the debugger is attached to the process. Also beware that if the
> machine
> > > running Flink is far away from the remote debugger you may suffer from
> > > increased latency when debugging.
> > >
> > > Hope I've been helpful, happy hacking. :)
> > >
> > > On Mon, May 16, 2016 at 6:43 PM, Vijay Srinivasaraghavan <
> > > [hidden email]> wrote:
> > >
> > > > How do I attach remote debugger to running Flink cluster from
> IntelliJ?
> > > > Appreciate if anyone could share the steps?
> > > > RegardsVijay
> > >
> > >
> > >
> > >
> > > --
> > > BR,
> > > Stefano Baghino
> > >
> > > Software Engineer @ Radicalbit
> > >
> > >
> > >
> > >
> >
>



--
BR,
Stefano Baghino

Software Engineer @ Radicalbit
Reply | Threaded
Open this post in threaded view
|

Re: remote debugging

Flavio Pompermaier
No I can't edit that page :(

On Tue, May 17, 2016 at 3:46 PM, Stefano Baghino <
[hidden email]> wrote:

> Thanks Flavio,
>
> perhaps it would be a nice addition to the Wiki page, would you care to
> contribute your suggestion? :)
>
> On Tue, May 17, 2016 at 3:22 PM, Flavio Pompermaier <[hidden email]>
> wrote:
>
> > Hi to all,
> >
> > for debugging Flink from Eclipse this is what you have to do:
> >
> >    1. go to 'Run' -> 'Debug configurations...'
> >    2. Create a new 'Remote Java Application'
> >    3. In the 'Connect' tab choose:
> >       1. the project to debug
> >       2. Connection type 'Standard (Socket Attach)'
> >       3. Connection properties *target.host.name-or-ip*/*5005* (change
> > *target.host.name-or-ip
> >       properly...)*
> >       4. (Optional) If you see the error 'Multiple launchers available'
> >       because you have bot Eclipse and scala debuggers click on Select
> one
> > and
> >       select the right one (e.g. Eclipse JDT Launcher)
> >
> > Unofrtunately remote debugging is not possible with Flink UDF (or at
> least
> > I didn't manage to debug it from Eclipse).
> >
> > Best,
> > Flavio
> >
> > On Tue, May 17, 2016 at 11:24 AM, Stephan Ewen <[hidden email]> wrote:
> >
> > > Hey Stefano!
> > >
> > > I think that question is bound to come up again. I created a page in
> the
> > > Flink Wiki to document this.
> > >
> > > If you have a few moments, would be great if you could add your
> > description
> > > there:
> > >
> > >
> >
> https://cwiki.apache.org/confluence/display/FLINK/Remote+Debugging+of+Flink+Clusters
> > > (it is linked from the front page
> > > https://cwiki.apache.org/confluence/display/FLINK/Apache+Flink+Home )
> > >
> > > Greetings,
> > > Stephan
> > >
> > >
> > > On Tue, May 17, 2016 at 4:26 AM, Vijay Srinivasaraghavan <
> > > [hidden email]> wrote:
> > >
> > > > Awesome, thanks Stefano!!
> > > >
> > > >     On Monday, May 16, 2016 9:57 AM, Stefano Baghino <
> > > > [hidden email]> wrote:
> > > >
> > > >
> > > >  I had to do it a couple of times. Wonderful experience to understand
> > the
> > > > inner workings of Flink and explore it while running.
> > > > I don't know if there's a preferred way to do this but this is how I
> > did
> > > > it:
> > > >
> > > > Edit the run configurations in IntelliJ, click the + icon in the
> upper
> > > left
> > > > corner, choose the "Remote" preset.
> > > > Under the "Settings" pane, fill in the remote host where you'll run
> > > Flink.
> > > > Copy the "Command line arguments for running remote JVM".
> > > > Go to the machine running Flink, choose the launch script you need to
> > > > "hijack" and append the copied arguments after the "java" command.
> Make
> > > > sure to set "suspend=y" if you want to make sure Flink doesn't start
> > > > without your debugger attached.
> > > >
> > > > Now simply run Flink with the script you tampered with and run the
> > > > debugger. Please note that if you set "suspend=y" Flink won't start
> > until
> > > > the debugger is attached to the process. Also beware that if the
> > machine
> > > > running Flink is far away from the remote debugger you may suffer
> from
> > > > increased latency when debugging.
> > > >
> > > > Hope I've been helpful, happy hacking. :)
> > > >
> > > > On Mon, May 16, 2016 at 6:43 PM, Vijay Srinivasaraghavan <
> > > > [hidden email]> wrote:
> > > >
> > > > > How do I attach remote debugger to running Flink cluster from
> > IntelliJ?
> > > > > Appreciate if anyone could share the steps?
> > > > > RegardsVijay
> > > >
> > > >
> > > >
> > > >
> > > > --
> > > > BR,
> > > > Stefano Baghino
> > > >
> > > > Software Engineer @ Radicalbit
> > > >
> > > >
> > > >
> > > >
> > >
> >
>
>
>
> --
> BR,
> Stefano Baghino
>
> Software Engineer @ Radicalbit
>
Reply | Threaded
Open this post in threaded view
|

Re: remote debugging

Robert Metzger
Can you give me your wiki user id, then I can give you permissions.

On Tue, May 17, 2016 at 3:56 PM, Flavio Pompermaier <[hidden email]>
wrote:

> No I can't edit that page :(
>
> On Tue, May 17, 2016 at 3:46 PM, Stefano Baghino <
> [hidden email]> wrote:
>
> > Thanks Flavio,
> >
> > perhaps it would be a nice addition to the Wiki page, would you care to
> > contribute your suggestion? :)
> >
> > On Tue, May 17, 2016 at 3:22 PM, Flavio Pompermaier <
> [hidden email]>
> > wrote:
> >
> > > Hi to all,
> > >
> > > for debugging Flink from Eclipse this is what you have to do:
> > >
> > >    1. go to 'Run' -> 'Debug configurations...'
> > >    2. Create a new 'Remote Java Application'
> > >    3. In the 'Connect' tab choose:
> > >       1. the project to debug
> > >       2. Connection type 'Standard (Socket Attach)'
> > >       3. Connection properties *target.host.name-or-ip*/*5005* (change
> > > *target.host.name-or-ip
> > >       properly...)*
> > >       4. (Optional) If you see the error 'Multiple launchers available'
> > >       because you have bot Eclipse and scala debuggers click on Select
> > one
> > > and
> > >       select the right one (e.g. Eclipse JDT Launcher)
> > >
> > > Unofrtunately remote debugging is not possible with Flink UDF (or at
> > least
> > > I didn't manage to debug it from Eclipse).
> > >
> > > Best,
> > > Flavio
> > >
> > > On Tue, May 17, 2016 at 11:24 AM, Stephan Ewen <[hidden email]>
> wrote:
> > >
> > > > Hey Stefano!
> > > >
> > > > I think that question is bound to come up again. I created a page in
> > the
> > > > Flink Wiki to document this.
> > > >
> > > > If you have a few moments, would be great if you could add your
> > > description
> > > > there:
> > > >
> > > >
> > >
> >
> https://cwiki.apache.org/confluence/display/FLINK/Remote+Debugging+of+Flink+Clusters
> > > > (it is linked from the front page
> > > > https://cwiki.apache.org/confluence/display/FLINK/Apache+Flink+Home
> )
> > > >
> > > > Greetings,
> > > > Stephan
> > > >
> > > >
> > > > On Tue, May 17, 2016 at 4:26 AM, Vijay Srinivasaraghavan <
> > > > [hidden email]> wrote:
> > > >
> > > > > Awesome, thanks Stefano!!
> > > > >
> > > > >     On Monday, May 16, 2016 9:57 AM, Stefano Baghino <
> > > > > [hidden email]> wrote:
> > > > >
> > > > >
> > > > >  I had to do it a couple of times. Wonderful experience to
> understand
> > > the
> > > > > inner workings of Flink and explore it while running.
> > > > > I don't know if there's a preferred way to do this but this is how
> I
> > > did
> > > > > it:
> > > > >
> > > > > Edit the run configurations in IntelliJ, click the + icon in the
> > upper
> > > > left
> > > > > corner, choose the "Remote" preset.
> > > > > Under the "Settings" pane, fill in the remote host where you'll run
> > > > Flink.
> > > > > Copy the "Command line arguments for running remote JVM".
> > > > > Go to the machine running Flink, choose the launch script you need
> to
> > > > > "hijack" and append the copied arguments after the "java" command.
> > Make
> > > > > sure to set "suspend=y" if you want to make sure Flink doesn't
> start
> > > > > without your debugger attached.
> > > > >
> > > > > Now simply run Flink with the script you tampered with and run the
> > > > > debugger. Please note that if you set "suspend=y" Flink won't start
> > > until
> > > > > the debugger is attached to the process. Also beware that if the
> > > machine
> > > > > running Flink is far away from the remote debugger you may suffer
> > from
> > > > > increased latency when debugging.
> > > > >
> > > > > Hope I've been helpful, happy hacking. :)
> > > > >
> > > > > On Mon, May 16, 2016 at 6:43 PM, Vijay Srinivasaraghavan <
> > > > > [hidden email]> wrote:
> > > > >
> > > > > > How do I attach remote debugger to running Flink cluster from
> > > IntelliJ?
> > > > > > Appreciate if anyone could share the steps?
> > > > > > RegardsVijay
> > > > >
> > > > >
> > > > >
> > > > >
> > > > > --
> > > > > BR,
> > > > > Stefano Baghino
> > > > >
> > > > > Software Engineer @ Radicalbit
> > > > >
> > > > >
> > > > >
> > > > >
> > > >
> > >
> >
> >
> >
> > --
> > BR,
> > Stefano Baghino
> >
> > Software Engineer @ Radicalbit
> >
>
Reply | Threaded
Open this post in threaded view
|

Re: remote debugging

Flavio Pompermaier
I've just signed up as f.pompermaier

Thanks!

On Tue, May 17, 2016 at 5:04 PM, Robert Metzger <[hidden email]> wrote:

> Can you give me your wiki user id, then I can give you permissions.
>
> On Tue, May 17, 2016 at 3:56 PM, Flavio Pompermaier <[hidden email]>
> wrote:
>
> > No I can't edit that page :(
> >
> > On Tue, May 17, 2016 at 3:46 PM, Stefano Baghino <
> > [hidden email]> wrote:
> >
> > > Thanks Flavio,
> > >
> > > perhaps it would be a nice addition to the Wiki page, would you care to
> > > contribute your suggestion? :)
> > >
> > > On Tue, May 17, 2016 at 3:22 PM, Flavio Pompermaier <
> > [hidden email]>
> > > wrote:
> > >
> > > > Hi to all,
> > > >
> > > > for debugging Flink from Eclipse this is what you have to do:
> > > >
> > > >    1. go to 'Run' -> 'Debug configurations...'
> > > >    2. Create a new 'Remote Java Application'
> > > >    3. In the 'Connect' tab choose:
> > > >       1. the project to debug
> > > >       2. Connection type 'Standard (Socket Attach)'
> > > >       3. Connection properties *target.host.name-or-ip*/*5005*
> (change
> > > > *target.host.name-or-ip
> > > >       properly...)*
> > > >       4. (Optional) If you see the error 'Multiple launchers
> available'
> > > >       because you have bot Eclipse and scala debuggers click on
> Select
> > > one
> > > > and
> > > >       select the right one (e.g. Eclipse JDT Launcher)
> > > >
> > > > Unofrtunately remote debugging is not possible with Flink UDF (or at
> > > least
> > > > I didn't manage to debug it from Eclipse).
> > > >
> > > > Best,
> > > > Flavio
> > > >
> > > > On Tue, May 17, 2016 at 11:24 AM, Stephan Ewen <[hidden email]>
> > wrote:
> > > >
> > > > > Hey Stefano!
> > > > >
> > > > > I think that question is bound to come up again. I created a page
> in
> > > the
> > > > > Flink Wiki to document this.
> > > > >
> > > > > If you have a few moments, would be great if you could add your
> > > > description
> > > > > there:
> > > > >
> > > > >
> > > >
> > >
> >
> https://cwiki.apache.org/confluence/display/FLINK/Remote+Debugging+of+Flink+Clusters
> > > > > (it is linked from the front page
> > > > >
> https://cwiki.apache.org/confluence/display/FLINK/Apache+Flink+Home
> > )
> > > > >
> > > > > Greetings,
> > > > > Stephan
> > > > >
> > > > >
> > > > > On Tue, May 17, 2016 at 4:26 AM, Vijay Srinivasaraghavan <
> > > > > [hidden email]> wrote:
> > > > >
> > > > > > Awesome, thanks Stefano!!
> > > > > >
> > > > > >     On Monday, May 16, 2016 9:57 AM, Stefano Baghino <
> > > > > > [hidden email]> wrote:
> > > > > >
> > > > > >
> > > > > >  I had to do it a couple of times. Wonderful experience to
> > understand
> > > > the
> > > > > > inner workings of Flink and explore it while running.
> > > > > > I don't know if there's a preferred way to do this but this is
> how
> > I
> > > > did
> > > > > > it:
> > > > > >
> > > > > > Edit the run configurations in IntelliJ, click the + icon in the
> > > upper
> > > > > left
> > > > > > corner, choose the "Remote" preset.
> > > > > > Under the "Settings" pane, fill in the remote host where you'll
> run
> > > > > Flink.
> > > > > > Copy the "Command line arguments for running remote JVM".
> > > > > > Go to the machine running Flink, choose the launch script you
> need
> > to
> > > > > > "hijack" and append the copied arguments after the "java"
> command.
> > > Make
> > > > > > sure to set "suspend=y" if you want to make sure Flink doesn't
> > start
> > > > > > without your debugger attached.
> > > > > >
> > > > > > Now simply run Flink with the script you tampered with and run
> the
> > > > > > debugger. Please note that if you set "suspend=y" Flink won't
> start
> > > > until
> > > > > > the debugger is attached to the process. Also beware that if the
> > > > machine
> > > > > > running Flink is far away from the remote debugger you may suffer
> > > from
> > > > > > increased latency when debugging.
> > > > > >
> > > > > > Hope I've been helpful, happy hacking. :)
> > > > > >
> > > > > > On Mon, May 16, 2016 at 6:43 PM, Vijay Srinivasaraghavan <
> > > > > > [hidden email]> wrote:
> > > > > >
> > > > > > > How do I attach remote debugger to running Flink cluster from
> > > > IntelliJ?
> > > > > > > Appreciate if anyone could share the steps?
> > > > > > > RegardsVijay
> > > > > >
> > > > > >
> > > > > >
> > > > > >
> > > > > > --
> > > > > > BR,
> > > > > > Stefano Baghino
> > > > > >
> > > > > > Software Engineer @ Radicalbit
> > > > > >
> > > > > >
> > > > > >
> > > > > >
> > > > >
> > > >
> > >
> > >
> > >
> > > --
> > > BR,
> > > Stefano Baghino
> > >
> > > Software Engineer @ Radicalbit
> > >
> >
>
Reply | Threaded
Open this post in threaded view
|

Re: remote debugging

Robert Metzger
Okay, I gave you permissions.

On Tue, May 17, 2016 at 5:22 PM, Flavio Pompermaier <[hidden email]>
wrote:

> I've just signed up as f.pompermaier
>
> Thanks!
>
> On Tue, May 17, 2016 at 5:04 PM, Robert Metzger <[hidden email]>
> wrote:
>
> > Can you give me your wiki user id, then I can give you permissions.
> >
> > On Tue, May 17, 2016 at 3:56 PM, Flavio Pompermaier <
> [hidden email]>
> > wrote:
> >
> > > No I can't edit that page :(
> > >
> > > On Tue, May 17, 2016 at 3:46 PM, Stefano Baghino <
> > > [hidden email]> wrote:
> > >
> > > > Thanks Flavio,
> > > >
> > > > perhaps it would be a nice addition to the Wiki page, would you care
> to
> > > > contribute your suggestion? :)
> > > >
> > > > On Tue, May 17, 2016 at 3:22 PM, Flavio Pompermaier <
> > > [hidden email]>
> > > > wrote:
> > > >
> > > > > Hi to all,
> > > > >
> > > > > for debugging Flink from Eclipse this is what you have to do:
> > > > >
> > > > >    1. go to 'Run' -> 'Debug configurations...'
> > > > >    2. Create a new 'Remote Java Application'
> > > > >    3. In the 'Connect' tab choose:
> > > > >       1. the project to debug
> > > > >       2. Connection type 'Standard (Socket Attach)'
> > > > >       3. Connection properties *target.host.name-or-ip*/*5005*
> > (change
> > > > > *target.host.name-or-ip
> > > > >       properly...)*
> > > > >       4. (Optional) If you see the error 'Multiple launchers
> > available'
> > > > >       because you have bot Eclipse and scala debuggers click on
> > Select
> > > > one
> > > > > and
> > > > >       select the right one (e.g. Eclipse JDT Launcher)
> > > > >
> > > > > Unofrtunately remote debugging is not possible with Flink UDF (or
> at
> > > > least
> > > > > I didn't manage to debug it from Eclipse).
> > > > >
> > > > > Best,
> > > > > Flavio
> > > > >
> > > > > On Tue, May 17, 2016 at 11:24 AM, Stephan Ewen <[hidden email]>
> > > wrote:
> > > > >
> > > > > > Hey Stefano!
> > > > > >
> > > > > > I think that question is bound to come up again. I created a page
> > in
> > > > the
> > > > > > Flink Wiki to document this.
> > > > > >
> > > > > > If you have a few moments, would be great if you could add your
> > > > > description
> > > > > > there:
> > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
> https://cwiki.apache.org/confluence/display/FLINK/Remote+Debugging+of+Flink+Clusters
> > > > > > (it is linked from the front page
> > > > > >
> > https://cwiki.apache.org/confluence/display/FLINK/Apache+Flink+Home
> > > )
> > > > > >
> > > > > > Greetings,
> > > > > > Stephan
> > > > > >
> > > > > >
> > > > > > On Tue, May 17, 2016 at 4:26 AM, Vijay Srinivasaraghavan <
> > > > > > [hidden email]> wrote:
> > > > > >
> > > > > > > Awesome, thanks Stefano!!
> > > > > > >
> > > > > > >     On Monday, May 16, 2016 9:57 AM, Stefano Baghino <
> > > > > > > [hidden email]> wrote:
> > > > > > >
> > > > > > >
> > > > > > >  I had to do it a couple of times. Wonderful experience to
> > > understand
> > > > > the
> > > > > > > inner workings of Flink and explore it while running.
> > > > > > > I don't know if there's a preferred way to do this but this is
> > how
> > > I
> > > > > did
> > > > > > > it:
> > > > > > >
> > > > > > > Edit the run configurations in IntelliJ, click the + icon in
> the
> > > > upper
> > > > > > left
> > > > > > > corner, choose the "Remote" preset.
> > > > > > > Under the "Settings" pane, fill in the remote host where you'll
> > run
> > > > > > Flink.
> > > > > > > Copy the "Command line arguments for running remote JVM".
> > > > > > > Go to the machine running Flink, choose the launch script you
> > need
> > > to
> > > > > > > "hijack" and append the copied arguments after the "java"
> > command.
> > > > Make
> > > > > > > sure to set "suspend=y" if you want to make sure Flink doesn't
> > > start
> > > > > > > without your debugger attached.
> > > > > > >
> > > > > > > Now simply run Flink with the script you tampered with and run
> > the
> > > > > > > debugger. Please note that if you set "suspend=y" Flink won't
> > start
> > > > > until
> > > > > > > the debugger is attached to the process. Also beware that if
> the
> > > > > machine
> > > > > > > running Flink is far away from the remote debugger you may
> suffer
> > > > from
> > > > > > > increased latency when debugging.
> > > > > > >
> > > > > > > Hope I've been helpful, happy hacking. :)
> > > > > > >
> > > > > > > On Mon, May 16, 2016 at 6:43 PM, Vijay Srinivasaraghavan <
> > > > > > > [hidden email]> wrote:
> > > > > > >
> > > > > > > > How do I attach remote debugger to running Flink cluster from
> > > > > IntelliJ?
> > > > > > > > Appreciate if anyone could share the steps?
> > > > > > > > RegardsVijay
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > > --
> > > > > > > BR,
> > > > > > > Stefano Baghino
> > > > > > >
> > > > > > > Software Engineer @ Radicalbit
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > > >
> > > >
> > > > --
> > > > BR,
> > > > Stefano Baghino
> > > >
> > > > Software Engineer @ Radicalbit
> > > >
> > >
> >
>
Reply | Threaded
Open this post in threaded view
|

Re: remote debugging

Flavio Pompermaier
Done ;)

On Tue, May 17, 2016 at 5:37 PM, Robert Metzger <[hidden email]> wrote:

> Okay, I gave you permissions.
>
> On Tue, May 17, 2016 at 5:22 PM, Flavio Pompermaier <[hidden email]>
> wrote:
>
> > I've just signed up as f.pompermaier
> >
> > Thanks!
> >
> > On Tue, May 17, 2016 at 5:04 PM, Robert Metzger <[hidden email]>
> > wrote:
> >
> > > Can you give me your wiki user id, then I can give you permissions.
> > >
> > > On Tue, May 17, 2016 at 3:56 PM, Flavio Pompermaier <
> > [hidden email]>
> > > wrote:
> > >
> > > > No I can't edit that page :(
> > > >
> > > > On Tue, May 17, 2016 at 3:46 PM, Stefano Baghino <
> > > > [hidden email]> wrote:
> > > >
> > > > > Thanks Flavio,
> > > > >
> > > > > perhaps it would be a nice addition to the Wiki page, would you
> care
> > to
> > > > > contribute your suggestion? :)
> > > > >
> > > > > On Tue, May 17, 2016 at 3:22 PM, Flavio Pompermaier <
> > > > [hidden email]>
> > > > > wrote:
> > > > >
> > > > > > Hi to all,
> > > > > >
> > > > > > for debugging Flink from Eclipse this is what you have to do:
> > > > > >
> > > > > >    1. go to 'Run' -> 'Debug configurations...'
> > > > > >    2. Create a new 'Remote Java Application'
> > > > > >    3. In the 'Connect' tab choose:
> > > > > >       1. the project to debug
> > > > > >       2. Connection type 'Standard (Socket Attach)'
> > > > > >       3. Connection properties *target.host.name-or-ip*/*5005*
> > > (change
> > > > > > *target.host.name-or-ip
> > > > > >       properly...)*
> > > > > >       4. (Optional) If you see the error 'Multiple launchers
> > > available'
> > > > > >       because you have bot Eclipse and scala debuggers click on
> > > Select
> > > > > one
> > > > > > and
> > > > > >       select the right one (e.g. Eclipse JDT Launcher)
> > > > > >
> > > > > > Unofrtunately remote debugging is not possible with Flink UDF (or
> > at
> > > > > least
> > > > > > I didn't manage to debug it from Eclipse).
> > > > > >
> > > > > > Best,
> > > > > > Flavio
> > > > > >
> > > > > > On Tue, May 17, 2016 at 11:24 AM, Stephan Ewen <[hidden email]
> >
> > > > wrote:
> > > > > >
> > > > > > > Hey Stefano!
> > > > > > >
> > > > > > > I think that question is bound to come up again. I created a
> page
> > > in
> > > > > the
> > > > > > > Flink Wiki to document this.
> > > > > > >
> > > > > > > If you have a few moments, would be great if you could add your
> > > > > > description
> > > > > > > there:
> > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
> https://cwiki.apache.org/confluence/display/FLINK/Remote+Debugging+of+Flink+Clusters
> > > > > > > (it is linked from the front page
> > > > > > >
> > > https://cwiki.apache.org/confluence/display/FLINK/Apache+Flink+Home
> > > > )
> > > > > > >
> > > > > > > Greetings,
> > > > > > > Stephan
> > > > > > >
> > > > > > >
> > > > > > > On Tue, May 17, 2016 at 4:26 AM, Vijay Srinivasaraghavan <
> > > > > > > [hidden email]> wrote:
> > > > > > >
> > > > > > > > Awesome, thanks Stefano!!
> > > > > > > >
> > > > > > > >     On Monday, May 16, 2016 9:57 AM, Stefano Baghino <
> > > > > > > > [hidden email]> wrote:
> > > > > > > >
> > > > > > > >
> > > > > > > >  I had to do it a couple of times. Wonderful experience to
> > > > understand
> > > > > > the
> > > > > > > > inner workings of Flink and explore it while running.
> > > > > > > > I don't know if there's a preferred way to do this but this
> is
> > > how
> > > > I
> > > > > > did
> > > > > > > > it:
> > > > > > > >
> > > > > > > > Edit the run configurations in IntelliJ, click the + icon in
> > the
> > > > > upper
> > > > > > > left
> > > > > > > > corner, choose the "Remote" preset.
> > > > > > > > Under the "Settings" pane, fill in the remote host where
> you'll
> > > run
> > > > > > > Flink.
> > > > > > > > Copy the "Command line arguments for running remote JVM".
> > > > > > > > Go to the machine running Flink, choose the launch script you
> > > need
> > > > to
> > > > > > > > "hijack" and append the copied arguments after the "java"
> > > command.
> > > > > Make
> > > > > > > > sure to set "suspend=y" if you want to make sure Flink
> doesn't
> > > > start
> > > > > > > > without your debugger attached.
> > > > > > > >
> > > > > > > > Now simply run Flink with the script you tampered with and
> run
> > > the
> > > > > > > > debugger. Please note that if you set "suspend=y" Flink won't
> > > start
> > > > > > until
> > > > > > > > the debugger is attached to the process. Also beware that if
> > the
> > > > > > machine
> > > > > > > > running Flink is far away from the remote debugger you may
> > suffer
> > > > > from
> > > > > > > > increased latency when debugging.
> > > > > > > >
> > > > > > > > Hope I've been helpful, happy hacking. :)
> > > > > > > >
> > > > > > > > On Mon, May 16, 2016 at 6:43 PM, Vijay Srinivasaraghavan <
> > > > > > > > [hidden email]> wrote:
> > > > > > > >
> > > > > > > > > How do I attach remote debugger to running Flink cluster
> from
> > > > > > IntelliJ?
> > > > > > > > > Appreciate if anyone could share the steps?
> > > > > > > > > RegardsVijay
> > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > > > --
> > > > > > > > BR,
> > > > > > > > Stefano Baghino
> > > > > > > >
> > > > > > > > Software Engineer @ Radicalbit
> > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > > >
> > > > >
> > > > > --
> > > > > BR,
> > > > > Stefano Baghino
> > > > >
> > > > > Software Engineer @ Radicalbit
> > > > >
> > > >
> > >
> >
>
Reply | Threaded
Open this post in threaded view
|

Re: remote debugging

till.rohrmann
Thanks Flavio for adding the Eclipse section for remote debugging :-)

On Tue, May 17, 2016 at 5:55 PM, Flavio Pompermaier <[hidden email]>
wrote:

> Done ;)
>
> On Tue, May 17, 2016 at 5:37 PM, Robert Metzger <[hidden email]>
> wrote:
>
> > Okay, I gave you permissions.
> >
> > On Tue, May 17, 2016 at 5:22 PM, Flavio Pompermaier <
> [hidden email]>
> > wrote:
> >
> > > I've just signed up as f.pompermaier
> > >
> > > Thanks!
> > >
> > > On Tue, May 17, 2016 at 5:04 PM, Robert Metzger <[hidden email]>
> > > wrote:
> > >
> > > > Can you give me your wiki user id, then I can give you permissions.
> > > >
> > > > On Tue, May 17, 2016 at 3:56 PM, Flavio Pompermaier <
> > > [hidden email]>
> > > > wrote:
> > > >
> > > > > No I can't edit that page :(
> > > > >
> > > > > On Tue, May 17, 2016 at 3:46 PM, Stefano Baghino <
> > > > > [hidden email]> wrote:
> > > > >
> > > > > > Thanks Flavio,
> > > > > >
> > > > > > perhaps it would be a nice addition to the Wiki page, would you
> > care
> > > to
> > > > > > contribute your suggestion? :)
> > > > > >
> > > > > > On Tue, May 17, 2016 at 3:22 PM, Flavio Pompermaier <
> > > > > [hidden email]>
> > > > > > wrote:
> > > > > >
> > > > > > > Hi to all,
> > > > > > >
> > > > > > > for debugging Flink from Eclipse this is what you have to do:
> > > > > > >
> > > > > > >    1. go to 'Run' -> 'Debug configurations...'
> > > > > > >    2. Create a new 'Remote Java Application'
> > > > > > >    3. In the 'Connect' tab choose:
> > > > > > >       1. the project to debug
> > > > > > >       2. Connection type 'Standard (Socket Attach)'
> > > > > > >       3. Connection properties *target.host.name-or-ip*/*5005*
> > > > (change
> > > > > > > *target.host.name-or-ip
> > > > > > >       properly...)*
> > > > > > >       4. (Optional) If you see the error 'Multiple launchers
> > > > available'
> > > > > > >       because you have bot Eclipse and scala debuggers click on
> > > > Select
> > > > > > one
> > > > > > > and
> > > > > > >       select the right one (e.g. Eclipse JDT Launcher)
> > > > > > >
> > > > > > > Unofrtunately remote debugging is not possible with Flink UDF
> (or
> > > at
> > > > > > least
> > > > > > > I didn't manage to debug it from Eclipse).
> > > > > > >
> > > > > > > Best,
> > > > > > > Flavio
> > > > > > >
> > > > > > > On Tue, May 17, 2016 at 11:24 AM, Stephan Ewen <
> [hidden email]
> > >
> > > > > wrote:
> > > > > > >
> > > > > > > > Hey Stefano!
> > > > > > > >
> > > > > > > > I think that question is bound to come up again. I created a
> > page
> > > > in
> > > > > > the
> > > > > > > > Flink Wiki to document this.
> > > > > > > >
> > > > > > > > If you have a few moments, would be great if you could add
> your
> > > > > > > description
> > > > > > > > there:
> > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
> https://cwiki.apache.org/confluence/display/FLINK/Remote+Debugging+of+Flink+Clusters
> > > > > > > > (it is linked from the front page
> > > > > > > >
> > > > https://cwiki.apache.org/confluence/display/FLINK/Apache+Flink+Home
> > > > > )
> > > > > > > >
> > > > > > > > Greetings,
> > > > > > > > Stephan
> > > > > > > >
> > > > > > > >
> > > > > > > > On Tue, May 17, 2016 at 4:26 AM, Vijay Srinivasaraghavan <
> > > > > > > > [hidden email]> wrote:
> > > > > > > >
> > > > > > > > > Awesome, thanks Stefano!!
> > > > > > > > >
> > > > > > > > >     On Monday, May 16, 2016 9:57 AM, Stefano Baghino <
> > > > > > > > > [hidden email]> wrote:
> > > > > > > > >
> > > > > > > > >
> > > > > > > > >  I had to do it a couple of times. Wonderful experience to
> > > > > understand
> > > > > > > the
> > > > > > > > > inner workings of Flink and explore it while running.
> > > > > > > > > I don't know if there's a preferred way to do this but this
> > is
> > > > how
> > > > > I
> > > > > > > did
> > > > > > > > > it:
> > > > > > > > >
> > > > > > > > > Edit the run configurations in IntelliJ, click the + icon
> in
> > > the
> > > > > > upper
> > > > > > > > left
> > > > > > > > > corner, choose the "Remote" preset.
> > > > > > > > > Under the "Settings" pane, fill in the remote host where
> > you'll
> > > > run
> > > > > > > > Flink.
> > > > > > > > > Copy the "Command line arguments for running remote JVM".
> > > > > > > > > Go to the machine running Flink, choose the launch script
> you
> > > > need
> > > > > to
> > > > > > > > > "hijack" and append the copied arguments after the "java"
> > > > command.
> > > > > > Make
> > > > > > > > > sure to set "suspend=y" if you want to make sure Flink
> > doesn't
> > > > > start
> > > > > > > > > without your debugger attached.
> > > > > > > > >
> > > > > > > > > Now simply run Flink with the script you tampered with and
> > run
> > > > the
> > > > > > > > > debugger. Please note that if you set "suspend=y" Flink
> won't
> > > > start
> > > > > > > until
> > > > > > > > > the debugger is attached to the process. Also beware that
> if
> > > the
> > > > > > > machine
> > > > > > > > > running Flink is far away from the remote debugger you may
> > > suffer
> > > > > > from
> > > > > > > > > increased latency when debugging.
> > > > > > > > >
> > > > > > > > > Hope I've been helpful, happy hacking. :)
> > > > > > > > >
> > > > > > > > > On Mon, May 16, 2016 at 6:43 PM, Vijay Srinivasaraghavan <
> > > > > > > > > [hidden email]> wrote:
> > > > > > > > >
> > > > > > > > > > How do I attach remote debugger to running Flink cluster
> > from
> > > > > > > IntelliJ?
> > > > > > > > > > Appreciate if anyone could share the steps?
> > > > > > > > > > RegardsVijay
> > > > > > > > >
> > > > > > > > >
> > > > > > > > >
> > > > > > > > >
> > > > > > > > > --
> > > > > > > > > BR,
> > > > > > > > > Stefano Baghino
> > > > > > > > >
> > > > > > > > > Software Engineer @ Radicalbit
> > > > > > > > >
> > > > > > > > >
> > > > > > > > >
> > > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > >
> > > > > >
> > > > > >
> > > > > > --
> > > > > > BR,
> > > > > > Stefano Baghino
> > > > > >
> > > > > > Software Engineer @ Radicalbit
> > > > > >
> > > > >
> > > >
> > >
> >
>
Reply | Threaded
Open this post in threaded view
|

Re: remote debugging

Flavio Pompermaier
You're welcome ;)

On Thu, May 19, 2016 at 11:54 AM, Till Rohrmann <[hidden email]>
wrote:

> Thanks Flavio for adding the Eclipse section for remote debugging :-)
>
> On Tue, May 17, 2016 at 5:55 PM, Flavio Pompermaier <[hidden email]>
> wrote:
>
> > Done ;)
> >
> > On Tue, May 17, 2016 at 5:37 PM, Robert Metzger <[hidden email]>
> > wrote:
> >
> > > Okay, I gave you permissions.
> > >
> > > On Tue, May 17, 2016 at 5:22 PM, Flavio Pompermaier <
> > [hidden email]>
> > > wrote:
> > >
> > > > I've just signed up as f.pompermaier
> > > >
> > > > Thanks!
> > > >
> > > > On Tue, May 17, 2016 at 5:04 PM, Robert Metzger <[hidden email]
> >
> > > > wrote:
> > > >
> > > > > Can you give me your wiki user id, then I can give you permissions.
> > > > >
> > > > > On Tue, May 17, 2016 at 3:56 PM, Flavio Pompermaier <
> > > > [hidden email]>
> > > > > wrote:
> > > > >
> > > > > > No I can't edit that page :(
> > > > > >
> > > > > > On Tue, May 17, 2016 at 3:46 PM, Stefano Baghino <
> > > > > > [hidden email]> wrote:
> > > > > >
> > > > > > > Thanks Flavio,
> > > > > > >
> > > > > > > perhaps it would be a nice addition to the Wiki page, would you
> > > care
> > > > to
> > > > > > > contribute your suggestion? :)
> > > > > > >
> > > > > > > On Tue, May 17, 2016 at 3:22 PM, Flavio Pompermaier <
> > > > > > [hidden email]>
> > > > > > > wrote:
> > > > > > >
> > > > > > > > Hi to all,
> > > > > > > >
> > > > > > > > for debugging Flink from Eclipse this is what you have to do:
> > > > > > > >
> > > > > > > >    1. go to 'Run' -> 'Debug configurations...'
> > > > > > > >    2. Create a new 'Remote Java Application'
> > > > > > > >    3. In the 'Connect' tab choose:
> > > > > > > >       1. the project to debug
> > > > > > > >       2. Connection type 'Standard (Socket Attach)'
> > > > > > > >       3. Connection properties
> *target.host.name-or-ip*/*5005*
> > > > > (change
> > > > > > > > *target.host.name-or-ip
> > > > > > > >       properly...)*
> > > > > > > >       4. (Optional) If you see the error 'Multiple launchers
> > > > > available'
> > > > > > > >       because you have bot Eclipse and scala debuggers click
> on
> > > > > Select
> > > > > > > one
> > > > > > > > and
> > > > > > > >       select the right one (e.g. Eclipse JDT Launcher)
> > > > > > > >
> > > > > > > > Unofrtunately remote debugging is not possible with Flink UDF
> > (or
> > > > at
> > > > > > > least
> > > > > > > > I didn't manage to debug it from Eclipse).
> > > > > > > >
> > > > > > > > Best,
> > > > > > > > Flavio
> > > > > > > >
> > > > > > > > On Tue, May 17, 2016 at 11:24 AM, Stephan Ewen <
> > [hidden email]
> > > >
> > > > > > wrote:
> > > > > > > >
> > > > > > > > > Hey Stefano!
> > > > > > > > >
> > > > > > > > > I think that question is bound to come up again. I created
> a
> > > page
> > > > > in
> > > > > > > the
> > > > > > > > > Flink Wiki to document this.
> > > > > > > > >
> > > > > > > > > If you have a few moments, would be great if you could add
> > your
> > > > > > > > description
> > > > > > > > > there:
> > > > > > > > >
> > > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
> https://cwiki.apache.org/confluence/display/FLINK/Remote+Debugging+of+Flink+Clusters
> > > > > > > > > (it is linked from the front page
> > > > > > > > >
> > > > >
> https://cwiki.apache.org/confluence/display/FLINK/Apache+Flink+Home
> > > > > > )
> > > > > > > > >
> > > > > > > > > Greetings,
> > > > > > > > > Stephan
> > > > > > > > >
> > > > > > > > >
> > > > > > > > > On Tue, May 17, 2016 at 4:26 AM, Vijay Srinivasaraghavan <
> > > > > > > > > [hidden email]> wrote:
> > > > > > > > >
> > > > > > > > > > Awesome, thanks Stefano!!
> > > > > > > > > >
> > > > > > > > > >     On Monday, May 16, 2016 9:57 AM, Stefano Baghino <
> > > > > > > > > > [hidden email]> wrote:
> > > > > > > > > >
> > > > > > > > > >
> > > > > > > > > >  I had to do it a couple of times. Wonderful experience
> to
> > > > > > understand
> > > > > > > > the
> > > > > > > > > > inner workings of Flink and explore it while running.
> > > > > > > > > > I don't know if there's a preferred way to do this but
> this
> > > is
> > > > > how
> > > > > > I
> > > > > > > > did
> > > > > > > > > > it:
> > > > > > > > > >
> > > > > > > > > > Edit the run configurations in IntelliJ, click the + icon
> > in
> > > > the
> > > > > > > upper
> > > > > > > > > left
> > > > > > > > > > corner, choose the "Remote" preset.
> > > > > > > > > > Under the "Settings" pane, fill in the remote host where
> > > you'll
> > > > > run
> > > > > > > > > Flink.
> > > > > > > > > > Copy the "Command line arguments for running remote JVM".
> > > > > > > > > > Go to the machine running Flink, choose the launch script
> > you
> > > > > need
> > > > > > to
> > > > > > > > > > "hijack" and append the copied arguments after the "java"
> > > > > command.
> > > > > > > Make
> > > > > > > > > > sure to set "suspend=y" if you want to make sure Flink
> > > doesn't
> > > > > > start
> > > > > > > > > > without your debugger attached.
> > > > > > > > > >
> > > > > > > > > > Now simply run Flink with the script you tampered with
> and
> > > run
> > > > > the
> > > > > > > > > > debugger. Please note that if you set "suspend=y" Flink
> > won't
> > > > > start
> > > > > > > > until
> > > > > > > > > > the debugger is attached to the process. Also beware that
> > if
> > > > the
> > > > > > > > machine
> > > > > > > > > > running Flink is far away from the remote debugger you
> may
> > > > suffer
> > > > > > > from
> > > > > > > > > > increased latency when debugging.
> > > > > > > > > >
> > > > > > > > > > Hope I've been helpful, happy hacking. :)
> > > > > > > > > >
> > > > > > > > > > On Mon, May 16, 2016 at 6:43 PM, Vijay Srinivasaraghavan
> <
> > > > > > > > > > [hidden email]> wrote:
> > > > > > > > > >
> > > > > > > > > > > How do I attach remote debugger to running Flink
> cluster
> > > from
> > > > > > > > IntelliJ?
> > > > > > > > > > > Appreciate if anyone could share the steps?
> > > > > > > > > > > RegardsVijay
> > > > > > > > > >
> > > > > > > > > >
> > > > > > > > > >
> > > > > > > > > >
> > > > > > > > > > --
> > > > > > > > > > BR,
> > > > > > > > > > Stefano Baghino
> > > > > > > > > >
> > > > > > > > > > Software Engineer @ Radicalbit
> > > > > > > > > >
> > > > > > > > > >
> > > > > > > > > >
> > > > > > > > > >
> > > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > > >
> > > > > > >
> > > > > > > --
> > > > > > > BR,
> > > > > > > Stefano Baghino
> > > > > > >
> > > > > > > Software Engineer @ Radicalbit
> > > > > > >
> > > > > >
> > > > >
> > > >
> > >
> >
>